Gatling-Scala framework - How to pass parameters from Jenkins file to gatling.config file?

How to pass parameters from Jenkins file to gatling.config file?

I have a scenario, where I need to update requestTimeout while staging 3 different scenarios in Jenkins file.

http {
requestTimeout = 240000 // the value should be parameterised in Jenkins file
dns {
resolution
}
}

like in jenkins file

    stage("Run Gatling test 1") {
        steps {
            sh 'mvn gatling:test1'

-----> -DrequestTimeout = 240000 // how to update requestTimeout parameter in gatling.config file
}
post {always {gatlingArchive()}}
}
.

    stage("Run Gatling test 2 - will take 2 hours to process the huge request") {
        steps {
            sh 'mvn gatling:test2'

-----> -DrequestTimeout = 7200000 // how to update requestTimeout parameter in gatling.config file
}
post {always {gatlingArchive()}}
}

Please provide a solution

Hello Monika,

Thanks so much for reaching out. In general the way that we at Gatling recommend integrating a CI/CD solution with Gatling is to use Gatling Enterprise (Cloud, Self-Hosted, or Marketplace options) which has an API and native integrations that allow you easily to connect with Jenkins and many others. If you like feel free to reach out to me at pdutka@gatling.io and I can set you up with a demo.

If you’re looking for an Open-Source solution maybe another community member can help you out.

All the best,
Pete

@GatlingPete Thanks for responding, but I am looking for open source solution.
@slandelle :crossed_fingers:
can community members please help me.
Thanks.

Also if there is a documentation to parameterise values from Jenkins file to Scala simulation please provide them.
Please help me with examples.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.