-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Merge feast-snowflake plugin into main repo with documentation #2193
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
Merged
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
f359ee3
Add backticks to left_table_query_string (#2250)
dmille 49c5536
Delete entity key from Redis only when all attached feature views are…
pyalex 68d2c1a
historical_field_mappings2 merge for one sign off commit (#2252)
michelle-rascati-sp 507ca6b
Correct inconsistent dependency (#2255)
judahrand 660a7d0
Add snowflake environment variables to allow testing on snowflake inf…
sfc-gh-madkins d44561b
Return `UNIX_TIMESTAMP` as Python `datetime` (#2244)
judahrand e617a06
Feast plan clean up (#2256)
felixwang9817 bb17968
Squash commits
adchia 1152687
Add error type and refactor query execution to have retries
adchia 9a2e0a5
Handle more snowflake errors
adchia 7c24117
Fix lint errors
adchia 5f8fbf4
Fix lint errors
adchia 80627c5
Fix lint errors
adchia 12c92f1
Fix wrong import
adchia 17874d7
modify registry.db s3 object initialization to work in S3 subdirector…
NalinGHub 61172b3
clean up docs
sfc-gh-madkins 26270bb
Merge branch 'feast-dev:master' into master
sfc-gh-madkins 9e952b2
lint-python
sfc-gh-madkins 12b2657
Merge branch 'master' of github.com:sfc-gh-madkins/feast
sfc-gh-madkins 3ddaf0d
fixed historical test
sfc-gh-madkins 6c29bfb
fixed historical test
sfc-gh-madkins File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| # Snowflake | ||
|
|
||
| ## Description | ||
|
|
||
| Snowflake data sources allow for the retrieval of historical feature values from Snowflake for building training datasets as well as materializing features into an online store. | ||
|
|
||
| * Either a table reference or a SQL query can be provided. | ||
|
|
||
| ## Examples | ||
|
|
||
| Using a table reference | ||
|
|
||
| ```python | ||
| from feast import SnowflakeSource | ||
|
|
||
| my_snowflake_source = SnowflakeSource( | ||
| database="FEAST", | ||
| schema="PUBLIC", | ||
| table="FEATURE_TABLE", | ||
| ) | ||
| ``` | ||
|
|
||
| Using a query | ||
|
|
||
| ```python | ||
| from feast import SnowflakeSource | ||
|
|
||
| my_snowflake_source = SnowflakeSource( | ||
| query=""" | ||
| SELECT | ||
| timestamp_column AS "ts", | ||
| "created", | ||
| "f1", | ||
| "f2" | ||
| FROM | ||
| `FEAST.PUBLIC.FEATURE_TABLE` | ||
| """, | ||
| ) | ||
| ``` | ||
|
|
||
| One thing to remember is how Snowflake handles table and column name conventions. | ||
| You can read more about quote identifiers [here](https://docs.snowflake.com/en/sql-reference/identifiers-syntax.html) | ||
|
|
||
| Configuration options are available [here](https://rtd.feast.dev/en/latest/index.html#feast.data_source.SnowflakeSource). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Snowflake | ||
|
|
||
| ## Description | ||
|
|
||
| The Snowflake offline store provides support for reading [SnowflakeSources](../data-sources/snowflake.md). | ||
|
|
||
| * Snowflake tables and views are allowed as sources. | ||
| * All joins happen within Snowflake. | ||
| * Entity dataframes can be provided as a SQL query or can be provided as a Pandas dataframe. Pandas dataframes will be uploaded to Snowflake in order to complete join operations. | ||
| * A [SnowflakeRetrievalJob](https://github.com/feast-dev/feast/blob/bf557bcb72c7878a16dccb48443bbbe9dc3efa49/sdk/python/feast/infra/offline_stores/snowflake.py#L185) is returned when calling `get_historical_features()`. | ||
|
|
||
| ## Example | ||
|
|
||
| {% code title="feature_store.yaml" %} | ||
| ```yaml | ||
| project: my_feature_repo | ||
| registry: data/registry.db | ||
| provider: local | ||
| offline_store: | ||
| type: snowflake.offline | ||
| account: snowflake_deployment.us-east-1 | ||
| user: user_login | ||
| password: user_password | ||
| role: sysadmin | ||
| warehouse: demo_wh | ||
| database: FEAST | ||
| ``` | ||
| {% endcode %} | ||
|
|
||
| Configuration options are available [here](https://github.com/feast-dev/feast/blob/bf557bcb72c7878a16dccb48443bbbe9dc3efa49/sdk/python/feast/infra/offline_stores/snowflake.py#L39). |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.