You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by di...@apache.org on 2021/07/24 20:37:30 UTC

[airavata-mft] branch develop updated: Fixing bug of not handling multi sectional uris

This is an automated email from the ASF dual-hosted git repository.

dimuthuupe pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/airavata-mft.git


The following commit(s) were added to refs/heads/develop by this push:
     new 512173b  Fixing bug of not handling multi sectional uris
512173b is described below

commit 512173ba9f6c5aafe2f42dcdabf2acb44ebd3eaa
Author: Dimuthu Wannipurage <di...@gmail.com>
AuthorDate: Sat Jul 24 16:37:18 2021 -0400

    Fixing bug of not handling multi sectional uris
---
 .../main/java/org/apache/airavata/mft/agent/http/HttpServerHandler.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/agent/src/main/java/org/apache/airavata/mft/agent/http/HttpServerHandler.java b/agent/src/main/java/org/apache/airavata/mft/agent/http/HttpServerHandler.java
index f9c026d..18fca15 100644
--- a/agent/src/main/java/org/apache/airavata/mft/agent/http/HttpServerHandler.java
+++ b/agent/src/main/java/org/apache/airavata/mft/agent/http/HttpServerHandler.java
@@ -63,7 +63,7 @@ public class HttpServerHandler extends SimpleChannelInboundHandler<FullHttpReque
                 return;
             }
 
-            final String uri = request.uri().substring(1);
+            final String uri = request.uri().substring(request.uri().lastIndexOf("/") + 1);
             logger.info("Received download request through url {}", uri);
 
             HttpTransferRequest httpTransferRequest = transferRequestsStore.getDownloadRequest(uri);