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
tokio-uring provides lots of async APIs for dealing with async IO, is there any way to deal with async non-IO?
For example, there is one tokio-uring application in which some data(meta) needs to be cached. More than one tasks need to check
and use the cache:
if the cache is update(read from FS), just use it, there isn't any
await involved.
if the cache doesn't exist, call async_read().await
if the cache IO(async_read()) has been started, but not completed yet, how to implement await, so that when the in-flight cache read is completed, this task gets notified.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello,
tokio-uring provides lots of async APIs for dealing with async IO, is there any way to deal with async non-IO?
For example, there is one tokio-uring application in which some data(meta) needs to be cached. More than one tasks need to check
and use the cache:
if the cache is update(read from FS), just use it, there isn't any
await involved.
if the cache doesn't exist, call async_read().await
if the cache IO(async_read()) has been started, but not completed yet, how to implement await, so that when the in-flight cache read is completed, this task gets notified.
Thanks,
Beta Was this translation helpful? Give feedback.
All reactions