You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streampipes.apache.org by fj...@apache.org on 2020/06/26 14:07:31 UTC

[incubator-streampipes] branch datalake-rest-extension created (now d36a353)

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

fjohn pushed a change to branch datalake-rest-extension
in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git.


      at d36a353  WIP: Datalake-Rest-Extension

This branch includes the following new commits:

     new d36a353  WIP: Datalake-Rest-Extension

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[incubator-streampipes] 01/01: WIP: Datalake-Rest-Extension

Posted by fj...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

fjohn pushed a commit to branch datalake-rest-extension
in repository https://gitbox.apache.org/repos/asf/incubator-streampipes.git

commit d36a35340673c6a448bd4822ec9ea82af6d2dedb
Author: Felix John <jo...@axantu.com>
AuthorDate: Fri Jun 26 16:07:15 2020 +0200

    WIP: Datalake-Rest-Extension
---
 .../streampipes/rest/impl/datalake/DataLakeManagementV3.java   |  1 +
 .../streampipes/rest/impl/datalake/DataLakeResourceV3.java     | 10 ++++++++--
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeManagementV3.java b/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeManagementV3.java
index 7417b92..b1ff0e3 100644
--- a/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeManagementV3.java
+++ b/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeManagementV3.java
@@ -517,6 +517,7 @@ public class DataLakeManagementV3 {
             .readTimeout(120, TimeUnit.SECONDS)
             .writeTimeout(120, TimeUnit.SECONDS);
 
+    
     return InfluxDBFactory.connect(BackendConfig.INSTANCE.getInfluxUrl(), okHttpClientBuilder);
   }
 
diff --git a/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeResourceV3.java b/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeResourceV3.java
index 285a65d..0d2ec1e 100644
--- a/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeResourceV3.java
+++ b/streampipes-rest/src/main/java/org/apache/streampipes/rest/impl/datalake/DataLakeResourceV3.java
@@ -113,6 +113,14 @@ public class DataLakeResourceV3 extends AbstractRestInterface {
   }
 
   @GET
+  @Path("/data/{index}/delete")
+  // @Produces(MediaType.APPLICATION_JSON)
+  public void deleteMeasurement(@PathParam("index") String index) {
+    dataLakeManagement.deleteMeasurement(index);
+    // return ok("John");
+  }
+
+  @GET
   @Produces(MediaType.APPLICATION_JSON)
   @Path("/data/{index}/last/{value}/{unit}")
   public Response getAllData(@PathParam("index") String index,
@@ -239,6 +247,4 @@ public class DataLakeResourceV3 extends AbstractRestInterface {
 
         return Response.ok("Successfully updated database.", MediaType.TEXT_PLAIN).build();
   }
-
-
 }