[CPS-devel] Re: Custom Directory

Olivier Grisel ogrisel at nuxeo.com
Wed Apr 19 11:01:23 CEST 2006


damien.metzler at ext.leroymerlin.fr a écrit :
> Hi,
>  
> I've just set up a LDAP directory with CPSLDAPSetup (great work).  My 
> problem is that my company wants me to use a web service to fetch user 
> information and authenticate. So I must make my own 
> WebServiceBackingDirectory which is quite the same as the 
> CPSLDAPDirectory. My problem is that i found tutorials on how to add 
> content products, simple products but i didn't find how to add custom 
> directory.
>  
> Here is the init.py that I did by copying the one found in CPSDirectory....
>  

Please note that this is __init__.py and not init.py. Furthermore, you will need 
to add a configure.zcml files with directives to initialize the "add" views for 
you directories and plug an adequate XMLAdapter if you want to add GenericSetup 
support for you new directory class.

Please also note that you should implement ZCacheable as well (as 
LDAPBAckingDirectory and ZODBDirectory do) in order to maintain acceptable 
performance using a RAMCacheManager instance such as 
portal_directories/dir_ramcache which is created in the default profile.

-- 
Olivier



More information about the cps-devel mailing list
More information about CPS: CPS project - CVS - API

Hosting: Nuxeo: Zope service provider


This list archive provided by Nuxeo, the leaders of open source ECM. Check out the Nuxeo 5 open source, standards-based ECM project.