I have this piece of code to execute two methods asynchronously so that I can receive signals meanwhile, but I also want to maintain the order these methods are executed.
Hi @tihomir, isn’t Activity considered a blocking call?
I’m asking because API doc of thenApply states that: Note that no blocking calls are allowed inside of the function.
The api doc that is referred in previous question is here.
We will update the comment to make it more clear. The intent was to say that the function code should follow the same constraints as the rest of the workflow code, outlined here.
So invoking an activity in the function passed to thenApply is fine (blocking and then resuming the workflow thread with things like activity invocation).
Thank you @tihomir . I thought that maybe thenApply and thenCompose behave differently in that regard, as thenApply has this comment about blocking calls, and thenCompose does not (docs).
Thank you for the clarification.