use of org.glassfish.jersey.logging.LoggingFeature in project camel by apache.
the class BonitaAPIUtil method getInstance.
public static BonitaAPIUtil getInstance(BonitaAPIConfig bonitaAPIConfig) {
if (instance == null) {
instance = new BonitaAPIUtil();
ClientConfig clientConfig = new ClientConfig();
clientConfig.register(MultiPartFeature.class);
clientConfig.register(JacksonJsonProvider.class);
Logger logger = Logger.getLogger("org.bonitasoft.camel.bonita.api.util.BonitaAPIUtil");
Feature feature = new LoggingFeature(logger, Level.INFO, null, null);
clientConfig.register(feature);
ClientBuilder clientBuilder = ClientBuilder.newBuilder().withConfig(clientConfig);
Client client = clientBuilder.build();
client.register(new JsonClientFilter());
client.register(new BonitaAuthFilter(bonitaAPIConfig));
instance.setWebTarget(client.target(bonitaAPIConfig.getBaseBonitaURI()));
}
return instance;
}
use of org.glassfish.jersey.logging.LoggingFeature in project jersey by jersey.
the class AsyncJaxrsApplication method getSingletons.
@Override
public Set<Object> getSingletons() {
final HashSet<Object> instances = new HashSet<Object>();
instances.add(new LoggingFeature(Logger.getLogger(AsyncJaxrsApplication.class.getName()), LoggingFeature.Verbosity.PAYLOAD_ANY));
return instances;
}
use of org.glassfish.jersey.logging.LoggingFeature in project jersey by jersey.
the class ErrorTest method configure.
@Override
protected Application configure() {
ResourceConfig config = new ResourceConfig(ErrorResource.class);
config.register(new LoggingFeature(LOGGER, LoggingFeature.Verbosity.PAYLOAD_ANY));
return config;
}
use of org.glassfish.jersey.logging.LoggingFeature in project jersey by jersey.
the class AsyncTest method configureClient.
@Override
protected void configureClient(final ClientConfig config) {
config.register(new LoggingFeature(LOGGER, LoggingFeature.Verbosity.PAYLOAD_ANY));
config.connectorProvider(new GrizzlyConnectorProvider());
}
use of org.glassfish.jersey.logging.LoggingFeature in project jersey by jersey.
the class FollowRedirectsTest method configure.
@Override
protected Application configure() {
ResourceConfig config = new ResourceConfig(RedirectResource.class);
config.register(new LoggingFeature(LOGGER, LoggingFeature.Verbosity.PAYLOAD_ANY));
return config;
}
Aggregations