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

wiener pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git


The following commit(s) were added to refs/heads/dev by this push:
     new e8f8277  [STREAMPIPES-427] remove username from base api path in client
e8f8277 is described below

commit e8f82778ead806581c6050bbcff6d9500f255d41
Author: Patrick Wiener <[email protected]>
AuthorDate: Sun Oct 17 13:32:57 2021 +0200

    [STREAMPIPES-427] remove username from base api path in client
---
 .../main/java/org/apache/streampipes/client/api/PipelineApi.java    | 2 +-
 .../java/org/apache/streampipes/client/util/StreamPipesApiPath.java | 6 ++++--
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git 
a/streampipes-client/src/main/java/org/apache/streampipes/client/api/PipelineApi.java
 
b/streampipes-client/src/main/java/org/apache/streampipes/client/api/PipelineApi.java
index 45a0959..1f0d949 100644
--- 
a/streampipes-client/src/main/java/org/apache/streampipes/client/api/PipelineApi.java
+++ 
b/streampipes-client/src/main/java/org/apache/streampipes/client/api/PipelineApi.java
@@ -102,7 +102,7 @@ public class PipelineApi extends 
AbstractClientApi<Pipeline> implements CRUDApi<
 
   @Override
   protected StreamPipesApiPath getBaseResourcePath() {
-    return StreamPipesApiPath.fromUserApiPath(clientConfig.getCredentials())
+    return StreamPipesApiPath.fromBaseApiPath()
             .addToPath("pipelines");
   }
 }
diff --git 
a/streampipes-client/src/main/java/org/apache/streampipes/client/util/StreamPipesApiPath.java
 
b/streampipes-client/src/main/java/org/apache/streampipes/client/util/StreamPipesApiPath.java
index c3764af..83a6758 100644
--- 
a/streampipes-client/src/main/java/org/apache/streampipes/client/util/StreamPipesApiPath.java
+++ 
b/streampipes-client/src/main/java/org/apache/streampipes/client/util/StreamPipesApiPath.java
@@ -30,9 +30,12 @@ public class StreamPipesApiPath {
   private static final List<String> BaseApiPathV2 = 
Arrays.asList("streampipes-backend", "api", "v2");
 
   public static StreamPipesApiPath fromBaseApiPath() {
-    return new StreamPipesApiPath(BaseApiPathV2);
+    List<String> authPath = new ArrayList<>();
+    authPath.addAll(BaseApiPathV2);
+    return new StreamPipesApiPath(authPath);
   }
 
+  @Deprecated
   public static StreamPipesApiPath fromUserApiPath(StreamPipesCredentials 
credentials) {
     List<String> authPath = new ArrayList<>();
     authPath.addAll(BaseApiPathV2);
@@ -40,7 +43,6 @@ public class StreamPipesApiPath {
     return new StreamPipesApiPath(authPath);
   }
 
-
   private StreamPipesApiPath(List<String> initialPathItems) {
     this.pathItems = initialPathItems;
   }

Reply via email to