2 new revisions:

Revision: e797176c0b63
Author:   [email protected] <[email protected]>
Date:     Mon Apr 22 09:46:16 2013
Log:      Update issue 208
http://code.google.com/p/sipservlets/source/detail?r=e797176c0b63

Revision: c8611c354757
Author:   [email protected] <[email protected]>
Date:     Mon Apr 22 09:47:55 2013
Log:      Merge branch 'websocket_support'
http://code.google.com/p/sipservlets/source/detail?r=c8611c354757

==============================================================================
Revision: e797176c0b63
Author:   [email protected] <[email protected]>
Date:     Mon Apr 22 09:46:16 2013
Log:      Update issue 208
http://code.google.com/p/sipservlets/source/detail?r=e797176c0b63

Modified:
/sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/message/SipFactoryImpl.java

=======================================
--- /sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/message/SipFactoryImpl.java Sat Dec 8 11:19:34 2012 +++ /sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/message/SipFactoryImpl.java Mon Apr 22 09:46:16 2013
@@ -888,12 +888,18 @@
         */
        public void addLoadBalancerRouteHeader(Request request) {
                try {
+                       String transport = JainSipUtils.findTransport(request);
                        String host = null;
                        int port = -1;
OutboundProxy proxy = StaticServiceHolder.sipStandardService.getOutboundProxy();
                        if(proxy == null) {
-                               host = 
loadBalancerToUse.getAddress().getHostAddress();
-                               port = loadBalancerToUse.getSipPort();
+                               if(transport.equalsIgnoreCase("ws")){
+                                       //This is a WebSocket request through 
LB, no need to add Route header.
+                                       return;
+                               } else {
+                                       host = 
loadBalancerToUse.getAddress().getHostAddress();
+                                       port = loadBalancerToUse.getSipPort();
+                               }
                        } else {
                                host = proxy.getHost();
                                port = proxy.getPort();
@@ -901,7 +907,6 @@
javax.sip.address.SipURI sipUri = SipFactoryImpl.addressFactory.createSipURI(null, host);
                        sipUri.setPort(port);
                        sipUri.setLrParam();
-                       String transport = JainSipUtils.findTransport(request);
                        sipUri.setTransportParam(transport);
                        MobicentsExtendedListeningPoint listeningPoint =
getSipNetworkInterfaceManager().findMatchingListeningPoint(transport, false);

==============================================================================
Revision: c8611c354757
Author:   [email protected] <[email protected]>
Date:     Mon Apr 22 09:47:55 2013
Log:      Merge branch 'websocket_support'
http://code.google.com/p/sipservlets/source/detail?r=c8611c354757


--

--- You received this message because you are subscribed to the Google Groups "mobicents-commits" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to