Gatling interview questions — Medium
298 medium-level Gatling questions from our Performance Testing bank, each with the correct answer and an explanation of why it is correct.
What this covers
Gatling appears throughout Performance Testing interviews. At medium level, interviewers are typically checking that you have used it in practice: what you configured, what broke, and how you knew it worked. Work through these, then explain your answer out loud; the second part is what interviews actually test.
20 example questions
1. "Executes an HTTP request action in a scenario" — in Gatling, this describes which of the following?
- A. Throttle.
- B. SetUp().
- C. JsonPath check.
- D. Exec(http(...)).correct
Why: exec(http(...)): Executes an HTTP request action in a scenario.
2. "Defines the sequence of actions virtual users perform" — in Gatling, this describes which of the following?
- A. Scenario().correct
- B. Percentile3 (p95).
- C. Exec(http(...)).
- D. JsonPath check.
Why: scenario(): Defines the sequence of actions virtual users perform.
3. "Injection step increasing arrival rate over time" — in Gatling, this describes which of the following?
- A. RampUsersPerSec.correct
- B. Percentile3 (p95).
- C. Scenario().
- D. Pause().
Why: rampUsersPerSec: Injection step increasing arrival rate over time.
4. "Report metric for 95th percentile response time" — in Gatling, this describes which of the following?
- A. Percentile3 (p95).correct
- B. Throttle.
- C. Pause().
- D. SetUp().
Why: percentile3 (p95): Report metric for 95th percentile response time.
5. "Wires scenarios to injection profiles in a simulation" — in Gatling, this describes which of the following?
- A. SetUp().correct
- B. Scenario().
- C. RampUsersPerSec.
- D. Exec(http(...)).
Why: setUp(): Wires scenarios to injection profiles in a simulation.
6. Which of the following statements about Gatling is TRUE?
- A. Feeders in Gatling cannot read CSV files.
- B. Gatling simulations are code-based, historically in Scala with Java and Kotlin DSLs also supported.correct
- C. Gatling produces no reports of any kind.
- D. Gatling assertions cannot fail a CI build.
Why: Simulation classes define scenarios, injection profiles, and assertions.
7. "Extracts or validates JSON response content" — in Gatling, this describes which of the following?
- A. Percentile3 (p95).
- B. JsonPath check.correct
- C. Scenario().
- D. SetUp().
Why: jsonPath check: Extracts or validates JSON response content.
8. "Caps requests per second during a simulation" — in Gatling, this describes which of the following?
- A. Pause().
- B. Scenario().
- C. Throttle.correct
- D. Percentile3 (p95).
Why: throttle: Caps requests per second during a simulation.
9. Identify the accurate statement about Gatling:
- A. Feeders in Gatling cannot read CSV files.
- B. Gatling's engine creates one operating-system thread per virtual user.
- C. Gatling assertions cannot fail a CI build.
- D. Gatling simulations are code-based, historically in Scala with Java and Kotlin DSLs also supported.correct
Why: Simulation classes define scenarios, injection profiles, and assertions.
10. "Adds think time between actions" — in Gatling, this describes which of the following?
- A. Exec(http(...)).
- B. JsonPath check.
- C. Scenario().
- D. Pause().correct
Why: pause(): Adds think time between actions.
11. Which statement correctly describes Gatling?
- A. Gatling simulations are code-based, historically in Scala with Java and Kotlin DSLs also supported.correct
- B. Feeders in Gatling cannot read CSV files.
- C. Gatling assertions cannot fail a CI build.
- D. Gatling's engine creates one operating-system thread per virtual user.
Why: Simulation classes define scenarios, injection profiles, and assertions.
12. Which Gatling concept matches this description: "Executes an HTTP request action in a scenario"?
- A. SetUp().
- B. Exec(http(...)).correct
- C. Scenario().
- D. Throttle.
Why: exec(http(...)): Executes an HTTP request action in a scenario.
13. In Gatling, which of the following is described as: "Defines the sequence of actions virtual users perform"?
- A. Exec(http(...)).
- B. JsonPath check.
- C. Scenario().correct
- D. Percentile3 (p95).
Why: scenario(): Defines the sequence of actions virtual users perform.
14. Which Gatling concept matches this description: "Wires scenarios to injection profiles in a simulation"?
- A. SetUp().correct
- B. RampUsersPerSec.
- C. Percentile3 (p95).
- D. Throttle.
Why: setUp(): Wires scenarios to injection profiles in a simulation.
15. Which Gatling concept matches this description: "Report metric for 95th percentile response time"?
- A. SetUp().
- B. Pause().
- C. Exec(http(...)).
- D. Percentile3 (p95).correct
Why: percentile3 (p95): Report metric for 95th percentile response time.
16. In Gatling, which of the following is described as: "Executes an HTTP request action in a scenario"?
- A. Throttle.
- B. JsonPath check.
- C. Pause().
- D. Exec(http(...)).correct
Why: exec(http(...)): Executes an HTTP request action in a scenario.
17. In Gatling, which of the following is described as: "Wires scenarios to injection profiles in a simulation"?
- A. Percentile3 (p95).
- B. SetUp().correct
- C. Exec(http(...)).
- D. Pause().
Why: setUp(): Wires scenarios to injection profiles in a simulation.
18. In the context of Gatling, which of the following is a correct statement?
- A. Gatling's engine creates one operating-system thread per virtual user.
- B. Gatling assertions cannot fail a CI build.
- C. Feeders in Gatling cannot read CSV files.
- D. Gatling simulations are code-based, historically in Scala with Java and Kotlin DSLs also supported.correct
Why: Simulation classes define scenarios, injection profiles, and assertions.
19. In Gatling, which of the following is described as: "Report metric for 95th percentile response time"?
- A. JsonPath check.
- B. Exec(http(...)).
- C. Throttle.
- D. Percentile3 (p95).correct
Why: percentile3 (p95): Report metric for 95th percentile response time.
20. Which Gatling concept matches this description: "Defines the sequence of actions virtual users perform"?
- A. JsonPath check.
- B. Throttle.
- C. SetUp().
- D. Scenario().correct
Why: scenario(): Defines the sequence of actions virtual users perform.