use of io.helidon.webserver.jersey.JerseySupport in project helidon by oracle.
the class JerseyPropertiesTest method testIgnoreExceptionResponseOverride.
@Test
void testIgnoreExceptionResponseOverride() {
JerseySupport jerseySupport = JerseySupport.builder().config(config).build();
assertNotNull(jerseySupport);
assertThat(System.getProperty(IGNORE_EXCEPTION_RESPONSE), is("false"));
}
use of io.helidon.webserver.jersey.JerseySupport in project helidon by oracle.
the class ServerCdiExtension method addApplication.
private void addApplication(JaxRsCdiExtension jaxRs, JaxRsApplication applicationMeta, InjectionManager injectionManager) {
LOGGER.info("Registering JAX-RS Application: " + applicationMeta.appName());
Optional<String> contextRoot = jaxRs.findContextRoot(config, applicationMeta);
Optional<String> namedRouting = jaxRs.findNamedRouting(config, applicationMeta);
boolean routingNameRequired = jaxRs.isNamedRoutingRequired(config, applicationMeta);
if (LOGGER.isLoggable(Level.FINEST)) {
LOGGER.finest("Application " + applicationMeta.appName() + ", class: " + applicationMeta.appClassName() + ", contextRoot: " + contextRoot + ", namedRouting: " + namedRouting + ", routingNameRequired: " + routingNameRequired);
}
Routing.Builder routing = routingBuilder(namedRouting, routingNameRequired, applicationMeta.appName());
JerseySupport jerseySupport = jaxRs.toJerseySupport(jaxRsExecutorService, applicationMeta, injectionManager);
if (contextRoot.isPresent()) {
String contextRootString = contextRoot.get();
LOGGER.fine(() -> "JAX-RS application " + applicationMeta.appName() + " registered on '" + contextRootString + "'");
routing.register(contextRootString, jerseySupport);
} else {
LOGGER.fine(() -> "JAX-RS application " + applicationMeta.appName() + " registered on '/'");
routing.register(jerseySupport);
}
jerseySupports.add(jerseySupport);
}
Aggregations