Closed hgiasac closed 9 months ago
I haven't tested in-depth about extremely high race condition use cases. However, there would be some locks on the read-message loop. For example, if the execution is too long, other messages will be locked or discarded from the WebSocket client.
So we should keep the async mode to avoid breaking changes for other users. It would be great if you could test and prove the sync mode works without issue. Thanks
I have heavily tested this version in my project, which has numerous subscriptions, and I have not encountered any issues. I think it can be merged.
close https://github.com/hasura/go-graphql-client/issues/113
Add a new
syncMode
option to allow subscriptions to execute messages in sequence (without goroutine)