Layer7 API Management

 View Only
  • 1.  Websocket configuration in a gateway HA pair?

    Posted Aug 31, 2018 12:38 PM

    After I configure a websocket connection in Policy Manager with e.g. port 20000, both gateways will start to listen on this port right away? Do I need to do anything else for both gateways to respond to websocket connection requests?

     

    Do I need to restart gateway (service ssg restart) for the websocket connection to take effect?



  • 2.  Re: Websocket configuration in a gateway HA pair?

    Posted Aug 31, 2018 12:48 PM

    After I configured websocket in Policy Manager, I ran `netstat -tulpn` and found only one gateway is listening on the port. After I ran `service ssg restart` on that node, it starts to listen on this port.

     

    Is gateway restart required for both gateways in an HA pair to become active?



  • 3.  Re: Websocket configuration in a gateway HA pair?
    Best Answer

    Posted Aug 31, 2018 06:11 PM

    Hi Victor,

     

    Please confirm which version of Gateway you are running. If it's 9.3, there are a few websocket-related bugs that were fixed up in cumulative releases ("CRs") that you may want to look into as in some cases it affected the way the connection was made (or rather a lack to create a connection successfully). Documentation referencing that is here for your reference: Resolved Issues - CA API Gateway - 9.3 - CA Technologies Documentation 

     

    From the documentation, I saw a note that reads that if an existing Websocket connection has changes made, the Websocket server on the Gateway is restarted, so it should do it all automatically for you I would think. Ref: WebSocket Connection Properties - CA API Gateway - 9.3 - CA Technologies Documentation 

     

    With that said though, I do see that a restart is needed after setting/changing any cluster-wide property related to websockets, which might imply a restart really is needed for a websocket connection. Ref: WebSocket Cluster Properties - CA API Gateway - 9.3 - CA Technologies Documentation 

     

    Unfortunately I don't have a lab available where I could quickly test this, so my input so far has just been what I've observed reading through the documentation.

     

    If you can confirm the Gateway version though, this may be relevant in case it's a bug. As a side note, no matter what version you are on, I'd recommend making sure you're on the latest CR. ;-)



  • 4.  Re: Websocket configuration in a gateway HA pair?

    Posted Sep 01, 2018 08:56 AM

    Hello Dustin.

     

    My gateway is 9.3. Reading the doc links in your reply above, looks like the issue I saw has been resolved,

     

    DE303135 as part of 9.3 CR1

    Changing a WebSocket connection now correctly updates all Gateway nodes, not just the node to which the Policy Manager is connected.

     

    I'm not defining cluster properties for my websocket connections (leave them with the default values). I define the properties in the websocket connection configuration; I assume gateway restart is not necessary then in this case?



  • 5.  Re: Websocket configuration in a gateway HA pair?

    Posted Sep 04, 2018 03:06 PM

    I don't believe the restart would be necessary in that case then, no.