jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Philippe Mouawad <philippe.moua...@gmail.com>
Subject Re: Cookie manager not getting more than one set-cookie per response?
Date Wed, 18 Apr 2012 00:10:22 GMT
Hello,
Could you open a bug with:

   - A simplified attached Test Plan showing the issue on a public website
   if possible
   - A detailed description of the issue you face
   - Some Fiddler capture of HTTP traffic and particularly the header
   received and what JMeter captures


Cause from what R. Wilson described there was no issue one we
CookieManager.save.cookies was set to true.

And reading the code I don't think that if false it does  impact cookies
reading.

Regards
Philippe M.
http://www.ubik-ingenierie.com


On Sun, Apr 15, 2012 at 10:13 PM, sergio <sergio@bosoconsulting.it> wrote:

> Hi everybody,
>
> I run into this issue today, exactly the same way Robin described.
>
> In fact, it seems that, if the property:
>
> "CookieManager.save.cookies=**false"
>
>
> then only the first cookie of the header is read.
>
> The solution that was found by R.Wilson is quite straight forward, however
> it may take quite a long time to understand where the problem comes from.
> I think that it should be fixed..
>
> regards
>
> Sergio
> Il 23/02/2012 16:07, Philippe Mouawad ha scritto:
>
>> This settings is false since 2.3.2, see:
>> http://jmeter.apache.org/**usermanual/component_**
>> reference.html#HTTP_Cookie_**Manager<http://jmeter.apache.org/usermanual/component_reference.html#HTTP_Cookie_Manager>
>> *"Received Cookies can be stored as JMeter thread variables (versions of
>>
>> JMeter after 2.3.2 no longer do this by default). To save cookies as
>> variables, define the property "CookieManager.save.cookies=**true"."
>> *
>>
>> Regards
>>
>> On Thu, Feb 23, 2012 at 4:04 PM, Robin D. Wilson<rwilson2@gmail.com>
>>  wrote:
>>
>>  Nevermind, I found the issue - it was this setting:
>>>
>>>                CookieManager.save.cookies=**true
>>>
>>> Apparently this was on by default previously in JMeter2.4 (or was
>>> configured somewhere that I didn't know about), but adding it to
>>> my 'user.properties' fixed the problem.
>>>
>>> --
>>> Robin D. Wilson
>>> Sr. Director of Web Development
>>> KingsIsle Entertainment, Inc.
>>> VOICE: 512-777-1861
>>> www.KingsIsle.com
>>>
>>> From: Robin D. Wilson [mailto:rwilson2@gmail.com]
>>> Sent: Thursday, February 23, 2012 8:58 AM
>>> To: 'JMeter Users List'
>>> Subject: RE: Cookie manager not getting more than one set-cookie per
>>> response?
>>>
>>> OK, I have setup a test case for this...
>>>
>>> My test script returns 2 cookies, here's a look at the response headers
>>> from a request to that page:
>>>
>>>
>>> Response headers:
>>> HTTP/1.1 200 OK
>>> Date: Thu, 23 Feb 2012 14:51:51 GMT
>>> Server: Apache/2.2.17 (Unix)
>>> Expires: Thu, 02 Feb 2012 23:59:59 GMT
>>> Set-Cookie: theCookie1=value1; Expires=Wed, 09 Jun 2021 12:00:00 GMT
>>> Set-Cookie: theCookie2=value2
>>> Keep-Alive: timeout=15, max=100
>>> Connection: Keep-Alive
>>> Transfer-Encoding: chunked
>>> Content-Type: text/html; charset=UTF-8
>>>
>>> My second sampler in the test attempts to use the cookies set above in
>>> the
>>> POST of the request - using "${COOKIE_theCookie1}" and
>>> "${COOKIE_theCookie2}". But when I look at the values posted, I get this
>>> instead:
>>>
>>> POST data:
>>>
>>> POSTVARCOOKIE1=%24%7BCOOKIE_**theCookie1%7D&POSTVARCOOKIE2=%**
>>> 24%7BCOOKIE_theCookie2%7D
>>>
>>> However, in the request headers of the second sampler, I can see that the
>>> cookies are both actually set:
>>>
>>> Cookie Data:
>>> theCookie1=value1; theCookie2=value2
>>>
>>> They just aren't being accessed by the "${COOKIE_<cookie_name>}"
>>> convention anymore... Did this change in JM2.6?
>>>
>>> --
>>> Robin D. Wilson
>>> Sr. Director of Web Development
>>> KingsIsle Entertainment, Inc.
>>> VOICE: 512-777-1861
>>> www.KingsIsle.com
>>>
>>>
>>>
>
> --
>
> Ing. Sergio Boso
>
> In caso di erronea ricezione da parte di persona diversa, siete pregati di
> eliminare il messaggio e i suoi allegati in modo definitivo dai vostri
> archivi e di volercelo comunicare immediatamente restituendoci il messaggio
> via e-mail al seguente indirizzosergio@**bosoconsulting.it<indirizzosergio@bosoconsulting.it><mailto:
> sergioboso@yahoo.it>
> L’interessato può, inoltre, esercitare tutti i diritti di accesso sui
> propri dati previsti dal decreto 196/2003, tra i quali i diritti di
> rettifica, aggiornamento e cancellazione, inviando un messaggio all’
> indirizzo:sergio@**bosoconsulting.it<indirizzo%3Asergio@bosoconsulting.it><mailto:
> sergioboso@yahoo.it>
>
>
>
>
>
> ------------------------------**------------------------------**---------
> To unsubscribe, e-mail: user-unsubscribe@jmeter.**apache.org<user-unsubscribe@jmeter.apache.org>
> For additional commands, e-mail: user-help@jmeter.apache.org
>
>


-- 
Cordialement.
Philippe Mouawad.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message