Search in sources :

Example 1 with JacksonJsonProvider

use of io.swagger.jaxrs.json.JacksonJsonProvider in project ff4j by ff4j.

the class ClientHttpJersey1Utils method buildJersey1Client.

/**
 * Initializing jerseyClient.
 */
public static Client buildJersey1Client() {
    ClientConfig config = new DefaultClientConfig();
    config.getFeatures().put(JSONConfiguration.FEATURE_POJO_MAPPING, Boolean.TRUE);
    config.getSingletons().add(new JacksonJsonProvider());
    config.getSingletons().add(new FF4jJacksonMapper());
    return Client.create(config);
}
Also used : DefaultClientConfig(com.sun.jersey.api.client.config.DefaultClientConfig) FF4jJacksonMapper(org.ff4j.web.api.FF4jJacksonMapper) JacksonJsonProvider(io.swagger.jaxrs.json.JacksonJsonProvider) DefaultClientConfig(com.sun.jersey.api.client.config.DefaultClientConfig) ClientConfig(com.sun.jersey.api.client.config.ClientConfig)

Aggregations

ClientConfig (com.sun.jersey.api.client.config.ClientConfig)1 DefaultClientConfig (com.sun.jersey.api.client.config.DefaultClientConfig)1 JacksonJsonProvider (io.swagger.jaxrs.json.JacksonJsonProvider)1 FF4jJacksonMapper (org.ff4j.web.api.FF4jJacksonMapper)1