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

Flatten configuration structure for online store #1459

Merged
merged 6 commits into from
Apr 13, 2021

Conversation

woop
Copy link
Member

@woop woop commented Apr 13, 2021

Signed-off-by: Willem Pienaar git@willem.co

What this PR does / why we need it:

The current configuration structure requires a nested online_store configuration like this

project: foo
registry: "registry.db"
provider: local
online_store:
    local:
        path: online_store.db

This refactor moves to

project: foo
registry: "registry.db"
provider: local
online_store:
    type: sqlite
    path: online_store.db

but allows for a default type to be set, based on the provider.

project: foo
registry: "registry.db"
provider: local
online_store:
    path: online_store.db

Much of the work in this PR is just to ensure that exceptions are clear to the user.

Does this PR introduce a user-facing change?:

Flattened configuration structure for online store

sdk/python/feast/repo_config.py Outdated Show resolved Hide resolved
Signed-off-by: Willem Pienaar <git@willem.co>
Signed-off-by: Willem Pienaar <git@willem.co>
Signed-off-by: Willem Pienaar <git@willem.co>
Signed-off-by: Willem Pienaar <git@willem.co>
Signed-off-by: Willem Pienaar <git@willem.co>
@@ -63,7 +65,7 @@ class RepoConfig(FeastBaseModel):
provider: StrictStr
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we'll need defaults for provider and project in order for RepoConfig() with no arguments to work

@jklegar
Copy link
Collaborator

jklegar commented Apr 13, 2021

fyi there's an empty file sdk/python/telemetry_tests/data/online.db included in here

Signed-off-by: Willem Pienaar <git@willem.co>
@feast-ci-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jklegar, woop

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jklegar
Copy link
Collaborator

jklegar commented Apr 13, 2021

/lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants