updated interface `health`

This commit is contained in:
Francesco Mangiacrapa 2024-10-15 16:55:16 +02:00
parent d22eba4c0a
commit a1db22e5b8
2 changed files with 12 additions and 1 deletions

View File

@ -30,7 +30,7 @@ public class ConstantsResolver {
public static final String QUERY_PARAM_CONTENT_TYPE = "contentType";
public static final String QUERY_PARAM_FILE_NAME = "fileName";
public static final String[] resourcesHardCoded = { "ctlg", "metrics" };
public static final String[] resourcesHardCoded = { "ctlg" };
// The default resource candidate to manage the input requests not matching any
// resolver services

View File

@ -1,5 +1,6 @@
package org.gcube.datatransfer.resolver.services;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import org.eclipse.microprofile.health.HealthCheck;
@ -7,7 +8,17 @@ import org.eclipse.microprofile.health.HealthCheckResponse;
@Path("health")
public class UriResolverHealthCheck implements HealthCheck {
@Override
/**
* Index.
*
* @param req the req
* @return the input stream
* @throws WebApplicationException the web application exception
*/
@GET
@Path("")
public HealthCheckResponse call() {
return HealthCheckResponse.named("uri-resolver").up().build();
}