Package org.apache.cxf.jaxrs.client

Examples of org.apache.cxf.jaxrs.client.ClientConfiguration


    * @param root
    *           The resource returned by the build() method of this builder
    *           class
    */
   public static void closeClient(ApiRootResource root) {
      ClientConfiguration config = WebClient.getConfig(root);
      HTTPConduit conduit = config.getHttpConduit();
      if (conduit == null) {
         throw new IllegalArgumentException(
               "Client is not using the HTTP transport");
      }
      conduit.close();
View Full Code Here


      bean.setResourceClass(proxyType);
      bean.setProvider(new JacksonJsonProvider(new ApiObjectMapper()));

      T rootResource = bean.create(proxyType);
      ClientConfiguration config = WebClient.getConfig(rootResource);
      HTTPConduit conduit = (HTTPConduit) config.getConduit();
      if (isTlsEnabled) {
         TLSClientParameters tlsParams = new TLSClientParameters();
         if (!validateCerts) {
            tlsParams
                  .setTrustManagers(new TrustManager[] { new AcceptAllTrustManager() });
View Full Code Here

    * @param root
    *           The resource returned by the build() method of this builder
    *           class
    */
   public static void closeClient(ApiRootResource root) {
      ClientConfiguration config = WebClient.getConfig(root);
      HTTPConduit conduit = config.getHttpConduit();
      if (conduit == null) {
         throw new IllegalArgumentException(
               "Client is not using the HTTP transport");
      }
      conduit.close();
View Full Code Here

    private WebClient setupWebClient( String jiraUrl )
    {
        WebClient client = WebClient.create( jiraUrl );

        ClientConfiguration clientConfiguration = WebClient.getConfig( client );
        HTTPConduit http = clientConfiguration.getHttpConduit();
        // MCHANGES-324 - Maintain the client session
        clientConfiguration.getRequestContext().put( Message.MAINTAIN_SESSION, Boolean.TRUE );

        if ( getLog().isDebugEnabled() )
        {
            clientConfiguration.getInInterceptors().add( new LoggingInInterceptor(  ) );
            clientConfiguration.getOutInterceptors().add( new LoggingOutInterceptor(  ) );
        }

        HTTPClientPolicy httpClientPolicy = new HTTPClientPolicy();

        // MCHANGES-341 Externalize JIRA server timeout values to the configuration section
View Full Code Here

TOP

Related Classes of org.apache.cxf.jaxrs.client.ClientConfiguration

Copyright © 2018 www.massapicom. 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.