james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefano Bagnara" <apa...@bago.org>
Subject isLocalUser behaviour (Was: Out of the box virtualhosting)
Date Fri, 02 Sep 2005 17:27:15 GMT
The only real change I/we need is to be able to check user presence in a
single call (this would allow many different virtualhosting solutions, but
we can discuss them after this).

Currently we run MailetContext.isLocalServer(domain) and in the following
call MailetContext.isLocalUser(local-part).
Having 2 different calls does not allow us to check users associated to a
specific domain.

We have 3 options:
1) change the isLocalUser documentation saying that you MUST provide the
full email address
  1a) eventually allowing to use names without @ (the system will consider
automatically @localhost)
2) add a further method isLocalEmail(String local, String domain) or
isLocalEmail(String fullEmail) to the MailetContext
3) add a 2 parameter isLocalUser(String user, String domain)

This would replace the current client code:
mailetContext.isLocalServer(recipient.getHost()) &&

IMHO this is a good improvement over the current API way to resolve local
users (double call) and this would allow us to implement automatic
virtualhosting support.

In solution 2) and 3) I would also deprecate the current isLocalUser since
it does not make much sense to check wether an user is local without
checking the domain first.

My vote goes for "1a)" if we plan to add this in 2.3.0 because it would be
totally backward compatible but for "2)" if we delay this change to 3.0.

IMHO implementation details can be discussed after this one.


To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org

View raw message