Skip to content

Remove spawn token queue

Sami Hiltunen requested to merge smh-remove-spawn-token-ff into master

Spawn token queue was implemented to limit the number of processes that might block on ForkLock in the Go runtime. It wasn't possible to cancel a request waiting ona lock, so the spawn token queue instead limited the number of processes that attempt to acquire the lock to prevent a pile up of goroutines in case forking is slow.

Go 1.21 is no longer serializing all forks by exclusively acquiring the ForkLock. We no longer need the spawn token queue to guard access to it. We've already rolled this change out to production behind a feature flag. As it works fine on production, let's remove the entire spawn token queue implementation and the feature flag with it.

Related to #6394 (closed), #5901 (closed)

Merge request reports

Loading