@Override protected void initChannel(Channel ch) throws Exception { ch.pipeline()// .addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this))// .addLast(HTTP_HANDLER, newHttpClientCodec())// .addLast(WS_PROCESSOR, wsProcessor); if (nettyConfig.getWssAdditionalPipelineInitializer() != null) nettyConfig.getWssAdditionalPipelineInitializer().initPipeline(ch.pipeline()); } });
public ChannelPipeline getPipeline() throws Exception { ChannelPipeline pipeline = pipeline(); pipeline.addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this)); pipeline.addLast(HTTP_HANDLER, newHttpClientCodec()); pipeline.addLast(WS_PROCESSOR, wsProcessor); if (nettyConfig.getWssAdditionalPipelineInitializer() != null) nettyConfig.getWssAdditionalPipelineInitializer().initPipeline(pipeline); return pipeline; } });
/** * Always make sure the channel who got cached support the proper protocol. * It could only occurs when a HttpMethod. CONNECT is used against a proxy * that requires upgrading from http to https. */ public void verifyChannelPipeline(ChannelPipeline pipeline, String scheme) throws IOException, GeneralSecurityException { boolean sslHandlerConfigured = isSslHandlerConfigured(pipeline); if (isSecure(scheme)) { if (!sslHandlerConfigured) pipeline.addFirst(SSL_HANDLER, new SslInitializer(this)); } else if (sslHandlerConfigured) pipeline.remove(SSL_HANDLER); }
public void verifyChannelPipeline(ChannelPipeline pipeline, String scheme) throws IOException, GeneralSecurityException { boolean sslHandlerConfigured = isSslHandlerConfigured(pipeline); if (isSecure(scheme)) { if (!sslHandlerConfigured) pipeline.addFirst(SSL_HANDLER, new SslInitializer(this)); } else if (sslHandlerConfigured) pipeline.remove(SSL_HANDLER); }
protected void initChannel(Channel ch) throws Exception { .addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this))// protected void initChannel(Channel ch) throws Exception { .addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this))//
pipeline.addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this)); pipeline.addLast(HTTP_HANDLER, newHttpClientCodec()); pipeline.addLast(INFLATER_HANDLER, newHttpContentDecompressor()); pipeline.addLast(SSL_HANDLER, new SslInitializer(ChannelManager.this)); pipeline.addLast(HTTP_HANDLER, newHttpClientCodec()); pipeline.addLast(WS_PROCESSOR, wsProcessor);