Atmosphere long polling

Hi,

This is the usual “I’m doing something without understanding it at all” post, so apologies up front.

I’ve been writing some performance tests with Gatling and until now it’s all gone well. However, I’m trying to test a page with some sort of ajax request - and the ‘proceed’ button (the element I need to click to proceed in the app) is only enabled once this request has finished.

The test times out when trying to replicate the request, even though it’s almost instant on the actual page. The Gatling recorder also gives up at this point.

The bit that I think is causing the problem:

emptyChain.execWithDefaults(
http(“Continue Atmosphere”)
.get("")
.headers(continueHeaders)
.queryParam(""“X-Atmosphere-Transport”"", “”“long-polling”"")
.queryParam(""“X-Atmosphere-Framework”"", “”“2.1.4-javascript”"")
.queryParam(""“X-Atmosphere-TrackMessageSize”"", “”“true”"")
.queryParam(""“X-atmo-protocol”"", “”“true”"")
.queryParam(""“X-Atmosphere-tracking-id”"", session=>{session}.getAttribute(“trackingId”).toString)

.queryParam(""“X-Cache-Date”"", “”“0"”")
.queryParam("""_""", “”“2"”")
).exec( session => {

session
})

where execWIthDefaults is:

def execWithDefaults(request: GetHttpRequestBuilder): ChainBuilder = {
builder
.exec(
request
.basicAuth(, )
.check(status.is(200))

)
}

And “trackingId” is captured in a previous regex.

Output from the run:

10:08:03.596 [INFO ] c.e.e.g.h.a.HttpRequestAction - Sending Request ‘Continue Atmosphere’: Scenario ‘standard’, UserId #1

10:09:03.617 [WARN ] c.e.e.g.h.a.GatlingAsyncHandler - Request ‘Continue Atmosphere’ failed

java.util.concurrent.TimeoutException: Request timeout of 60000 ms

at com.ning.http.client.providers.netty.timeout.TimeoutTimerTask.expire(TimeoutTimerTask.java:43) [async-http-client-1.8.3.jar:na]

at com.ning.http.client.providers.netty.timeout.RequestTimeoutTimerTask.run(RequestTimeoutTimerTask.java:41) [async-http-client-1.8.3.jar:na]

at org.jboss.netty.util.HashedWheelTimer$HashedWheelTimeout.expire(HashedWheelTimer.java:546) [netty-3.9.0.Final.jar:na]

at org.jboss.netty.util.HashedWheelTimer$Worker.notifyExpiredTimeouts(HashedWheelTimer.java:446) [netty-3.9.0.Final.jar:na]

at org.jboss.netty.util.HashedWheelTimer$Worker.run(HashedWheelTimer.java:395) [netty-3.9.0.Final.jar:na]

at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108) [netty-3.9.0.Final.jar:na]

at java.lang.Thread.run(Thread.java:745) [na:1.7.0_55]

10:09:03.620 [WARN ] c.e.e.g.h.a.GatlingAsyncHandlerActor - Request ‘Continue Atmosphere’ failed : Request timeout of 60000 ms

10:09:03.621 [TRACE] c.e.e.g.h.a.GatlingAsyncHandlerActor -

Hi,

Jean-François hates me for that, but I still don’t know much about Atmo…

We’re in RC phase for Gatling 2. Have you tried with latest snapshot?
https://oss.sonatype.org/content/repositories/snapshots/io/gatling/highcharts/gatling-charts-highcharts/2.0.0-SNAPSHOT/

Is there any way you can share a reproducer, please?

Cheers,

I haven’t yet tried v2 - I’ll give that a go. Thanks for replying so quickly!