Sorry, but the Cookie Manager does not support variable cookie values.
You may be able to use the Header Manager instead - I've not tried.
Otherwise, given that you are already using BeanShell, you may be able
to find the Cookie Manager object, and add the cookie yourself.
BTW, there is no need to use BeanShell Sampler to generate a sample
and then extract it using the RE extractor. BeanShell scripts have
access to the thread variables - see the manual.
And unless you need to calculate the cookies at run-time, you might as
well put them in a file and use CSV DataSet to create the variables.
See also the JMeter FAQ.
S.
On 21/02/06, Gisela Kogler <[EMAIL PROTECTED]> wrote:
>
>
> Dear Jakarta JMeter Developer Group!
>
> First of all - you did a good work so far!!! Thank you for this really,
> really useful stress-test-toolbox!
>
> But now - why I am writing? Yes, of course: I have a big (for me not logical)
> problem: I can not add a cookie within the HTTP Cookie Manager manually which
> has a dynamically value (this value is a local variable should be filled by
> the outcome of a Regular Extractor Rule; see the structure below).
> The value has to be dynamically changeable, because the value is a token
> which has been generated dynamically before within a BeanShell. The token has
> to be generated within a BeanShell, because I want to overgo bottlenecks we
> have with our login-database (which, in fact, has nothing to do with this
> stress-test, but
> with the hardware architecture ...).
>
> So here is the structure:
>
> Thread Group:
> |
> -1.) BeanShell Sampler (generates a token an puts it into the ResponseMessage)
> | |
> | - Regular Expresson Extractor (gets the token String out of the
> ResponseMessage into the local variable tokenValue)
> |
> |- 2.) HTTP Cookie Manager with one manually added Cookie:
> | Name: TOKEN
> | Value: ${tokenValue}
> | Domain: .betandwin.com
> | Path: /
> | Security: not enabled
> |
> -3.) HTTP Request (which needs the token as Cookie Data, so that the Request
> looks like this:
> GET
> http://rbweb.betandwin.com:8080/displayMyBetsXML?dateFrom=2005-12-01&dateTo=2006-01-31&details=1&type=ALL
> Cookie Data:
> ABPTOKEN=nSfm1d4u/U/VAElK8jJQubQl6y6QfpPYdF9BGj3I16bFlipSqMKX78g==
>
>
> The problem is that my HTTP Request looks like this:
> GET
> http://rbweb.betandwin.com:8080/displayMyBetsXML?dateFrom=2005-12-01&dateTo=2006-01-31&details=1&type=ALL
> Cookie Data:
> ABPTOKEN=${tokenValue}
>
>
>
> I really would feel much happier, if you can provide any solution ... because
> I have already searched for one for a long time and I really need it asap.
>
> Thank you in advance,
>
>
>
>
>
>
>
> Gisela Kogler
> Software Developer
>
>
>
>
> Web http://www.betandwin.com*
> WAP http://wap.betandwin.com*
> Office +43-1-585 6044-7308
> Fax +43-1-585 6044-16
>
>
> E-mail [EMAIL PROTECTED]
> S-mail Börsegasse 11/Top floor,
> 1010 Vienna, Austria
>
>
> [Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
> Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
> irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und
> vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte
> Weitergabe dieser Mail ist nicht gestattet.
>
> This e-mail may contain confidential and/or privileged information. If you
> are not the intended recipient (or have received this e-mail in error) please
> notify the sender immediately and destroy this e-mail. Any unauthorised
> copying, disclosure or distribution of the material in this e-mail is
> strictly forbidden.]
>
> *operated by the subsidiary BAW International Ltd.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]