You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@synapse.apache.org by GitBox <gi...@apache.org> on 2020/02/27 13:50:21 UTC

[GitHub] [synapse] madhawa-gunasekara commented on a change in pull request #23: Fix SYNAPSE-1106

madhawa-gunasekara commented on a change in pull request #23: Fix SYNAPSE-1106
URL: https://github.com/apache/synapse/pull/23#discussion_r385136910
 
 

 ##########
 File path: modules/transports/core/nhttp/src/main/java/org/apache/synapse/transport/passthru/ServerWorker.java
 ##########
 @@ -107,110 +107,114 @@ public ServerWorker(final SourceRequest request,
     }
 
     public void run() {
-        if (log.isDebugEnabled()) {
-            log.debug("Starting a new Server Worker instance");
-        }
-        ConfigurationContext cfgCtx = sourceConfiguration.getConfigurationContext();        
-        msgContext.setProperty(Constants.Configuration.HTTP_METHOD, request.getMethod());
-
-        String method = request.getRequest() != null ?
-                request.getRequest().getRequestLine().getMethod().toUpperCase() : "";
-        
-        String uri = request.getUri();
-        String oriUri = uri;
-        
-        if (uri.contains(cfgCtx.getServicePath())) {
-            // discard up to servicePath
-            uri = uri.substring(uri.indexOf(cfgCtx.getServicePath()) +
-                    cfgCtx.getServicePath().length());
-            // discard [proxy] service name if any
-            int pos = uri.indexOf("/", 1);
-            if (pos > 0) {
-                uri = uri.substring(pos);
-            } else {
-                pos = uri.indexOf("?");
-                if (pos != -1) {
+        try {
 
 Review comment:
   Noted 👍 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@synapse.apache.org
For additional commands, e-mail: dev-help@synapse.apache.org