Limit Concurrent Activities in Parallel

Hmm - this only allows us to limit activities per worker, but what if you wanted to limit the activities on a workflow?
For example, if you have a workflow that needs to execute 64 activities, but only want 4 activities executing concurrently. Is that possible?

You start 4 activities and start more when one of the executing activities is completed. Note that in Go SDK ExecuteActivity returns a Future. So the call is already asynchronous. You can use Selector for waiting on multiple Futures.

Also, is there a limit on how many activities you can have running in parallel at any point in time?

Limiting the number of executing activities across multiple workers is not supported. Only a global rate list per task queue is supported.

I haven’t heard of swarm before, so maybe that terminology is why I didn’t jump to this. Do you have a rough description of what this attempts to do?

It was contributed. So I’m not an expert in the mathematical model it implements.