trustfall
trustfall copied to clipboard
Make it possible for query result iterators to be `Send`
Right now, none of our code or tests check whether the result iterator will be Send
, and I believe it is currently not Send
. Making it Send
would make it easier to use lazy evaluation of queries in a work-stealing parallel context, like with tokio
's default settings.
Making it Send
won't be free since some Rc
may need to become Arc
. It will also require that the value of the Adapter::Vertex
associated type is also Send
.
We need:
- [x] internal implementation changes to make
Send
possible - [ ] documentation on how to adjust your adapter to produce
Send
result iterators - [ ] tests that ensure that following all the steps properly results in a
Send
iterator type
I believe we've completed the work needed to make Send
possible.