0

I have an EC2 instance. I need to receive data from 4 separate websockets located in different regions around the world.

Three of the websockets are working fine, but one of the websockets is being routed in a weird way by their CDN and it's taking multiple seconds for the data to reach me. So I want to create my own proxy next to the source (I am only 80 milliseconds away from the region by ping) and connect to the websocket through the proxy so that I can get the data faster. I should save a few seconds by doing this.

So, I want to connect to 3 websockets normally, and to 1 websocket through my own proxy.

I'm using Java's okhttp3 websocket library.

How would I achieve this?

  • You’ll need to add more details on what programs or tools or programming languages you use to connect to the WS sources. – MLu Feb 16 '20 at 09:04
  • The question still seems unclear. You might be asking "how do I set up a forward (or reverse?) proxy server that supports websockets?" or perhaps you're asking "how do I configure the Java `okhttp3` library to use a proxy server for some endpoints but not others?" or something else entirely. – Michael - sqlbot Feb 17 '20 at 01:38

0 Answers0