main
etc?
ask
pattern
@olanod - did you ever find a way to run a future to completion from within an actor's recv
method? Just using block_on
results in the error
cannot execute
LocalPool
executor from within another executor: EnterError
and trying to use the ctx.run()
method complains about a lifetime issue as the future that I'm trying to execute is a method on an S3 bucket client from rusoto. Thanks!
move
keyword
tokio::runtime::Handle::current()
and then pass this handle around to the actor system whenever an actor needed to be able to block on a future. Hope this helps others! I think this should be added to the docs, and if I get motivated I may submit a PR for this.
Version 0.4.2
is now available. Special thanks to @olexiyb and @nothingismagick for:
Next up we'll be expanding on the migration to GHA to improve cadence with regards to code merges and version releases. Thank you to the team and community.
[dependencies]
riker = "0.4.2"
ask
pattern here: https://riker.rs/patterns/ )
'there is no timer running, must be called from the context of Tokio runtime'
when using Context::run
? riker-rs/riker#150
Context::run
? I would basically like to use self
when running a future using ctx.run(async move { self.data = something().await; })
but of course that doesn't work. Can I use messages?