[query] Decide on an approach for re-algebrizing and caching queries #154
Labels
No labels
A-build
A-cli
A-core
A-design
A-edn
A-ffi
A-query
A-sdk
A-sdk-android
A-sdk-ios
A-sync
A-transact
A-views
A-vocab
P-Android
P-desktop
P-iOS
bug
correctness
dependencies
dev-ergonomics
discussion
documentation
duplicate
enhancement
enquiry
good first bug
good first issue
help wanted
hygiene
in progress
invalid
question
ready
size
speed
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: greg/mentat#154
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
A query goes through several stages between input and execution.
Most likely we will want to cache/prepare up to four of these:
In the first and second cases, we hit an issue with
Rc
, which isn'tSend
: a query cache must be per-thread.In the third case, we also hit a snag with
Rc
: we can't useRc
in query arguments, so the definition ofSQLQuery
will have to change a little. (We'll also hit this if we need to keep args around in the fourth case.)We should decide on our path forward; we will hit this as soon as we begin to write a multi-threaded query consumer. Our options are:
SQLQuery
in terms ofArc
or nothing at all, allowing it to be reused, but otherwise not allowing these internal states to leak across threads.Arc
instead ofRc
. We don't mutate the reference count very often.