[ 
https://issues.apache.org/jira/browse/CAMEL-13707?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16878144#comment-16878144
 ] 

Eloy Coto commented on CAMEL-13707:
-----------------------------------

[~bedla]

 
{code:java}
localhost.localdomain ➜  camel-netty-proxy git:(master) 
http_proxy=http://localhost:8080 curl -v "http://neverssl.com?user=123";
* Uses proxy env variable http_proxy == 'http://localhost:8080'
*   Trying ::1...
* TCP_NODELAY set
* Connected to localhost (::1) port 8080 (#0)
> GET http://neverssl.com/?user=123 HTTP/1.1
> Host: neverssl.com
> User-Agent: curl/7.64.0
> Accept: */*
> Proxy-Connection: Keep-Alive
>
< HTTP/1.1 400 Bad Request
< content-length: 3674
< Server: CloudFront
< X-Amz-Cf-Id: j8XHKtmGAuH4Q51gu8zVnWIISEz-3qL8C47D4FvLFXn5bj4yJsVqvw==
< X-Amz-Cf-Pop: MAD51-C1
< X-Cache: Error from cloudfront
< content-type: text/plain
< connection: close
<
org.apache.camel.component.netty4.http.NettyHttpOperationFailedException: Netty 
HTTP operation failed invoking http://neverssl.com:80 with statusCode: 400
        at 
org.apache.camel.component.netty4.http.NettyHttpHelper.populateNettyHttpOperationFailedException(NettyHttpHelper.java:160)
        at 
org.apache.camel.component.netty4.http.NettyHttpProducer$NettyHttpProducerCallback.done(NettyHttpProducer.java:141)
        at 
org.apache.camel.component.netty4.NettyProducer$NettyProducerCallback.done(NettyProducer.java:541)
        at 
org.apache.camel.component.netty4.handlers.ClientChannelHandler.channelRead0(ClientChannelHandler.java:210)
        at 
io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
        at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352)
        at 
io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
        at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352)
        at 
io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:301)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
        at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352)
        at 
io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:438)
        at 
io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:323)
        at 
io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:297)
        at 
io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:253)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
        at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352)
        at 
io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1408)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374)
        at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360)
        at 
io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:930)
        at 
io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:163)
        at 
io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:682)
        at 
io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:617)
        at 
io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:534)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496)
        at 
io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:906)
        at 
io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
        at java.lang.Thread.run(Thread.java:748)
* Closing connection 0{code}

> Query string issues
> -------------------
>
>                 Key: CAMEL-13707
>                 URL: https://issues.apache.org/jira/browse/CAMEL-13707
>             Project: Camel
>          Issue Type: Bug
>            Reporter: Eloy Coto
>            Priority: Minor
>
> Test environment:
>  
> [https://github.com/zregvart/camel-netty-proxy]
> running the readme, all ok,
>  
> running the following command, no connection and the following error message: 
> {code:java}
> $ http_proxy=http://localhost:8080 curl -v "http://neverssl.co?user=123m"; * 
> Uses proxy env variable http_proxy == 'http://localhost:8080' * Trying ::1... 
> * TCP_NODELAY set * Connected to localhost (::1) port 8080 (#0) > GET 
> http://neverssl.co/?user=123m HTTP/1.1 > Host: neverssl.co > User-Agent: 
> curl/7.64.0 > Accept: */* > Proxy-Connection: Keep-Alive > ^C {code}
> Log output:
> {code:java}
> 2019-07-01 08:23:55 [Camel Thread #11 - NettyClientTCPWorker] WARN 
> i.n.util.concurrent.DefaultPromise - An exception was thrown by 
> org.apache.camel.component.netty4.NettyProducer$ChannelConnectedListener.operationComplete()
>  io.netty.util.IllegalReferenceCountException: refCnt: 0, decrement: 1 at 
> io.netty.util.internal.ReferenceCountUpdater.toLiveRealRefCnt(ReferenceCountUpdater.java:74)
>  at 
> io.netty.util.internal.ReferenceCountUpdater.release(ReferenceCountUpdater.java:138)
>  at 
> io.netty.buffer.AbstractReferenceCountedByteBuf.release(AbstractReferenceCountedByteBuf.java:100)
>  at 
> io.netty.handler.codec.http.HttpObjectAggregator$AggregatedFullHttpMessage.release(HttpObjectAggregator.java:386)
>  at io.netty.util.ReferenceCountUtil.release(ReferenceCountUtil.java:88) at 
> org.apache.camel.component.netty4.NettyProducer$BodyReleaseCallback.done(NettyProducer.java:663)
>  at 
> org.apache.camel.component.netty4.NettyProducer$ChannelConnectedListener.operationComplete(NettyProducer.java:631)
>  at 
> org.apache.camel.component.netty4.NettyProducer$ChannelConnectedListener.operationComplete(NettyProducer.java:612)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:502)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListeners0(DefaultPromise.java:495)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListenersNow(DefaultPromise.java:474)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListeners(DefaultPromise.java:415)
>  at 
> io.netty.util.concurrent.DefaultPromise.setValue0(DefaultPromise.java:540) at 
> io.netty.util.concurrent.DefaultPromise.setFailure0(DefaultPromise.java:533) 
> at 
> io.netty.util.concurrent.DefaultPromise.setFailure(DefaultPromise.java:106) 
> at 
> io.netty.channel.DefaultChannelPromise.setFailure(DefaultChannelPromise.java:89)
>  at io.netty.bootstrap.Bootstrap.doResolveAndConnect0(Bootstrap.java:216) at 
> io.netty.bootstrap.Bootstrap.access$000(Bootstrap.java:49) at 
> io.netty.bootstrap.Bootstrap$1.operationComplete(Bootstrap.java:188) at 
> io.netty.bootstrap.Bootstrap$1.operationComplete(Bootstrap.java:174) at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:502)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListenersNow(DefaultPromise.java:476)
>  at 
> io.netty.util.concurrent.DefaultPromise.notifyListeners(DefaultPromise.java:415)
>  at 
> io.netty.util.concurrent.DefaultPromise.setValue0(DefaultPromise.java:540) at 
> io.netty.util.concurrent.DefaultPromise.setSuccess0(DefaultPromise.java:529) 
> at 
> io.netty.util.concurrent.DefaultPromise.trySuccess(DefaultPromise.java:101) 
> at 
> io.netty.channel.DefaultChannelPromise.trySuccess(DefaultChannelPromise.java:84)
>  at 
> io.netty.channel.AbstractChannel$AbstractUnsafe.safeSetSuccess(AbstractChannel.java:1009)
>  at 
> io.netty.channel.AbstractChannel$AbstractUnsafe.register0(AbstractChannel.java:517)
>  at 
> io.netty.channel.AbstractChannel$AbstractUnsafe.access$200(AbstractChannel.java:428)
>  at 
> io.netty.channel.AbstractChannel$AbstractUnsafe$1.run(AbstractChannel.java:487)
>  at 
> io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
>  at 
> io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:405)
>  at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) at 
> io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:906)
>  at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) 
> at java.lang.Thread.run(Thread.java:748){code}
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to