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

Storage - Replace LiteDB with SQLite + EF Core #843

Merged
merged 14 commits into from
Mar 13, 2024

Conversation

RobertBeekman
Copy link
Member

@RobertBeekman RobertBeekman commented Mar 9, 2024

  • Remove branch from CI

@DarthAffe
Copy link
Member

Two things I noted:

  1. The context in EF Core is not designed to be stored and kept alive for the lifetime of the application, but to be created when needed and disposed afterwards (https://learn.microsoft.com/en-us/ef/core/dbcontext-configuration/#the-dbcontext-lifetime)
  2. You should run #pragma OPTIMIZE from time to time (I don't think it's necessary on each db close, but maybe on application start/exit (https://www.sqlite.org/pragma.html#pragma_optimize and https://www.sqlite.org/lang_analyze.html)

@RobertBeekman RobertBeekman marked this pull request as ready for review March 13, 2024 19:18
@RobertBeekman RobertBeekman merged commit 551921d into development Mar 13, 2024
1 check passed
@RobertBeekman RobertBeekman deleted the feature/sqlite branch March 13, 2024 19:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants