You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Laurent Perez <ha...@gmail.com> on 2008/09/22 18:45:26 UTC

[jmeter-users] HTTP Request Sampler + POST + Location: redirect -> cookies not being sent ?

Hi

I'm using Jmeter 2.3.2.
I've encountered a problem when using the HTTP Request Sampler with a
POST method, and the box "follow autoredirects" being checked.

When the POST response does a 302 redirect (as expected), Jmeter will
follow the redirect, but *without* sending back cookies, even if the
Location: is on a correct domain and path. I double checked, I have a
thread group with a HTTP Cookies Manager configuration element, set to
rfc2965 (chaging the value does not help).

If I uncheck the follow redirects, and I manually add a GET HTTP
Request Sampler, then the cookies are correctly sent.

Is it a known behaviour/bug ?
Thanks

laurent


-- 
<a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
- Mobile world, technology and more</a>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org


Re: [jmeter-users] HTTP Request Sampler + POST + Location: redirect -> cookies not being sent ?

Posted by sebb <se...@gmail.com>.
On 22/09/2008, Laurent Perez <ha...@gmail.com> wrote:
> > If you are using Redirect Automatically, then yes, cookies may not be
>  > sent, because JMeter does not see the redirect.
>
>
> Yes, I meant "Redirect automatically" was checked, sorry.
>
>
>  > If you are using Follow Redirect, then JMeter should  send the correct cookies.
>
>
> Correct, the cookies are sent when I check the Follow box.
>  The "automatic" setting confused me, it works fine now.
>

OK, thanks for letting us know the problem has been solved.

>  Thanks
>
>
>  laurent
>
>
>  >
>  > You can check the cookies in the Tree View Listener.
>  >
>  >>  laurent
>  >>
>  >>
>  >>
>  >>  --
>  >>  <a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
>  >>  - Mobile world, technology and more</a>
>  >>
>  >>  ---------------------------------------------------------------------
>  >>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  >>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>  >>
>  >>
>  >
>  > ---------------------------------------------------------------------
>  > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  > For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>  >
>  >
>
>
>
>
> --
>
> <a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
>  - Mobile world, technology and more</a>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org


Re: [jmeter-users] HTTP Request Sampler + POST + Location: redirect -> cookies not being sent ?

Posted by Laurent Perez <ha...@gmail.com>.
> If you are using Redirect Automatically, then yes, cookies may not be
> sent, because JMeter does not see the redirect.

Yes, I meant "Redirect automatically" was checked, sorry.

> If you are using Follow Redirect, then JMeter should  send the correct cookies.

Correct, the cookies are sent when I check the Follow box.
The "automatic" setting confused me, it works fine now.

Thanks

laurent

>
> You can check the cookies in the Tree View Listener.
>
>>  laurent
>>
>>
>>
>>  --
>>  <a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
>>  - Mobile world, technology and more</a>
>>
>>  ---------------------------------------------------------------------
>>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>



-- 
<a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
- Mobile world, technology and more</a>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org


Re: [jmeter-users] HTTP Request Sampler + POST + Location: redirect -> cookies not being sent ?

Posted by sebb <se...@gmail.com>.
On 22/09/2008, Laurent Perez <ha...@gmail.com> wrote:
> Hi
>
>  I'm using Jmeter 2.3.2.
>  I've encountered a problem when using the HTTP Request Sampler with a
>  POST method, and the box "follow autoredirects" being checked.
>
>  When the POST response does a 302 redirect (as expected), Jmeter will
>  follow the redirect, but *without* sending back cookies, even if the
>  Location: is on a correct domain and path. I double checked, I have a
>  thread group with a HTTP Cookies Manager configuration element, set to
>  rfc2965 (chaging the value does not help).
>
>  If I uncheck the follow redirects, and I manually add a GET HTTP
>  Request Sampler, then the cookies are correctly sent.
>
>  Is it a known behaviour/bug ?
>  Thanks

If you are using Redirect Automatically, then yes, cookies may not be
sent, because JMeter does not see the redirect.

If you are using Follow Redirect, then JMeter should  send the correct cookies.

You can check the cookies in the Tree View Listener.

>  laurent
>
>
>
>  --
>  <a href="http://in-pocket.blogspot.com">http://in-pocket.blogspot.com
>  - Mobile world, technology and more</a>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org