[Zope3-dev] Re: principal events for the event hub

Chris Withers chrisw@nipltd.com
Tue, 22 Apr 2003 13:00:52 +0100


Do we really want this many messages floating around Zope 3?

I know we're aiming to be slow^w^w^w^wnot aiming to be optimised, but how will 
we ever make a system with myriads of events flowing around scale properly?

cheers,

Chris

Christian Heimes wrote:
> Steve Alexander wrote:
> 
>>
>>> class IPrincipalEvent(IEvent):
>>>     """Something happens to a principal"""
>>
>>
>> This should contain a principal object. You can't have a principal 
>> event if you don't have a principal.
> 
> 
> This mistake bases on a misunderstanding. I thought that a anonymous 
> access doesn't have a principal
> 
> Here is a retry:
> 
> class IPrincipalEvent(IEvent):
>     """Something happens to a principal"""
>     principal = Attribute("principal object")
> 
> # principal authentication source
> 
> class IPrincipalSourceEvent(IPrincipalEvent):
>     """A principal authentication source has been changed"""
> 
> class IPrincipalAddedEvent(IPrincipalSourceEvent):
>     """A principal is added"""
> 
> class IPrincipalRemovedEvent(IPrincipalSourceEvent):
>     """A principal is removed"""
> 
> # is renaming a principal supported?
> class IPrincipalChangedEvent(IPrincipalSourceEvent):
>     """A principal has changed"""
> 
> # login/logout
> 
> class IPrincipalAuthenticationEvent(IPrincipalEvent):
>     """A principal is logged in or off"""
> 
> class IPrincipalLoginEvent(IPrincipalAuthenticationEvent):
>     """A principal has logged in successfully"""
> 
> class IPrincipalDeniedLoginEvent(IPrincipalAuthenticationEvent):
>     """A principal couldn't be validated"""
> 
> class IPrincipalLogoutEvent(IPrincipalAuthenticationEvent):
>     """A principal has logged out"""
> 
> 
> # Maybe these events could be usefull, too:
> 
> class IPrincipalAccessEvent(IPrincipalEvent):
>     """A principal tries to access an object""
>     path = Attribute("path to the object")
> 
> class IPrincipalAllowedAccessEvent(IPrincipalAccessEvent):
>     """A granted access"""
> 
> class IPrincipalDeniedAccessEvent(IPrincipalAccessEvent):
>     """A denied access"""
> 
> 
> 
> 
> 
> _______________________________________________
> Zope3-dev mailing list
> Zope3-dev@zope.org
> http://mail.zope.org/mailman/listinfo/zope3-dev
> 
>