exceptions thrown while recording

While recording some scripts, I noticed several exceptions are thrown quite often:

Nov 27, 2012 5:17:23 PM org.jboss.netty.channel.SimpleChannelHandler
WARNING: EXCEPTION, please implement com.excilys.ebi.gatling.recorder.http.handler.ServerHttpResponseHandler.exceptionCaught() for proper handling.
java.io.IOException: An existing connection was forcibly closed by the remote host
at sun.nio.ch.SocketDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:25)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:198)
at sun.nio.ch.IOUtil.read(IOUtil.java:166)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:245)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:59)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.processSelectedKeys(AbstractNioWorker.java:471)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:332)
at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:35)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
Nov 27, 2012 5:17:36 PM org.jboss.netty.channel.SimpleChannelHandler
WARNING: EXCEPTION, please implement com.excilys.ebi.gatling.recorder.http.handler.ServerHttpResponseHandler.exceptionCaught() for proper handling.
java.io.IOException: An existing connection was forcibly closed by the remote host
at sun.nio.ch.SocketDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:25)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:198)
at sun.nio.ch.IOUtil.read(IOUtil.java:166)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:245)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:59)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.processSelectedKeys(AbstractNioWorker.java:471)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:332)
at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:35)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
Nov 27, 2012 5:19:20 PM org.jboss.netty.channel.SimpleChannelHandler
WARNING: EXCEPTION, please implement com.excilys.ebi.gatling.recorder.http.handler.ServerHttpResponseHandler.exceptionCaught() for proper handling.
java.io.IOException: An existing connection was forcibly closed by the remote host
at sun.nio.ch.SocketDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:25)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:198)
at sun.nio.ch.IOUtil.read(IOUtil.java:166)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:245)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:59)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.processSelectedKeys(AbstractNioWorker.java:471)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:332)
at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:35)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)

Has anyone else seen this?

FYI, this is exception is thrown from recording in HTTPS. I did try to manually add an exception to the sites listed on the recorded. When I fire up the recorder again, I still see these hosts as requiring certificates.

Implementing a man-in-the-middle over HTTPS is a real pain and will become more and more difficult as browsers enforce security.
That’s why we’re considering building a new component that would transform HAR files:
https://github.com/excilys/gatling/issues/827

For the time being, we’ll have to cope with the recorder.

Regarding the exceptions you get: it seems that your server closed the connection, don’t know why though.
Regarding the recorder keeping on listing the sites, even though you accepted the certificate, that’s normal. Maybe the message is not clear enough: “hosts requiring accepting a certificate” doesn’t mean “hosts which you don’t have accepted the certificate yet”.

Cheers,

Stéphane

Thanks for update! Yes, it’s indeed the recorder as I was able to try the same thing on JMeter’s HTTP Proxy. I had to monkey with JMeter’s settings (‘HttpClient 3.1’ is set over ‘Java’) which did the trick. JMeter also has a setting for spoofing HTTPS but this setting didn’t come into play.

When I was recording, there are some connections being dropped, thus the web pages do not fully appear on the browser. This prevents the full recording to complete. I am going script the simulation manually to get around some things.

Is there any chance I can access your website and try to reproduce and investigate?

Hmm… I don’t know if this is possible at least on our load test servers. Aside, I am currently new to this company so I need to ask around if this can be done.

I’ll update keep you guys posted … maybe I can find the answer or give more specifics.

If it's complicated, don't bother. I'll try to find a website where I can
reproduce.

I am facing the same issue when trying to record of my local site. Any fixes for this yet?

Thanks

Rishi Davda

Your stacktrace shows “com.excilys.ebi” which means you’re still using Gatling 1, which as been dead for 2 years.
Please upgrade to latest version, which is 2.2.2 atm.

I am currently on 2.2.2. still have the same issue or maybe something am not quite doing right?

This e-mail and any attachments are confidential and intended solely for the use of the addressee only. If you have received this message in error, you must not copy, distribute or disclose the contents; please notify the sender immediately and delete the message.

This message is attributed to the sender and may not necessarily reflect the view of Travis Perkins Trading Company Limited, 733503, Lodge Way House, Lodge Way, Harlestone Road, Northampton, NN5 7UG or its parent company Travis Perkins plc (Registered in England No. 824821; Lodge Way House, Lodge Way, Harlestone Road, Northampton, NN5 7UG; VAT number 408556737) and any of its subsidiaries. Agreements binding Travis Perkins Trading Company Limited may not be concluded by means of e-mail communication.

**E-mail transmissions are not secure and Travis Perkins Trading accepts no responsibility for changes made to this message after it was sent. Whilst steps have been taken to ensure that this message is virus free, Travis Perkins Trading accepts no liability for infection and recommends that you scan this e-mail and any attachments.**

Ah ok, you’ve resurrected a thread from 2012.
So, no, you don’t have the same issue, but maybe a similar one.
Please create a new thread and provide your exact stacktrace, and a way to reproduce your problem.