Skip to content

Commit

Permalink
add remote registry
Browse files Browse the repository at this point in the history
Signed-off-by: tokoko <[email protected]>
  • Loading branch information
tokoko committed Feb 7, 2024
1 parent 373e624 commit 14a9e10
Show file tree
Hide file tree
Showing 6 changed files with 445 additions and 1 deletion.
4 changes: 4 additions & 0 deletions sdk/python/feast/feature_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,10 @@ def __init__(
self._registry = SnowflakeRegistry(
registry_config, self.config.project, None
)
elif registry_config and registry_config.registry_type == "remote":
from feast.infra.registry.remote import RemoteRegistry

self._registry = RemoteRegistry(registry_config, self.config.project, None)
else:
r = Registry(self.config.project, registry_config, repo_path=self.repo_path)
r._initialize_registry(self.config.project)
Expand Down
2 changes: 1 addition & 1 deletion sdk/python/feast/infra/registry/base_registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def delete_feature_view(self, name: str, project: str, commit: bool = True):
@abstractmethod
def get_stream_feature_view(
self, name: str, project: str, allow_cache: bool = False
):
) -> StreamFeatureView:
"""
Retrieves a stream feature view.
Expand Down
4 changes: 4 additions & 0 deletions sdk/python/feast/infra/registry/registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,10 @@ def __new__(
from feast.infra.registry.snowflake import SnowflakeRegistry

return SnowflakeRegistry(registry_config, project, repo_path)
elif registry_config and registry_config.registry_type == "remote":
from feast.infra.registry.remote import RemoteRegistry

return RemoteRegistry(registry_config, project, repo_path)
else:
return super(Registry, cls).__new__(cls)

Expand Down
Loading

0 comments on commit 14a9e10

Please sign in to comment.