Problem Statement
The current version of SDK contains static calls to classes that manage one global state. This is not usable in concurrent workloads, where multiple fibers may process multiple requests concurrently.
Would it be possible to implement a fiber context layer above the current global state, so each fiber could work with contextual data that belongs to it?
Solution Brainstorm
Maybe it would be sufficient to index fiber contexts by spl_object_id() of the fiber, not sure if that works though. In Swoole, the contexts can be indexed by coroutine id.