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
I was wondering if you could offer advice about how to store pending Completion instances while you are waiting for them to be completed, potentially doing other work in the meantime and submitting additional tasks to the queue.
the two issues I ran into while attempting a demo event loop design around Rio were:
no way to storeCompletion instances returned by my ring, as taking an immutable reference into a collection would prevent the ability to add additional items to it, and
no way to check if a Completion is done without blocking (not sure if this is avoidable, I am not a io-uring expert (yet))
my goal is for a thread pool worker to be receiving io jobs over a channel, submitting work to the ring, potentially for several unrelated jobs at once, then processing the results from the ring as they become available, and sending back info/data about the outcome of the work to the thread that sent the job upon that result becoming available.
another, more big picture way of saying this is, how do I store the context (buffer/file) of a Rio submission, other than a named stack variable as in the examples?
thanks for any help you can provide!
The text was updated successfully, but these errors were encountered:
hello,
I was wondering if you could offer advice about how to store pending
Completion
instances while you are waiting for them to be completed, potentially doing other work in the meantime and submitting additional tasks to the queue.the two issues I ran into while attempting a demo event loop design around
Rio
were:Completion
instances returned by my ring, as taking an immutable reference into a collection would prevent the ability to add additional items to it, andCompletion
is done without blocking (not sure if this is avoidable, I am not a io-uring expert (yet))I posted some code here, which is where I stopped, unable to figure out how I would go further: https://gist.github.com/jonathanstrong/0d8aaef2fbbb62d2ddcd291f62a03114
my goal is for a thread pool worker to be receiving io jobs over a channel, submitting work to the ring, potentially for several unrelated jobs at once, then processing the results from the ring as they become available, and sending back info/data about the outcome of the work to the thread that sent the job upon that result becoming available.
another, more big picture way of saying this is, how do I store the context (buffer/file) of a
Rio
submission, other than a named stack variable as in the examples?thanks for any help you can provide!
The text was updated successfully, but these errors were encountered: