-
Notifications
You must be signed in to change notification settings - Fork 34
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
database enhancements #666
Conversation
f836d05
to
afb76ec
Compare
Is this ready for review? Looking to be ongoing updates so maybe should be a draft until it's ready |
350a333
to
90dd3f5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should move the removal of store/src/db.rs into the first commit since you are already creating two separate files for sqlite and postgres that have the pool reuse modification
I figured it's probably better to have this enhancement as a single commit (too many moving pieces and I want to avoid to break bisect too) |
The pool object is meant to be reused and since we're initializing the store as part of a long running process, we should save the pool object and pass it around/use it. Have a proper db url directly in configuration files instead of using environment variables. Signed-off-by: Antonio Murdaca <[email protected]>
That also works for me 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
chore: store: db: reuse connection pool
The pool object is meant to be reused and since we're initializing the
store as part of a long running process, we should save the pool object
and pass it around/use it.
chore: store: db: refactor database configuration
This mainly comes from @mmartinv comment https://github.com/fdo-rs/fido-device-onboard-rs/pull/556/files#r1465996442