use of org.jboss.netty.channel.local.DefaultLocalClientChannelFactory in project databus by linkedin.
the class DummyHttpRequestHandler method setupClient.
private void setupClient() {
_clientBootstrap = new ClientBootstrap(new DefaultLocalClientChannelFactory());
_clientBootstrap.setPipelineFactory(new ChannelPipelineFactory() {
@Override
public ChannelPipeline getPipeline() throws Exception {
ChannelPipeline clientPipeline = pipeline();
clientPipeline.addLast("client logger 1", new LoggingHandler("client logger 1", InternalLogLevel.DEBUG, true));
clientPipeline.addLast("codec", new HttpClientCodec());
clientPipeline.addLast("aggregator", new FooterAwareHttpChunkAggregator(1000000));
_responseHandler = new SimpleHttpResponseHandler();
clientPipeline.addLast("handler", _responseHandler);
clientPipeline.addLast("client logger 5", new LoggingHandler("client logger 5", InternalLogLevel.DEBUG, true));
return clientPipeline;
}
});
}
Aggregations