Jmeter configuration element of the HTTP Cookie manager

cookie manager element characteristics

1. Like with a web browser can be stored and transmitted Cookies;

2. If a request and HTTP response contains a cookie, cookie manager automatically stores the cookie, and conversation can be held by Cookie;

3. Each JMeter thread has its own "cookie store." So, if you are testing a Web site uses a cookie to store session information, each JMeter thread has its own session. Note that this will not show up cookies in the cookie manager, but you can see them in the "View Results Tree" in;

4. JMeter cookies checks received is valid for the URL. This means that the cross-domain cookie can not be stored. If you have eavesdropping, or want to store the cross-domain cookies, we need to set in jmeter.poperties in: "CookieManager.check.cookies = false"; received Cookies can be stored as a variable thread of JMeter. If you want cookies stored as a variable, you need to set: "CookieManager.save.cookies = true";

5. jmeter default, when the storage of cookies name prefix "COOKIE_", this is to avoid anomalies caused by the same name local variable. If you do not want to use this prefix, define the property "CookieManager.name.prefix =" (one or more spaces). If the prefix is ​​a name for the value of the cookie TEST may be obtained by $ {COOKIE_TEST};

6. You can manually add a cookie to cookie manager. If you do this, the cookie will be shared by all threads of JMeter.

cookies 7. null values ​​ignored by default. This can be changed by setting properties of JMeter: CookieManager.delete_null_cookies = false. Note that this also applies to any such manual definition of cookies- cookies will be removed from the cookie manager in after the update;

8. Also note that the cookie name must be unique - if a cookie name and cookie has the same name, which will replace the original cookie.

Note: If you have multiple cookie manager in a sampler scope, there is no way to specify a particular. Then, the storage manager of a cookie can not be used in other cookie cookie manager, so caution plurality cookie manager

cookie manager parameters introduced

Note: the domain name server Required

Check cookie request to carry

Published 59 original articles · won praise 19 · views 10000 +

Guess you like

Origin blog.csdn.net/weixin_43507959/article/details/104027316