Skip to content

Latest commit

 

History

History
103 lines (68 loc) · 3.58 KB

2.0-to-2.1.md

File metadata and controls

103 lines (68 loc) · 3.58 KB
title description lead date lastmod weight
Migrating from 2.0 to 2.1
Gatling migration from 2.0 to 2.1
2021-04-20 18:30:56 +0200
2021-04-20 18:30:56 +0200
1072

Global changes

Scala 2.11

Gatling is now built with Scala 2.11. If you're using Scala IDE, make sure you're using a version compatible with Scala 2.11.

Compiler runs standalone

Gatling itself doesn't compile the Simulations anymore and expects that the simulations are already compiled. This means that gatling.sh/gatling.bat and the Maven plugin runs the compiler prior to running Gatling. Consequently, a few options in gatling.conf have been removed:

  • gatling.core.disableCompiler
  • gatling.core.zinc.jvmArgs

Please note that, as this change implied that the Maven Plugin was heavily modified so that it compiles the simulations separately prior to running Gatling, you'll need to upgrade the Maven Plugin to its version 2.1.0 too.

Percentiles

Gatling now publishes 4 percentiles instead of 2. These percentiles are published in the reports and in the Graphite integration module. Beware that keys in gatling.conf file have been translated:

  • Gatling 2.0:
    • percentile1 = 95
    • percentile2 = 99
  • Gatling 2.1+:
    • percentile1 = 50
    • percentile2 = 75
    • percentile3 = 95
    • percentile4 = 99

Core

Mute mode

The "mute mode" option, which was previously restricted to the SBT Plugin, is now also usable by the bundle scripts and the Maven Archetype.

Assertions

Validating assertions in combination with the reports-only / ro option does not require to pass the simulation (using -s) for which the assertions will be validated anymore.

Throttling

Throttling now automatically adds a maxDuration of either the simulation throttling duration, or the minimum of the scenarios throttling durations.

HTTP

Parameters

Form parameters are no longer specific to POST method, you can use them with all methods.

Request Bodies Directory

The directory name was changed from request-bodies to bodies as it now can host both request bodies and response bodies. The latter one are now captured by the recorder, and can be used as template for [checking the response body]({{< ref "../http/check#http-response-body" >}}).

CLI option was renamed from rbf to bdf.

Checks

Deprecated dontValidate was dropped in 2.1 as previously announced. Please use optional instead.

Protocol

Deprecated baseHeaders was dropped in 2.1 as previously announced. Please use headers instead.

Maven Archetype

Due to some necessary changes to allow Gatling to use Scala 2.11, you'll have to update IDEPathHelper.scala, Engine.scala and Recorder.scala if you're using the Maven archetype.

Either generate a new project with the 2.1.1 archetype (there was a bug in 2.1), or override your classes with the ones here. If you choose the latter, don't forget to fix the simulationPackage in Recorder.scala.

SBT Plugin

The SBT Plugin's test framework has been moved to the core project in 2.1. As a consequence, the test framework name has be modified to follow the naming conventions of all core modules and share its versionning.

The SBT Plugin will also share the same versionning schema as all other Gatling modules, and has been renamed to 'gatling-sbt'.

The new coordinates are therefore :

  • "io.gatling" % "gatling-sbt" % "2.1.0" for the SBT Plugin
  • "io.gatling" % "gatling-test-framework" % "2.1.0" for the testing framework.