1

My application is hosted on Nodejitsu and uses multiple drones/servers.

According to the Nodejitsu documentation, I can target a specific drone via the http header

'x-drone':1 where 1 is the drone number.

On client side, it looks something like this: (I think this is how it's supposed to be. I can't test it because I don't have multiple drones yet.)

$.ajax({
    url: '/path',
    headers: { 'x-drone': 1 }
});

Is there a way to establish a socket.io connection to a specific drone?

Right now, this is what I have on client side (but it connects to least busy drone):

    <script src="/socket.io/socket.io.js"></script>
    var socket = io(); //version 1.0

I searched in the documentation about io() for options parameter but couldn't find anything.

RainingChain
  • 7,397
  • 10
  • 36
  • 68

0 Answers0