Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Realtime Messaging - Can't establish a connection

    SmartGWT 4.1d
    Firefox 10.0.4

    I am evaluating upgrading from SmartGWT 3.0 to 4.1d, and GWT 2.4.0 to 2.6.0.

    I updated the required jars, but I get an exception on the browser stating "Firefox can't establish a connection to the server at https://.../myApp/sc/messaging..."

    Is there anything that needs to be done for 4.1d realtime messaging?

    #2
    Realtime Messaging - Can't establish a connection

    It appears to hit the servlet when I increase the timeout (via Poster). But why does it take so long for it to return?

    Comment


      #3
      Realtime Messaging - Can't establish a connection

      Firebug actually gives a 505 HTTP Version Not Supported error

      Comment


        #4
        Realtime Messaging - Can't establish a connection

        Is there a limit on the length of subscribedChannels?

        I have over 200+ channels.

        I also noticed a successful GET which only contained 4 subscribedChannels.

        Comment


          #5
          This sounds like either:

          1. The Messaging Servlet is not deployed at all - see Messaging overview

          2. You have a lot of channels, and perhaps some large cookies, and this is exceeding the HTTP GET request combined limit for the URL and headers (which included cookies), which your server is misreporting as the wrong protocol version.

          If the latter is the problem, you will need to either reduce the size of your cookies, or reduce the number of channels the client needs to subscribe to, presumably by creating consolidated channel names in the server so that the client can effectively subscribe to many channels at once using just one shorter identifier.

          Comment


            #6
            Assuming its 2), since it works with less channels, has there been a change to the limit in SmartGWT 4.1d from SmartGWT 3.0?

            This used to work just fine in SmartGWT 3.0.

            Comment


              #7
              Nothing's changed - this isn't a limit we're in control of, and not a limit we're enforcing, it's your Servlet engine doing that.

              So what may have actually changed is:

              1. Your Servlet engine was also updated and now enforces this limit

              2. Something about your deployment has added more or larger HTTP headers (including cookies) or a longer URL.

              Comment


                #8
                Realtime Messaging - Can't establish a connection

                Using SmartGWT 4.1p now, but still seeing the same error in Firebug:

                505 HTTP Version Not Supported error

                One thing I notice is that the previous working version, 3.0p, sends POSTs whereas 4.1p sends GETs

                Does this sound correct?

                Comment


                  #9
                  Whether we use GET or POST is now browser-dependent, to work around bugs in various browsers.

                  Again the causes to look at are in post #7 above.

                  Comment


                    #10
                    Realtime Messaging - Can't establish a connection

                    Both my 3.1p and 4.1p applications are deployed on JBoss 6.2.0 EAP.

                    The only change made was to the ${smartgwt.version} property in our pom.xml

                    We verify using the same Firefox 10.0.4 browser on RHEL 6.

                    And the 3.1p sends POSTs and the 4.1p sends GETs.

                    I do compile for Firefox in my gwt.xml:

                    <set-property name="user.agent" value="gecko1_8" />

                    Is my 4.1p application being confused for a Chrome application?

                    Comment


                      #11
                      No. Again, the fact that you see GET requests on some platforms is a correct and expected behavior. Please look into the possibilities in #7 above.

                      Comment


                        #12
                        Realtime Messaging - Can't establish a connection

                        From what I'm reading POSTs have much higher limits than GETs, which might explain the problem.

                        Comment


                          #13
                          Yes they do. However as you can easily see, we are not sending any significant data to the server, other than the URL and cookies, which we already covered in post #7.

                          Comment


                            #14
                            Realtime Messaging - Can't establish a connection

                            Firebug lists the request as containing much more, specifically the "subscribedChannels", which in my case is quite large.

                            /messaging?ts=1397779861271&type=connect&connectionID=isc_HiddenFrame_109&subscribedChannels=...

                            Comment


                              #15
                              Right, so:

                              2. You have a lot of channels, and perhaps some large cookies, and this is exceeding the HTTP GET request combined limit for the URL and headers (which included cookies), which your server is misreporting as the wrong protocol version.
                              Have you looked yet at whether your server has a limit on GET URLs, and whether you can change it?

                              Also just how big is the total amount of data?

                              Comment

                              Working...
                              X