[Zope] Problem with multiple Browser Id Managers

Pablo Ziliani pablo at decode.com.ar
Thu Nov 17 20:47:29 EST 2005


Hello all, I have a situation here;
as I has previously posted, I need to set the domain/host for of the 
cookie that stores the session id so it is shared among multiple 
subdomains. As Dieter has pointed to me, I should change the 'domain' 
property for the Browser Id Manager (from now on BMI) that controls the 
session.
Unfortunately, my Zope instance holds multiples virtual sites, so I 
can't simply change the root BMI that comes with Zope's installation; 
instead I need to create inner BMI instances. So I did, giving the new 
instance a different Browser Id Name than the root's _ZopeId both to 
differentiate them and to be more site-specific. Then I restarted Zope 
(don't know if this really matters) and re-entered the site to see what 
happened: I was still given the same cookie, _ZopeId.

Reading the documentation I found this quote (browser-add.stx):

"""


      Instantiating Multiple Browser Id Managers (Optional)

(...) In its default configuration, Zope will not allow you to create a 
browser id manager if one is installed in the root or in a place where 
the new browser id manager can acquire the original browser id manager 
via its containment path (for programmers: the session id manager's 
class' Zope __replaceable__ property is set to UNIQUE). This means, 
practically, that if you wish to have multiple browser id managers, you 
need to carefully delete the root browser id manager, then you need to 
place additional browser id managers in the most deeply-nested 
containers first, working your way out towards the root, finally 
replacing the root browser id manager if desired.
"""

...which is either false or (more likely), outdated, since first (as I 
said) I had no trouble in adding another deeper BMI; and second, because 
any attempt to delete root's BMI ends in a "/browser_id_manager/ cannot 
be deleted." page error message.

Any hint?

Thanks all in advance,
Pablo Ziliani




More information about the Zope mailing list