You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Santosh <sa...@wirkle.com> on 2006/06/14 12:06:25 UTC
Working of Matcher...little confused
I'm little confused about the working of a matcher. It's a simple doubt
though.
Consider a mail with:
From: someone@somedomain.com
To: a@adomain.com , b@adomain.com, c@adomain.com
In the transport processor:
<mailet match="RecipientIsLocal " class="EchoMailet" /> --- call it 1
<mailet match="HostIsLocal" class=" EchoMailet " /> -- call it 2
Current HostName: adomain.com
localUsers: a & b (but not c)
EchoMailet simply prints the recipient addresses in the Mail object it
receives in the service(Mail mail) method. It extends GenericMailet.
According to my observations,
after 1: EchoMailet prints
a@adomain.com
b@adomain.com
after 2: EchoMailet prints
a@adomain.com
b@adomain.com
c@adomain.com
Shouldn't the matcher RecipientIsLocal filter out a@adomain.com &
b@adomain.com such that at/after 2 only c@adomain.com? Isn't this the
_expected_ behavior of any matcher?
Santosh.
RE: Working of Matcher...little confused
Posted by Santosh <sa...@wirkle.com>.
Confirmed...Thanks a lot.
Santosh.
-----Original Message-----
From: Stefano Bagnara [mailto:apache@bago.org]
Sent: Wednesday, June 14, 2006 4:02 PM
To: James Users List
Subject: Re: Working of Matcher...little confused
No, the matcher identify what to pass to the mailet itself.
To "block" the mail from being processed by the following you have to
use a consuming mailet (a mailet that sets the message state to GHOST).
Most mailets sets the state to GHOST unless you specify a
<passThrough>true</passThrough> attribute in the configuration.
Stefano
Santosh wrote:
> I'm little confused about the working of a matcher. It's a simple
doubt
> though.
>
> Consider a mail with:
> From: someone@somedomain.com
> To: a@adomain.com , b@adomain.com, c@adomain.com
>
> In the transport processor:
> <mailet match="RecipientIsLocal " class="EchoMailet" /> --- call it 1
>
> <mailet match="HostIsLocal" class=" EchoMailet " /> -- call it 2
>
> Current HostName: adomain.com
>
> localUsers: a & b (but not c)
>
> EchoMailet simply prints the recipient addresses in the Mail object it
> receives in the service(Mail mail) method. It extends GenericMailet.
>
> According to my observations,
>
> after 1: EchoMailet prints
> a@adomain.com
> b@adomain.com
>
> after 2: EchoMailet prints
> a@adomain.com
> b@adomain.com
> c@adomain.com
>
> Shouldn't the matcher RecipientIsLocal filter out a@adomain.com &
> b@adomain.com such that at/after 2 only c@adomain.com? Isn't this the
> _expected_ behavior of any matcher?
>
> Santosh.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org
Re: Working of Matcher...little confused
Posted by Stefano Bagnara <ap...@bago.org>.
No, the matcher identify what to pass to the mailet itself.
To "block" the mail from being processed by the following you have to
use a consuming mailet (a mailet that sets the message state to GHOST).
Most mailets sets the state to GHOST unless you specify a
<passThrough>true</passThrough> attribute in the configuration.
Stefano
Santosh wrote:
> I'm little confused about the working of a matcher. It's a simple doubt
> though.
>
> Consider a mail with:
> From: someone@somedomain.com
> To: a@adomain.com , b@adomain.com, c@adomain.com
>
> In the transport processor:
> <mailet match="RecipientIsLocal " class="EchoMailet" /> --- call it 1
>
> <mailet match="HostIsLocal" class=" EchoMailet " /> -- call it 2
>
> Current HostName: adomain.com
>
> localUsers: a & b (but not c)
>
> EchoMailet simply prints the recipient addresses in the Mail object it
> receives in the service(Mail mail) method. It extends GenericMailet.
>
> According to my observations,
>
> after 1: EchoMailet prints
> a@adomain.com
> b@adomain.com
>
> after 2: EchoMailet prints
> a@adomain.com
> b@adomain.com
> c@adomain.com
>
> Shouldn't the matcher RecipientIsLocal filter out a@adomain.com &
> b@adomain.com such that at/after 2 only c@adomain.com? Isn't this the
> _expected_ behavior of any matcher?
>
> Santosh.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org