Problems running with build from master branch

1,361 views
Skip to first unread message

Luke Taylor

unread,
Jan 30, 2012, 3:31:51 PM1/30/12
to gat...@googlegroups.com
Hi,

I've built Gatling from the lastest master branch but keep running into a NoClassDefFoundError:

Simulation basic-script-exampleATdefault.txt started...
Simulation Finished.
Generating reports...
Exception in thread "main" java.lang.NoClassDefFoundError: com/excilys/ebi/gatling/charts/component/impl/ComponentLibraryImpl
    at com.excilys.ebi.gatling.charts.report.ReportsGenerator$.<init>(ReportsGenerator.scala:60)
    at com.excilys.ebi.gatling.charts.report.ReportsGenerator$.<clinit>(ReportsGenerator.scala)

I get the same problem even if I checkout a commit from two weeks back (fa96d20608e).

Is it expected that report generation is broken on master at the moment, or is this likely to be something weird with my local setup?

I'm using OSX, java 1.6.0_29

Cheers,

Luke

Stéphane Landelle

unread,
Jan 30, 2012, 4:07:25 PM1/30/12
to gat...@googlegroups.com
Hi Luke,

We have to add a section in the Wiki describing how to build Gatling from sources and a link in the FAQ...

Here's the problem :
  • Gatling is not "completely" open-source: the reports depend on javascript libraries (highcharts and highstocks) that are not open source (we couldn't find a good Apache 2 licenced replacement yet)
  • As we wanted to keep as much code as possible under Apache 2, we built a reports generation API and moved the implementation into a separate project : https://github.com/excilys/gatling-highcharts
  • So if you want to build from source, the procedure is similar to running from the IDE: https://github.com/excilys/gatling/wiki/Development-Environment, you have to build gatling-highcharts too. The bundle you're looking for is gatling-charts-highcharts-bundle.
Let me know if you're still stuck.

Sincerely,

Stephane

2012/1/30 Luke Taylor <munkym...@gmail.com>

Luke Taylor

unread,
Jan 31, 2012, 10:50:04 AM1/31/12
to gat...@googlegroups.com
Great, thanks!

I get it now, and it seems to be working fine. I did notice a small problem with looping. If I use a "times(n)" loop, it works ok, but changing it to "during(n)" causes an exception:

[ERROR]   [1/31/12 3:41 PM] [akka:event-driven:dispatcher:global-10] [LocalActorRef] You must call startCounter before this method is called
java.lang.IllegalAccessError: You must call startCounter before this method is called
    at com.excilys.ebi.gatling.core.session.handler.CounterBasedIterationHandler$$anonfun$3.apply(CounterBasedterationHandler.scala:65)
    at com.excilys.ebi.gatling.core.session.handler.CounterBasedIterationHandler$$anonfun$3.apply(CounterBasedterationHandler.scala:65)

Script:

val urlBase = "http://localhost:8080/"

val httpConf = httpConfig.baseURL(urlBase)

val blah = scenario("VMC Login")
    .loop(
        chain.exec(
            http("request_1")
            .get("/")
            .check(status.eq(200))
        )
        .pause(50, 500, MILLISECONDS)
    ).during(20)

val scnConf = blah.configure users 2 protocolConfig httpConf

runSimulation(scnConf)

Stéphane Landelle

unread,
Jan 31, 2012, 11:03:09 AM1/31/12
to gat...@googlegroups.com
I probably missed something when I made the Sessions properly immutable last week.
I'll fix this ASAP.

2012/1/31 Luke Taylor <munkym...@gmail.com>

Stéphane Landelle

unread,
Jan 31, 2012, 11:07:28 AM1/31/12
to gat...@googlegroups.com
Pushed!
Can you give it a try, please?

2012/1/31 Stéphane Landelle <slan...@excilys.com>

Luke Taylor

unread,
Jan 31, 2012, 12:37:24 PM1/31/12
to gat...@googlegroups.com
Thanks! That seems to be working now. Looks nice :).

One other thing I've not been able to get working is specifying a custom simluations folder on the command line:

$GATLING_HOME/bin/gatling.sh -sf /Users/luke/blah/gatling/simulations
GATLING_HOME already set to: /Users/luke/Work/tools/gatling-charts-highcharts-1.1.0-SNAPSHOT
-----------
Gatling cli
-----------

Exception in thread "main" java.util.NoSuchElementException: next on empty iterator
    at scala.collection.Iterator$$anon$3.next(Iterator.scala:28)
    at scala.collection.Iterator$$anon$3.next(Iterator.scala:26)
    at scala.collection.Iterator$$anon$22.next(Iterator.scala:395)
    at scala.collection.Iterator$Partner$1.next(Iterator.scala:946)
    at com.excilys.ebi.gatling.app.Gatling$.com$excilys$ebi$gatling$app$Gatling$$displayMenu(Gatling.scala:126)
    at com.excilys.ebi.gatling.app.Gatling$$anonfun$main$1.apply$mcV$sp(Gatling.scala:84)
    at com.excilys.ebi.gatling.app.Gatling$$anonfun$main$1.apply(Gatling.scala:77)
    at com.excilys.ebi.gatling.app.Gatling$$anonfun$main$1.apply(Gatling.scala:77)
    at scala.Option.getOrElse(Option.scala:108)
    at com.excilys.ebi.gatling.app.Gatling$.main(Gatling.scala:76)

Does that work for you?

Stéphane Landelle

unread,
Jan 31, 2012, 1:20:13 PM1/31/12
to gat...@googlegroups.com
@Romain, can you have a look at this?

2012/1/31 Luke Taylor <munkym...@gmail.com>

Romain Sertelon

unread,
Jan 31, 2012, 1:51:12 PM1/31/12
to gat...@googlegroups.com
Hi Luke,

What is the content of the /Users/luke/blah/gatling/simulations please ?

Issue #374 may be related to yours. I'm checking on that!

Cheers,
Romain

Romain Sertelon

unread,
Jan 31, 2012, 1:56:08 PM1/31/12
to gat...@googlegroups.com
Hi,

What is very strange is that this exception shouldn't even happen... Still searching!

Cheers,
Romain

Luke Taylor

unread,
Jan 31, 2012, 5:10:39 PM1/31/12
to gat...@googlegroups.com
Hi,

Yes, you're right. It seems to happen when there is only one script file. It differs from 374 in that it happens at startup even before the menu is presented.

Cheers,

Luke.

Stéphane Landelle

unread,
Jan 31, 2012, 5:49:56 PM1/31/12
to gat...@googlegroups.com
Hi Luke,

I've pushed the fix.

Thanks for reporting!

Bye,

Stephane

2012/1/31 Luke Taylor <munkym...@gmail.com>
Reply all
Reply to author
Forward
0 new messages