You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We currently use prepare to create sqlite statements, however we should use prepare_cachedas parsing a statement is a non-trivial cost.
How should it be done?
Analyze the sql statements in crates/store/src/db/sql.rs and change every common one to use prepare_cached.
Exceptions should be made for statements which should be rare. Alternatively (and maybe additionally), we should change the cache size which currently defaults to 16 to something large enough to handle all statements..
When is this task done?
All relevant prepare are changed to prepare_cached and the default cache size has been changed (or at least address why it should not be changed).
Node's components affected by this task
What should be done?
We currently use
prepare
to create sqlite statements, however we should useprepare_cached
as parsing a statement is a non-trivial cost.How should it be done?
Analyze the sql statements in
crates/store/src/db/sql.rs
and change every common one to useprepare_cached
.Exceptions should be made for statements which should be rare. Alternatively (and maybe additionally), we should change the cache size which currently defaults to 16 to something large enough to handle all statements..
When is this task done?
All relevant
prepare
are changed toprepare_cached
and the default cache size has been changed (or at least address why it should not be changed).Additional context
#419 (comment)
The text was updated successfully, but these errors were encountered: