From c5b325344b63932644739de287fadf6e8206a6a1 Mon Sep 17 00:00:00 2001 From: "francesco.mangiacrapa" Date: Mon, 21 Oct 2024 10:43:38 +0200 Subject: [PATCH] Updated gcube-app configuration --- .../geoportal/service/GeoPortalService.java | 2 +- .../service/GeoPortalServiceHealth.java | 34 +++++++++---------- .../src/main/webapp/WEB-INF/gcube-app.xml | 12 +++++++ .../src/main/webapp/WEB-INF/web.xml | 6 +--- 4 files changed, 31 insertions(+), 23 deletions(-) create mode 100644 geoportal-service/src/main/webapp/WEB-INF/gcube-app.xml diff --git a/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalService.java b/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalService.java index 0a4bcb2..7d7e531 100644 --- a/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalService.java +++ b/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalService.java @@ -53,7 +53,7 @@ public class GeoPortalService extends ResourceConfig { registerClasses(ProfiledDocuments.class); registerClasses(UseCaseDescriptors.class); registerClasses(Plugins.class); - //registerClasses(GeoportalHealth.class); + registerClasses(GeoportalHealth.class); // registerClasses(DocsGenerator.class); log.info("Setting implementations .. "); diff --git a/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalServiceHealth.java b/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalServiceHealth.java index 71b187b..09ea94c 100644 --- a/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalServiceHealth.java +++ b/geoportal-service/src/main/java/org/gcube/application/geoportal/service/GeoPortalServiceHealth.java @@ -1,17 +1,17 @@ -package org.gcube.application.geoportal.service; - -import javax.ws.rs.ApplicationPath; - -import org.gcube.application.geoportal.service.rest.GeoportalHealth; -import org.glassfish.jersey.server.ResourceConfig; - -@ApplicationPath("/api") -public class GeoPortalServiceHealth extends ResourceConfig { - - public GeoPortalServiceHealth() { - - registerClasses(GeoportalHealth.class); - - } - -} +//package org.gcube.application.geoportal.service; +// +//import javax.ws.rs.ApplicationPath; +// +//import org.gcube.application.geoportal.service.rest.GeoportalHealth; +//import org.glassfish.jersey.server.ResourceConfig; +// +//@ApplicationPath("/") +//public class GeoPortalServiceHealth extends ResourceConfig { +// +// public GeoPortalServiceHealth() { +// +// registerClasses(GeoportalHealth.class); +// +// } +// +//} diff --git a/geoportal-service/src/main/webapp/WEB-INF/gcube-app.xml b/geoportal-service/src/main/webapp/WEB-INF/gcube-app.xml new file mode 100644 index 0000000..41ab521 --- /dev/null +++ b/geoportal-service/src/main/webapp/WEB-INF/gcube-app.xml @@ -0,0 +1,12 @@ + + + + ${project.artifactId} + ${project.groupId} + ${project.version} + ${project.description} + + + /src/health + + diff --git a/geoportal-service/src/main/webapp/WEB-INF/web.xml b/geoportal-service/src/main/webapp/WEB-INF/web.xml index 078da9f..ef51265 100644 --- a/geoportal-service/src/main/webapp/WEB-INF/web.xml +++ b/geoportal-service/src/main/webapp/WEB-INF/web.xml @@ -29,11 +29,7 @@ default /api-docs/* - - default - /api/health - - + org.gcube.application.geoportal.service.GeoPortalService