Questions tagged [scala-gatling]

426 questions
1
vote
1 answer

how to run gatling scenarios sequentially and not concurrently?

I have created a simple gatling maven application to test performance, verify API rate limit(so if sent requests more than its rate limit it should fail) . In order to run each api as an independent operation and not concurrently, I have created…
anonymous-explorer
  • 365
  • 1
  • 12
  • 26
1
vote
1 answer

Gatling : Update content of JSON file before using it as request body

{ "aggregateResults": true, "targetTimeSeries": "finalForecast", "filter": { "id": "f3456789sdsd779sds4488" } } This the content of my JSON file, I want to change the value of id before sending this JSON as body in a POST request for my…
mu1988
  • 51
  • 1
  • 7
1
vote
2 answers

Gatling: transform findAll to sorted list

I'm new to scala and Gatling. I'm trying to transform the result of findAll into a sorted list and then return a String representation of the sorted list. I can't seem to do this with the following code: http(requestTitle) .post(serverUrl) …
KeithC
  • 97
  • 8
1
vote
0 answers

Gatling - Concatenate JSON files within static JSON content

Galing version : 3.3.1 I am trying to post json payloads using multiple files. These files contain a segment of a bigger JSON payload [unique json file for each user]. Since each Json file is a segment/child of bigger JSON, I need to concatenate…
karan d
  • 11
  • 2
1
vote
1 answer

Gatling with gradle: Task has not declared any outputs despite executing actions

I try to setup gatling in my Spring Boot project, based on gradle, following this tutorial: http://brokenrhythm.blog/gradle-gatling-springboot-automation Here is the tasks I wrote: task runGatling(type: JavaExec) { description = 'Test load the…
Romain R.
  • 920
  • 12
  • 21
1
vote
0 answers

How To Write Java Lambda function To Call The Class That The Maven Gatling plugin is Ultimately Calling and Run in AWS LAMBDA

I execute perf tests using below maven command, mvn gatling:test -Dgatling.simulationClass=simulations.Stageabcsite Now my need is i would like to use a Java Lambda function instead of mvn because i have a requirement to run this gatling code on…
mark liberhman
  • 101
  • 1
  • 11
1
vote
3 answers

Gatling: How to extract one object from array?

I am new in Gatling and Scala. Sending Get Request the response body is Array and I need to extract only one object from Array and post it in Gatling. Can someone explain to me how to do it? Here is my code example: private val getUsers = exec( …
aliiise
  • 51
  • 1
  • 6
1
vote
3 answers

gatling Form Parameters : How to pass custom form-data to post request

I am new to gatling scripting. I am trying to execute a performance testing against one of our application's POST api. This POST request API required to pass the form-data. EG : Print-Screen of the postman collection of the request body For that…
UtpMahesh
  • 410
  • 10
  • 25
1
vote
1 answer

Gatling Time Extraction From Response Body

I am completely new to Gatling/Scala. I have a scenario to execute. Here it goes: -->Change the shift timings of the employees. For the above, I am able to script/code the flow. However, I have a challenge: -> I need to extract the "new" time…
kp4692
  • 11
  • 3
1
vote
0 answers

Injecting 0 users in scenario message during rampup users in gatling

I am using a simple setup to ramp up the users but getting the following error and the run is going on infinite loop code in my Scenario: setUp( scenarioBuilder.inject( rampUsers(numUser).during(duration minutes) ) …
1
vote
0 answers

Log only the request names and their status in gatling using logback

Is there any way to log just the request names and their status to a file. The options included in logback are only for logging all requests/responses using TRACE, or for logging only failed requests using DEBUG. Or is there any way to log the…
Adharsh V S
  • 95
  • 11
1
vote
0 answers

How to load the gatling configuration only once while executing the scenarios in Gatling?

I am loading the application related config in BasicSimulation class and this class is being inherited by all other simulation test scripts in my project. This class contains something like this The sample simulation script is like below…
Vaibhav_Sharma
  • 546
  • 1
  • 9
  • 22
1
vote
1 answer

Error: type inference was unable to figure out the type. Getting error on upgrading scala version

logger.info("Error Response:[" + extraInfo.session("username").asOption[String] + "], Code:[" + statusCode + "], Response Body:[" + extraInfo.response.body.string + "], Token:[" +…
Roshan Nalawade
  • 172
  • 1
  • 16
1
vote
1 answer

Gatling won't save access token

In this example below, I can see that path to token is correct, because when I change it I get errors such as find.exists. found nothing. Yet for some reason I can't save the token. I get Failed to build request: No attribute named 'Token' is…
Tiina86
  • 33
  • 3
1
vote
1 answer

Randomising number of repeats for different users in Gatling

I'm currently trying to write a scenario in Gatling where I would like an action to be repeated between 1 and 8 times. The randomness should be on a per user basis, so for example one user may get 3 repeats and another gets 7. I'm wanting the…
Kyri Elia
  • 997
  • 9
  • 18