11 Replies Latest reply on Jun 23, 2017 1:20 AM by haducloc

    EAP 6.4 & WebSockets with web server

    hostalp

      Hello, based on:

      - 16.2. Create a WebSocket Application

      - JBoss Enterprise Application Platform (EAP) 6 Supported Configurations - Red Hat Customer Portal

      - Does Red Hat / JBoss offer support for Apache, mod_jk, mod_proxy, or mod_cluster? - Red Hat Customer Portal (by the way why does this one mention mod_proxy as supported when the Supported Configurations document above doesn't mention mod_proxy at all?)

      - 4. Unsupported and Deprecated Features

      - Add support of websocket proxying. · modcluster/mod_cluster@e801c55 · GitHub

      - Make the websocket proxy switchable. · modcluster/mod_cluster@f1f68c5 · GitHub

       

      It seems that:

      - EAP 6.4 itself supports WebSockets

      - supported web server connectors mod_cluster 1.2.11 / mod_jk 1.2.40 don't support WebSockets

      - mod_cluster 1.3.1 supports WebSockets (without failover) via Apache HTTP Server 2.4.x mod_proxy_wstunnel but this configuration isn't supported by EAP 6.4

      - Apache HTTP Server 2.4.x mod_proxy_wstunnel alone (well, typically combined with mod_proxy_http + mod_proxy_balancer) supports WebSockets but this configuration isn't supported by EAP 6.4

       

      How is one supposed to achieve a supported configuration with web server and WebSockets?

        • 1. Re: EAP 6.4 & WebSockets with web server
          mmusaji

          Hi Petr

           

          If you're using and have access to access.redhat.com documentation I presume you have a support subscription with Red Hat. For support questions and supported configurations it's best to raise a support case with our support engineers for this type of question.

           

          Thanks

          Mustafa

          • 2. Re: EAP 6.4 & WebSockets with web server
            hostalp

            Hello,

            though we've got valid subscriptions, these are NFR ones as we're just Ready business partners. These NFR subscriptions are provided without a support so I'm afraid I wouldn't get anywhere when trying to use Your support channels.

             

            Basically we're developing a solution for our customer where we'd like to make use of WebSockets but it will have to be run together with a web server in the front of JBoss EAP servers (there's going to be a cluster of several JBoss instances). Internally we tested that it works with Apache 2.4 + mod_proxy_wstunnel, however I'm afraid this wouldn't be an accepted solution (by our customer) for production use since nothing seems to point to the possibility that such configuration would be supported by You (at least at the moment).

            • 3. Re: EAP 6.4 & WebSockets with web server
              csutherl

              Hi Petr,

               

              > How is one supposed to achieve a supported configuration with web server and WebSockets?

               

              At this point we aren't offering a supported mechanism for proxying with JWS to EAP 6.4.0, so mod_proxy, mod_jk, nor mod_cluster isn't presently supported for proxying to EAP with JWS. With that said, we are in the process of testing those features to ensure that everything will work as intended and I know that we're also looking at certifying mod_proxy_wstunnel as well. The testing of mod_proxy, mod_jk, and mod_cluster should be completed by sometime in July, but I can't say for sure if mod_proxy_wstunnel will be tested by that time. I'll have to get back to you on that.

               

              Let us know if you have other questions in the meantime.

              • 4. Re: EAP 6.4 & WebSockets with web server
                hostalp

                Hello,

                thank you for reply, We can wait for that time to see the outcome.

                At the moment we'd probably prefer to combine mod_cluster for HTTP traffic and add then just add mod_proxy_wstunnel related ProxyPass directives for the WebSockets connections. But given that it would require Apache 2.4 (because of mod_proxy_wstunnel) it would also mean that mod_cluster 1.3.1 (or later) would have to be used.

                The reason for the above solution is that the currently available mod_cluster 1.3.1 doesn't support failover for WS connections yet (and it uses mod_proxy_wstunnel anyway so it shouldn't make much difference to use it directly).

                • 5. Re: EAP 6.4 & WebSockets with web server
                  fcorneli

                  I've solved this issue by running an embedded NettoSphere within my Java EE application and directly expose the port without Apache front-end.

                  See also: Atmosphere/nettosphere · GitHub

                  • 6. Re: EAP 6.4 & WebSockets with web server
                    csutherl

                    Hello again,

                     

                    I'd like to apologize for the lull in my responsiveness. I just wanted to drop by and make a statement as I've had conversations around this post in support cases with a few individuals.

                     

                    JWS 3.x is _not_ presently supported as a proxy to EAP. It may work, but we haven't tested it at this time and therefore can't support it's use. We are working on testing this and will be supporting JWS as a proxy to EAP in a later 3.x release. Please reply with any questions; I'd be happy to answer them, hopefully a bit quicker than this reply

                     

                     

                     

                    -Coty

                    • 7. Re: EAP 6.4 & WebSockets with web server
                      hostalp

                      Hello, thanks for replying. So at the moment there's no supported solution for JBoss EAP with WebSockets and HTTP server in the front of it, right?

                      • 8. Re: EAP 6.4 & WebSockets with web server
                        csutherl

                        No problem. Again, sorry for the delay earlier. Yes, at the moment it isn't a supported configuration, but be aware that we are testing this for a future release of JWS 3. I'll make a note to myself to keep tabs on this forum post to provide you any updates that I get on it, or you can update and ask if some time passes with no update.

                        • 9. Re: EAP 6.4 & WebSockets with web server
                          fobos

                          Reviving this topic I have a similar environment that need of WebSockets and I'm using:

                          • RH 6.6
                          • JBoss EAP 6.4
                          • mod_cluster 1.2.11 (connector="http")
                          • Apache 2.2.15

                          I compiled mod_proxy_wstunnel for Apache 2.2, put on Apache and its works fine with manual configuration of ProxyPass, so I lost LB from mod_cluster in this case.

                           

                          Using http connector in mod_cluster have the same behavior of ajp with balancers but I need of the plus of ProxyPass to ws:// to a complete solution, is it what was developed in mod_cluster 1.3.1 with mod_proxy_wstunnel integration?

                           

                          I found something about EnableWsTunnel in mod_cluster 1.3.1, I downloaded mod_cluster 1.3.1 binaries but the same does not work with my Apache 2.2. I find that was compiled with Apache 2.4 and I don't know if the source is compatible with Apache 2.2.

                           

                          Anyone have ideia of how to enable EnableWsTunnel using Apache 2.2 and if is it possible ?

                           

                          Thank you.

                          • 10. Re: EAP 6.4 & WebSockets with web server
                            fobos

                            I build mod_proxy_wstunnel and mod_cluster 1.3.3 for Apache 2.2.15 with success. Now all is working as expected.

                             

                            Thanks.

                            • 11. Re: EAP 6.4 & WebSockets with web server
                              haducloc

                              Hi Carlos Lacerda,

                               

                              I am configuring mod_cluster 1.3.1 for Apache 2.4.18 and Wildfly 10. I am using mod_proxy_http instead of mod_proxy_ajp in order to support Websocket connection.

                               

                              I have done mod_cluster configuration. It is working fine.

                               

                              I googled a lot but I didn't find any document for WebSocket configuration for my situation (Apache 2.4.18, mod_cluster, mod_proxy, mod_proxy_http, and Wildfly 10)

                               

                              It seems that you had the same situation. Can you please share some configurations in order to make WebSocket work?

                               

                              Thanks a lot!

                               

                              Loc