<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">Hi,<br><br>in app.publication.zopepublication.py there are 2 methods.<br>Maybe they are invoked in different scenarios, I am not sure.<br>But at least one PAU auth for each request.<br><br> def callTraversalHooks(self, request, ob):<br> # Call __before_publishing_traverse__ hooks<br> notify(BeforeTraverseEvent(ob, request))<br> # This is also a handy place to try and authenticate.<br> self._maybePlacefullyAuthenticate(request, ob)<br><br> def afterTraversal(self, request,
ob):<br> #recordMetaData(object, request)<br> self._maybePlacefullyAuthenticate(request, ob)<br><br><br><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">----- Original Message ----<br>From: Roger Ineichen <dev@projekt01.ch><br>To: nixon <nxnth@yahoo.com.cn>; zope3-users@zope.org<br>Sent: Wednesday, April 30, 2008 11:26:31 AM<br>Subject: AW: [Zope3-Users] efficiency of PAU authentication<br><br>
Hi Nixon<br><br>> Betreff: [Zope3-Users] efficiency of PAU authentication<br>> <br>> Hi, dear all,<br>> <br>> PAU authenticates 2 times each request, before and after traversal.<br><br>Really? <br>Can you explain why this happens?<br><br>> What if I make an authentication plugin based on relational database?<br>> Everytime the plugin has to create a pricipal from database, <br>> assign roles to it, ...<br>> When the website is under heavy load, there must be huge <br>> number of authentication request.<br>> Is RDB based PAU efficient enough to do authentication?<br>> <br>> I have an idea of session-cache authentication: fetch <br>> credentials from RDB and cache them in session. Is this more <br>> efficient?<br><br>Yes, of corse, I recommend caching if you need to run a heavy loaded site.<br><br>Regards<br>Roger Ineichen<br><br>> Best Regards<br>> Nixon<br>> <br>> <br>>
________________________________<br>> <br>> ÑÅ»¢ÓÊÏ䣬ÄúµÄÖÕÉúÓÊÏ䣡 <<a href="http://cn.mail.yahoo.com/" target="_blank">http://cn.mail.yahoo.com/</a>> <br>> <br><br></div><br></div></div><br>
<hr size=1>Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. <a href="http://us.rd.yahoo.com/evt=51733/*http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ "> Try it now.</a></body></html>