[Top] [All Lists]

Language for conflicting actions

1999-01-25 18:27:11
I'm opposed to adding more commands to the language that have nearly
identical semantics to fileinto.  Regardless, we're going to have to
deal with multiple fileinto's being executed.

Tied into this discussion is error messages.  One suggestion here at
CMU was to have the Sieve agent modify a header in a default-delivery
message to indicate a problem in a Sieve script...  Another
possibility is to send a DSN to the person.

Command Interactions

It is possible for two or more actions to be executed by a script.  A
script MUST NOT perform any action before finishing execution, and
MUST check that the actions are consistent (according the the
following chart).

An implementation MAY choose to support multiple compatible actions.
If so, it should either execute all actions or none (barring error
conditions outside the control of the Sieve interpreter).  If the
implementation cannot execute all actions, it should treat it as a
run-time error.

For instance, an implementation may choose to support "redirect" and
"fileinto" together, but not multiple "fileinto" actions.  In that
case, any script that attempts multiple "fileinto" actions causes a
run-time error.

           keep      fileinto    redirect   discard    reject

keep       compat.   compat.     compat.    no         no

fileinto   compat.   compat.     compat.    no         no

redirect   compat.   compat.     compat.    no         no

discard    no        no          no         yes        no

reject     no        no          no         no         no

Two "keep"'s cause a message to be delivered multiple times to the
default location.  Two "fileinto"'s cause a message to be filed into
the specified folders.  Two "redirect"'s cause a message to be
forwarded to multiple addresses.

The implicit keep is only performed when no actions were executed by
the script.

Run-time Errors

It is impossible to prevent run-time errors from occuring.
Implementations are encouraged to statically check Sieve scripts
upon submission to minimize the chances of errors during run-time.

Errors may include:
- quota or ACL problems
- incompatible actions
- too many actions (too many redirects by site policy)

If a run-time error occurs, the implementation should attempt to
perform a "keep" (disregarding any other actions) and should send a
message to the user, either via electronic mail or another
communication channel.

<Prev in Thread] Current Thread [Next in Thread>