Uploaded image for project: 'HttpComponents HttpCore'
  1. HttpComponents HttpCore
  2. HTTPCORE-460

Add factory methods to DefaultHttpClientIODispatch to handle a null SSLContext

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 4.4.7
    • None
    • None

    Description

      Add factory methods to DefaultHttpClientIODispatch to handle a null SSLContext:

          /**
           * Creates a new instance of this class to be used for dispatching I/O event
           * notifications to the given protocol handler.
           *
           * @param handler the client protocol handler.
           * @param sslContext an SSLContext or null (for a plain text connection.)
           * @param config a connection configuration
           * @return a new instance
           * @since 4.4.7
           */
          public static DefaultHttpClientIODispatch create(final NHttpClientEventHandler handler,
                  final SSLContext sslContext,
                  final ConnectionConfig config) {
              return sslContext == null ? new DefaultHttpClientIODispatch(handler, config)
                      : new DefaultHttpClientIODispatch(handler, sslContext, config);
          }
          
          /**
           * Creates a new instance of this class to be used for dispatching I/O event
           * notifications to the given protocol handler.
           *
           * @param handler the client protocol handler.
           * @param sslContext an SSLContext or null (for a plain text connection.)
           * @param sslHandler customizes various aspects of the TLS/SSL protocol.
           * @param config a connection configuration
           * @return a new instance
           * @since 4.4.7
           */
          public static DefaultHttpClientIODispatch create(final NHttpClientEventHandler handler,
                  final SSLContext sslContext,
                  final SSLSetupHandler sslHandler,
                  final ConnectionConfig config) {
              return sslContext == null ? new DefaultHttpClientIODispatch(handler, config)
                      : new DefaultHttpClientIODispatch(handler, sslContext, sslHandler, config);
          }
      

      Attachments

        Issue Links

          Activity

            People

              ggregory Gary D. Gregory
              ggregory Gary D. Gregory
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: