Skip to content

Commit

Permalink
fix: Method _should_use_plan only returns true for local sqlite provi…
Browse files Browse the repository at this point in the history
…der (feast-dev#2344)

Only the SQLite local provider supports _plan and _apply_diffs. Updated
the method to only return true for that setup so that other local
providers don't need to implement these methods right now.

Signed-off-by: Gunnar Sv Sigurbjörnsson <gunnar.sigurbjornsson@gmail.com>
  • Loading branch information
nossrannug authored Mar 1, 2022
1 parent 43cc886 commit fdb5f21
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sdk/python/feast/feature_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -392,8 +392,10 @@ def _get_features(

def _should_use_plan(self):
"""Returns True if _plan and _apply_diffs should be used, False otherwise."""
# Currently only the local provider supports _plan and _apply_diffs.
return self.config.provider == "local"
# Currently only the local provider with sqlite online store supports _plan and _apply_diffs.
return self.config.provider == "local" and (
self.config.online_store and self.config.online_store.type == "sqlite"
)

def _validate_all_feature_views(
self,
Expand Down

0 comments on commit fdb5f21

Please sign in to comment.