Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

Jmeter grabs the Set-Cookie value from the previous request using regular expressions and applies it in the next request

Shulou Source: shulou.com Published: 2022-06-03 04:39:11 11月15日 Update

For problems encountered in work, the login request contains a parameter Set-Cookie in the returned Response Headers. You need to grab this parameter and apply it to the next request, as shown in the following figure:

Grab the value of Set-Cookie through a regular expression, which needs to be selected as an "information header" because the value exists in Response Headers:

When used in other requests, you need to add a "HTTP header manager" to reference the captured values above, as shown in the following figure:

If the request is sent again, there is also a Set-Cookie value in Response Headers, and the login timeout will not be returned.

Tags: Regular following figure information parameters login expression again problem work management selection China Transportation Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS Shulou Technology MySQL Redmi MariaDB