Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Graduate write_to_online_store out of experimental status #2426

Merged
merged 1 commit into from
Mar 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions sdk/python/feast/feature_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -1159,11 +1159,6 @@ def write_to_online_store(
"""
ingests data directly into the Online store
"""
if not flags_helper.enable_direct_ingestion_to_online_store(self.config):
raise ExperimentalFeatureNotEnabled(
flags.FLAG_DIRECT_INGEST_TO_ONLINE_STORE
)

# TODO: restrict this to work with online StreamFeatureViews and validate the FeatureView type
feature_view = self._registry.get_feature_view(
feature_view_name, self.project, allow_cache=allow_registry_cache
Expand Down
2 changes: 0 additions & 2 deletions sdk/python/feast/flags.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
FLAG_ALPHA_FEATURES_NAME = "alpha_features"
FLAG_ON_DEMAND_TRANSFORM_NAME = "on_demand_transforms"
FLAG_AWS_LAMBDA_FEATURE_SERVER_NAME = "aws_lambda_feature_server"
FLAG_DIRECT_INGEST_TO_ONLINE_STORE = "direct_ingest_to_online_store"
ENV_FLAG_IS_TEST = "IS_TEST"

FLAG_NAMES = {
FLAG_ALPHA_FEATURES_NAME,
FLAG_ON_DEMAND_TRANSFORM_NAME,
FLAG_AWS_LAMBDA_FEATURE_SERVER_NAME,
FLAG_DIRECT_INGEST_TO_ONLINE_STORE,
}
4 changes: 0 additions & 4 deletions sdk/python/feast/flags_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,3 @@ def enable_on_demand_feature_views(repo_config: RepoConfig) -> bool:

def enable_aws_lambda_feature_server(repo_config: RepoConfig) -> bool:
return feature_flag_enabled(repo_config, flags.FLAG_AWS_LAMBDA_FEATURE_SERVER_NAME)


def enable_direct_ingestion_to_online_store(repo_config: RepoConfig) -> bool:
return feature_flag_enabled(repo_config, flags.FLAG_DIRECT_INGEST_TO_ONLINE_STORE)
9 changes: 8 additions & 1 deletion sdk/python/feast/repo_config.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import logging
import os
from pathlib import Path
from typing import Any
Expand All @@ -23,6 +24,8 @@
from feast.importer import import_class
from feast.usage import log_exceptions

_logger = logging.getLogger(__name__)

# These dict exists so that:
# - existing values for the online store type in featurestore.yaml files continue to work in a backwards compatible way
# - first party and third party implementations can use the same class loading code path.
Expand Down Expand Up @@ -278,7 +281,11 @@ def _validate_flags(cls, v):

for flag_name, val in v.items():
if flag_name not in flags.FLAG_NAMES:
raise ValueError(f"Flag name, {flag_name}, not valid.")
_logger.warn(
"Unrecognized flag: %s. This feature may be invalid, or may refer "
"to a previously experimental feature which has graduated to production.",
flag_name,
)
if type(val) is not bool:
raise ValueError(f"Flag value, {val}, not valid.")

Expand Down