Edit detail for #338 useroptions: combine cookies revision 1 of 1

1
Editor: betabug
Time: 2007/03/14 09:19:06 GMT+0
Note: any number of cookies are just 1 http header

added:


<b>FlorianKonnertz, 2003/01/16 06:38 GMT (via web):</b><br>
Could you explain? Why should they be combined and how can this be done?

From simon Wed Apr 19 00:01:11 -0700 2006
From: simon
Date: Wed, 19 Apr 2006 00:01:11 -0700
Subject: 
Message-ID: <[email protected]>


It seemed inefficient to be sending these multiple cookies, when one should be enough. The various Zwiki user options would need to be combined in a single cookie, all code which uses them would need to be adapted, and old cookies would need to be gracefully converted to a new-style cookie.

From betabug Wed Mar 14 09:19:06 +0000 2007
From: betabug
Date: Wed, 14 Mar 2007 09:19:06 +0000
Subject: any number of cookies are just 1 http header
Message-ID: <[email protected]>

Status: open => closed 

Any number of cookies are just transmitted in one http header with each request. So there is no "sending multiple cookies" involved.

Instead of going through the code and implementing our own assembling and dissassembling of values, we can let http and the Zope cookie routines sort the stuff out. Code like REQUEST.cookies.get('email',None)) can't really get more efficient. (The use of "email" for a cookie name is a different issue, already in the tracker IIRC.)

Submitted by : simon at: 2003-10-26T21:31:43+00:00 (17 years ago)
Name :
Category : Severity : Status :
Optional subject :  
Optional comment :

FlorianKonnertz, 2003/01/16 06:38 GMT (via web):
Could you explain? Why should they be combined and how can this be done?


comments:

... --simon, Wed, 19 Apr 2006 00:01:11 -0700 reply

It seemed inefficient to be sending these multiple cookies, when one should be enough. The various Zwiki user options would need to be combined in a single cookie, all code which uses them would need to be adapted, and old cookies would need to be gracefully converted to a new-style cookie.

any number of cookies are just 1 http header --betabug, Wed, 14 Mar 2007 09:19:06 +0000 reply
Status: open => closed

Any number of cookies are just transmitted in one http header with each request. So there is no "sending multiple cookies" involved.

Instead of going through the code and implementing our own assembling and dissassembling of values, we can let http and the Zope cookie routines sort the stuff out. Code like REQUEST.cookies.get(email,None)) can't really get more efficient. (The use of "email" for a cookie name is a different issue, already in the tracker IIRC.)