From 9932d3b8395e46ebe57a2a1a95596661a1754896 Mon Sep 17 00:00:00 2001 From: Michael Dürre Date: Fri, 14 Apr 2023 14:14:46 +0200 Subject: fix apigateway servlets MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix missing whiteboard patterns Issue-ID: CCSDK-3890 Change-Id: I8d127d9a8b97ed91fb74a9ee384d3b4d07c9e242 Signed-off-by: Michael Dürre Signed-off-by: highstreetherbert --- sdnr/wt/apigateway/provider/pom.xml | 6 +++++ .../features/sdnr/wt/apigateway/EsServlet.java | 7 +++++ .../sdnr/wt/apigateway/SitedocServlet.java | 7 +++++ .../sdnr/wt/apigateway/TerrainServlet.java | 7 +++++ .../features/sdnr/wt/apigateway/TilesServlet.java | 7 +++++ .../sdnr/wt/apigateway/TopologyServlet.java | 7 +++++ .../org/opendaylight/blueprint/blueprint.xml | 30 ++-------------------- 7 files changed, 43 insertions(+), 28 deletions(-) (limited to 'sdnr') diff --git a/sdnr/wt/apigateway/provider/pom.xml b/sdnr/wt/apigateway/provider/pom.xml index 1a682eb67..6c69cd7dd 100644 --- a/sdnr/wt/apigateway/provider/pom.xml +++ b/sdnr/wt/apigateway/provider/pom.xml @@ -69,6 +69,12 @@ ${project.version} provided + + org.osgi + osgi.cmpn + 7.0.0 + compile + diff --git a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/EsServlet.java b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/EsServlet.java index f3871a5c4..e1a9ae0f8 100644 --- a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/EsServlet.java +++ b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/EsServlet.java @@ -21,10 +21,17 @@ package org.onap.ccsdk.features.sdnr.wt.apigateway; import java.io.IOException; +import javax.servlet.Servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.osgi.service.component.annotations.Component; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletName; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletPattern; +@HttpWhiteboardServletPattern("/database/*") +@HttpWhiteboardServletName("EsServlet") +@Component(service = Servlet.class) public class EsServlet extends BaseServlet { private static final long serialVersionUID = -3996363343749995011L; diff --git a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/SitedocServlet.java b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/SitedocServlet.java index 347dbb0d3..d96ddb613 100644 --- a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/SitedocServlet.java +++ b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/SitedocServlet.java @@ -21,10 +21,17 @@ package org.onap.ccsdk.features.sdnr.wt.apigateway; import java.io.IOException; +import javax.servlet.Servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.osgi.service.component.annotations.Component; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletName; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletPattern; +@HttpWhiteboardServletPattern("/sitedoc/*") +@HttpWhiteboardServletName("SitedocServlet") +@Component(service = Servlet.class) public class SitedocServlet extends BaseServlet { private static final long serialVersionUID = 5946205120796162644L; diff --git a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TerrainServlet.java b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TerrainServlet.java index 12954c647..5b5cc8ab9 100644 --- a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TerrainServlet.java +++ b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TerrainServlet.java @@ -21,10 +21,17 @@ package org.onap.ccsdk.features.sdnr.wt.apigateway; import java.io.IOException; +import javax.servlet.Servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.osgi.service.component.annotations.Component; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletName; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletPattern; +@HttpWhiteboardServletPattern("/terrain/*") +@HttpWhiteboardServletName("TerrainServlet") +@Component(service = Servlet.class) public class TerrainServlet extends BaseServlet { private static final long serialVersionUID = 5946205120796162644L; diff --git a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TilesServlet.java b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TilesServlet.java index a29717a73..1978d7c6f 100644 --- a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TilesServlet.java +++ b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TilesServlet.java @@ -21,10 +21,17 @@ package org.onap.ccsdk.features.sdnr.wt.apigateway; import java.io.IOException; +import javax.servlet.Servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.osgi.service.component.annotations.Component; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletName; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletPattern; +@HttpWhiteboardServletPattern("/tiles/*") +@HttpWhiteboardServletName("TilesServlet") +@Component(service = Servlet.class) public class TilesServlet extends BaseServlet { private static final long serialVersionUID = 5946205120796162644L; diff --git a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TopologyServlet.java b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TopologyServlet.java index 1a8187640..0350d966b 100644 --- a/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TopologyServlet.java +++ b/sdnr/wt/apigateway/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/apigateway/TopologyServlet.java @@ -21,10 +21,17 @@ package org.onap.ccsdk.features.sdnr.wt.apigateway; import java.io.IOException; +import javax.servlet.Servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.osgi.service.component.annotations.Component; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletName; +import org.osgi.service.http.whiteboard.propertytypes.HttpWhiteboardServletPattern; +@HttpWhiteboardServletPattern("/topology/*") +@HttpWhiteboardServletName("TopologyServlet") +@Component(service = Servlet.class) public class TopologyServlet extends BaseServlet { private static final long serialVersionUID = 5946205120796162644L; diff --git a/sdnr/wt/apigateway/provider/src/main/resources/org/opendaylight/blueprint/blueprint.xml b/sdnr/wt/apigateway/provider/src/main/resources/org/opendaylight/blueprint/blueprint.xml index 37fa4ee9c..a6166b433 100644 --- a/sdnr/wt/apigateway/provider/src/main/resources/org/opendaylight/blueprint/blueprint.xml +++ b/sdnr/wt/apigateway/provider/src/main/resources/org/opendaylight/blueprint/blueprint.xml @@ -26,59 +26,33 @@ class="org.onap.ccsdk.features.sdnr.wt.apigateway.AaiServlet"> - - - - - - - - - - - - - - - - - - - - - - - - - - - + -- cgit 1.2.3-korg