You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by se...@apache.org on 2012/11/29 17:00:49 UTC

svn commit: r1415224 - in /cxf/branches/2.6.x-fixes: ./ rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java

Author: sergeyb
Date: Thu Nov 29 16:00:48 2012
New Revision: 1415224

URL: http://svn.apache.org/viewvc?rev=1415224&view=rev
Log:
Merged revisions 1415221 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1415221 | sergeyb | 2012-11-29 15:57:02 +0000 (Thu, 29 Nov 2012) | 1 line
  
  [CXF-4643] Updating ServletController to check for custom query handlers only if HTTP method is GET
........

Modified:
    cxf/branches/2.6.x-fixes/   (props changed)
    cxf/branches/2.6.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java

Propchange: cxf/branches/2.6.x-fixes/
------------------------------------------------------------------------------
    svn:mergeinfo = /cxf/trunk:1415221

Propchange: cxf/branches/2.6.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.6.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java?rev=1415224&r1=1415223&r2=1415224&view=diff
==============================================================================
--- cxf/branches/2.6.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java (original)
+++ cxf/branches/2.6.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java Thu Nov 29 16:00:48 2012
@@ -167,14 +167,12 @@ public class ServletController {
                             orig = ClassLoaderUtils.setThreadContextClassloader(loader);
                         }
                     }
+                    updateDestination(request, d);
+                    
                     QueryHandlerRegistry queryHandlerRegistry = bus.getExtension(QueryHandlerRegistry.class);
-
-                    if (!StringUtils.isEmpty(request.getQueryString()) && queryHandlerRegistry != null) {
-                        
-                        // update the EndPoint Address with request url
-                        if ("GET".equals(request.getMethod())) {
-                            updateDestination(request, d);
-                        }
+                    if ("GET".equals(request.getMethod()) 
+                        && !StringUtils.isEmpty(request.getQueryString()) 
+                        && queryHandlerRegistry != null) {
                         
                         String ctxUri = request.getPathInfo();
                         String baseUri = request.getRequestURL().toString()
@@ -187,8 +185,6 @@ public class ServletController {
                             respondUsingQueryHandler(selectedHandler, res, ei, ctxUri, baseUri);
                             return;
                         }
-                    } else {
-                        updateDestination(request, d);
                     }
                     invokeDestination(request, res, d);
                 } finally {