Package org.glassfish.jersey.client

Examples of org.glassfish.jersey.client.ClientConfig.property()


    clientConfig.property(ClientProperties.FOLLOW_REDIRECTS, false);
    clientConfig.property(ClientProperties.JSON_PROCESSING_FEATURE_DISABLE,
        false);
    clientConfig.property(ClientProperties.METAINF_SERVICES_LOOKUP_DISABLE,
        true);
    clientConfig.property(ClientProperties.MOXY_JSON_FEATURE_DISABLE, true);
    clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER,
        clientConnectionManager);
    clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);
    clientConfig.property(ApacheClientProperties.HTTP_PARAMS, httpParams);
    clientConfig.property(
View Full Code Here


    clientConfig.property(ClientProperties.JSON_PROCESSING_FEATURE_DISABLE,
        false);
    clientConfig.property(ClientProperties.METAINF_SERVICES_LOOKUP_DISABLE,
        true);
    clientConfig.property(ClientProperties.MOXY_JSON_FEATURE_DISABLE, true);
    clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER,
        clientConnectionManager);
    clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);
    clientConfig.property(ApacheClientProperties.HTTP_PARAMS, httpParams);
    clientConfig.property(
        ApacheClientProperties.PREEMPTIVE_BASIC_AUTHENTICATION, false);
View Full Code Here

    clientConfig.property(ClientProperties.METAINF_SERVICES_LOOKUP_DISABLE,
        true);
    clientConfig.property(ClientProperties.MOXY_JSON_FEATURE_DISABLE, true);
    clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER,
        clientConnectionManager);
    clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);
    clientConfig.property(ApacheClientProperties.HTTP_PARAMS, httpParams);
    clientConfig.property(
        ApacheClientProperties.PREEMPTIVE_BASIC_AUTHENTICATION, false);
    return clientConfig;
  }
View Full Code Here

        true);
    clientConfig.property(ClientProperties.MOXY_JSON_FEATURE_DISABLE, true);
    clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER,
        clientConnectionManager);
    clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);
    clientConfig.property(ApacheClientProperties.HTTP_PARAMS, httpParams);
    clientConfig.property(
        ApacheClientProperties.PREEMPTIVE_BASIC_AUTHENTICATION, false);
    return clientConfig;
  }
View Full Code Here

    clientConfig.property(ClientProperties.MOXY_JSON_FEATURE_DISABLE, true);
    clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER,
        clientConnectionManager);
    clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);
    clientConfig.property(ApacheClientProperties.HTTP_PARAMS, httpParams);
    clientConfig.property(
        ApacheClientProperties.PREEMPTIVE_BASIC_AUTHENTICATION, false);
    return clientConfig;
  }

  private PoolingClientConnectionManager createPoolingClientConnectionManager(
View Full Code Here

                                                return property.startsWith(propertyPrefix);
                                            }
                                        });

                                for (String property : clientProperties) {
                                    cfg.property(property.substring(propertyPrefix.length()),
                                            serverConfig.getProperty(property));
                                }

                                return new ManagedClient(ClientBuilder.newClient(cfg), customBaseUri);
                            }
View Full Code Here

     * @return a fully-configured {@link Client}
     */

    public Client build() {
        ClientConfig clientConfig = new ClientConfig();
        clientConfig.property(ClientProperties.READ_TIMEOUT, configuration.getReadTimeout());
        clientConfig.property(ClientProperties.CONNECT_TIMEOUT, configuration.getConnectTimeout());
        clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);

        PoolingHttpClientConnectionManager poolingClientConnectionManager = new PoolingHttpClientConnectionManager();
        poolingClientConnectionManager.setMaxTotal(configuration.getMaxTotalThread());
View Full Code Here

     */

    public Client build() {
        ClientConfig clientConfig = new ClientConfig();
        clientConfig.property(ClientProperties.READ_TIMEOUT, configuration.getReadTimeout());
        clientConfig.property(ClientProperties.CONNECT_TIMEOUT, configuration.getConnectTimeout());
        clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);

        PoolingHttpClientConnectionManager poolingClientConnectionManager = new PoolingHttpClientConnectionManager();
        poolingClientConnectionManager.setMaxTotal(configuration.getMaxTotalThread());
        poolingClientConnectionManager.setDefaultMaxPerRoute(configuration.getDefaultMaxPerRoute());
View Full Code Here

    public Client build() {
        ClientConfig clientConfig = new ClientConfig();
        clientConfig.property(ClientProperties.READ_TIMEOUT, configuration.getReadTimeout());
        clientConfig.property(ClientProperties.CONNECT_TIMEOUT, configuration.getConnectTimeout());
        clientConfig.property(ApacheClientProperties.DISABLE_COOKIES, true);

        PoolingHttpClientConnectionManager poolingClientConnectionManager = new PoolingHttpClientConnectionManager();
        poolingClientConnectionManager.setMaxTotal(configuration.getMaxTotalThread());
        poolingClientConnectionManager.setDefaultMaxPerRoute(configuration.getDefaultMaxPerRoute());
View Full Code Here

        PoolingHttpClientConnectionManager poolingClientConnectionManager = new PoolingHttpClientConnectionManager();
        poolingClientConnectionManager.setMaxTotal(configuration.getMaxTotalThread());
        poolingClientConnectionManager.setDefaultMaxPerRoute(configuration.getDefaultMaxPerRoute());

        clientConfig.property(ApacheClientProperties.CONNECTION_MANAGER, poolingClientConnectionManager);

        ObjectMapper mapper = new ObjectMapper();
        mapper.enable(SerializationFeature.INDENT_OUTPUT);
        mapper.registerModule(new GuavaModule());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.