Re: [exim] Wishlist item prop. - logical conditions in strin…

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Marcin Krol
日付:  
To: exim users
題目: Re: [exim] Wishlist item prop. - logical conditions in string expansion
Hello Phil,

> On 2007-10-15 at 17:15 +0200, Marcin Krol wrote:
>> Every RBL had to have those 3 conditions tested again right after
>> previous RBL verb tested them, so I decided to consolidate condition
>> lines into a single user variable and this is what I ended up with:


> Spec, 40.22 ACL conditions. Condition "acl".


> An ACL can require that another ACL be passed, so you can write ACLs as
> subroutines.


Well that's nice, except:

1. That still runs this ACL as many times as RBLs are configured.

Unless the results of ACL runs are cached (don't remember reading anything about that), that means doing completely unnecessary expansions and file lookups (cached, all right, but the "lookup" call still has to be ran) again and again.

If I wanted just an ACL, I would just leave those "condition = " lines right in the RBL verb. Heck, I guess leaving them inline is actually a bit faster than defining them in a separate ACL and then calling ACL several times.

Avoiding that repetition is exactly what variables are for. Defining user variable might actually be seen as a way of "caching" the result of ACL conditions' expansions.

Some would say "exim is not a procedural language", to what I say: "why not? that would actually be great; such power in many cases might be truly necessary".


2. ACLs are not the only place where Exim user might want to use complex logical conditions.



--
Marcin Krol