Tracking strategy for default identifier

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Tracking strategy for default identifier

Esteban A. Maringolo
Hi all,

I recently moved to `WACookieForBrowserIPForCrawlerTrackingStrategy`
tracking strategy, but I noticed that the session count was increasing
beyond the actual "normal" use, suggesting a new session was being
created everytime.

Then I noticed that when I perform a request to the default
dispatcher, it creates a new session, because the cookie is created
with the app path so the browser is not sending it back when visiting
the root.

I have the default name for the dispatcher as:
WAAdmin defaultDispatcher defaultName: 'app'.

If I visit this:
http://localhost:8080/app
I get a new cookie (if needed) and subsequent requests don't create a new one.

If I visit
http://localhost:8080/
I get a new cookie (and a new session is created) each time because
the cookie is created with the `/app` path.

Did this happen to anyone else?

Regards!

Esteban A. Maringolo
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Tracking strategy for default identifier

Karsten Kusche
Hi Esteban,

that’s probably due to how cookies work in general (they contain their path and only apply there, so if you open / it doesn’t send the cookies for /app).
You could have a default-dispatcher that redirects to /app to avoid the problem.

Kind Regards
Karsten

— 

Georg Heeg eK
Wallstraße 22
06366 Köthen

Tel.: 03496/214328
FAX: 03496/214712
Amtsgericht Dortmund HRA 12812


Am 17. August 2020 um 18:32:58, Esteban Maringolo ([hidden email]) schrieb:

Hi all,

I recently moved to `WACookieForBrowserIPForCrawlerTrackingStrategy`
tracking strategy, but I noticed that the session count was increasing
beyond the actual "normal" use, suggesting a new session was being
created everytime.

Then I noticed that when I perform a request to the default
dispatcher, it creates a new session, because the cookie is created
with the app path so the browser is not sending it back when visiting
the root.

I have the default name for the dispatcher as:
WAAdmin defaultDispatcher defaultName: 'app'.

If I visit this:
http://localhost:8080/app
I get a new cookie (if needed) and subsequent requests don't create a new one.

If I visit
http://localhost:8080/
I get a new cookie (and a new session is created) each time because
the cookie is created with the `/app` path.

Did this happen to anyone else?

Regards!

Esteban A. Maringolo
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside