Class AsyncWithCustomKeystores

  • All Implemented Interfaces:
    HttpAsyncClientBuilderConfig

    @ComponentProfile(since="4.5.0",
                      summary="Allows you to configure custom keystores when building the HttpAsyncClient")
    public class AsyncWithCustomKeystores
    extends java.lang.Object
    implements HttpAsyncClientBuilderConfig
    HttpClientBuilderConfigurator implementation that allows you to customise keystores etc.

    In the adapter configuration file this class is aliased as apache-http-async-client-builder-with-custom-keystores which is the preferred alternative to the fully qualified classname when building your configuration.

    • Constructor Detail

      • AsyncWithCustomKeystores

        public AsyncWithCustomKeystores()
    • Method Detail

      • configure

        public org.apache.http.impl.nio.client.HttpAsyncClientBuilder configure​(org.apache.http.impl.nio.client.HttpAsyncClientBuilder builder)
                                                                         throws java.lang.Exception
        Description copied from interface: HttpAsyncClientBuilderConfig
        Do any additional configuration.
        Specified by:
        configure in interface HttpAsyncClientBuilderConfig
        Parameters:
        builder - the existing builder
        Returns:
        a reconfigured builder.
        Throws:
        java.lang.Exception
      • trustStrategy

        protected org.apache.http.ssl.TrustStrategy trustStrategy()
      • setTruststore

        public void setTruststore​(ConfiguredKeystore truststore)
        The truststore used with TLS
      • setKeystore

        public void setKeystore​(ConfiguredKeystore keystore)
        The keystore used with TLS.
      • setPrivateKeyPassword

        public void setPrivateKeyPassword​(PrivateKeyPasswordProvider privateKeyPassword)
        The private key password.
      • getTrustSelfSigned

        public java.lang.Boolean getTrustSelfSigned()
        Whether or not to trust self signed certificates.

        Defaults to false if not explicitly configured.

      • setTrustSelfSigned

        public void setTrustSelfSigned​(java.lang.Boolean trustSelfSigned)
        Whether or not to trust self signed certificates.

        Defaults to false if not explicitly configured.