Async activity Invocation Example in Go#286
Async activity Invocation Example in Go#286edmondop wants to merge 4 commits intotemporalio:mainfrom
Conversation
There was a problem hiding this comment.
Add this example to the example list
| err = future.Get(ctx, &res2) | ||
| }) | ||
| selector.Select(ctx) | ||
| selector.Select(ctx) |
There was a problem hiding this comment.
If an err was reported by the first select, you have swallowed it
|
We already have two samples that cover async activity execution: https://github.com/temporalio/samples-go/tree/main/splitmerge-future |
mfateev
left a comment
There was a problem hiding this comment.
This use case is already covered by existing samples:
https://github.com/temporalio/samples-go/tree/main/splitmerge-selector
https://github.com/temporalio/samples-go/tree/main/splitmerge-future
Thanks! Didn't know those examples! If this pattern is what match more closely the Java async examples, maybe we can just update the README ? |
What was changed
This adds an example of a non-blocking invocation of two activities in Go, with a behavior coherent with the Java example here
https://github.com/edmondop/samples-java/blob/main/src/main/java/io/temporal/samples/hello/HelloAsync.java#L114
Why?
Checklist
Closes
How was this tested: