Shijith Anandan
Shijith Anandan

Reputation: 23

How to pass variables across thread groups in JMeter?

Been trying to extract a value from the response data of a thread group,store it in a variable use the variable in the subsequent thread group. Would be great if someone provides insights on how to proceed.

Upvotes: 1

Views: 5932

Answers (2)

Dmitri T
Dmitri T

Reputation: 168002

  • Use __setProperty() function to convert JMeter Variable to JMeter Property in one thread group
  • Use __property() function to access previously set property value in another thread group(s)

See Knit One Pearl Two: How to Use Variables in Different Thread Groups article for detailed explanation

Upvotes: 0

RaGe
RaGe

Reputation: 23637

Variables are local to a thread. Use properties as they're common to all threads.

From here:

Properties are not the same as variables. Variables are local to a thread; properties are common to all threads, and need to be referenced using the __P or __property function.

Upvotes: 2

Related Questions