1 Mar 2005 15:38
Re: Additional work on centralizing spool_dir handling
John Peacock <jpeacock <at> rowman.com>
2005-03-01 14:38:30 GMT
2005-03-01 14:38:30 GMT
John Peacock wrote: > I turned down my log level and discovered that the spool_dir code was > being called more often than I had thought (the Transaction object and > the Plugin object were each initializing it and caching it at different > levels). If the following is too tricky (introducing a closure-hidden > scalar), I can simply make it a package global in Qpsmtpd.pm. > After playing with this for a while, decided that we don't need to hide this in a closure so I applied code to store it in a package lexical instead. Now, the spool_dir is cached in the Qpsmtpd object instead of in the Transaction object (i.e. once per session instead of once per Transaction). This also helps because the plugins usage was cached inside the Qpsmtpd object anyways (thus happening twice per session). John
RSS Feed