Skip to content

Supporting load balancers #1057

Closed
Closed
@OneSman7

Description

@OneSman7

Hello!

We added load balancers to our server (tried haproxy and traefik) and lost web socket connection. After debugging we encountered that balancers use cookies to route connections to the same server after initial connect, and those are not passed when trying to create web socket connection. I am talking about createWebSocketAndConnect() method.

To support load balancers that use cookies we just need to pass them from current long polling URLSession to URLRequest that is used when creating WebSocket object.

I am working on a PR with proposed changes, will link it here.
What do you think, will such changes be merged?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions