I've been working on the javamail code, mostly on the base implementation. Today, I finally started looking at the Geronimo mail GBean code, and added GBean adaptors for the NNTPStore and NNTPTransport protocols.

I suspect it really has not been used much, since prior shipped releases only had support for SMTP without authentication, but we may need to take a look at adding some default mail authenticators. As structured now, there is a configured MailGBean that can manage multiple mail resources (typically, a Store/Transport pair, but it can manage more than that). It is configured with a Collection of protocol GBeans that describe the different protocol properties. There is one ProtocolGBean for each type of transport or store Geronimo supports (e.g., SMTP, POP3, NNTP, etc.).

Additionally, the constructor for MailGBean takes an instance of javax.mail.Authenticator, which will be used by the transport/store services for requesting site passwords. The ProtocolGBeans allow configuring of the user names, but no password information. The passwords need to be retrieved from the Authenticator at run time.

Currently, there are no default Authenticator implementations included in Geronimo. When only non-authenticated SMTP was available, this was not much of an issue. However, now that Geronimo has a javamail implemenation that supports authenticated SMTP, NNTP, and POP3 (with IMAP on the radar screen), this has become a little more important.

So, what sort of authenticator(s) should be written so users can configure mail support without needing to write their own Authenticator instances? I think we need something, but I'm not too clear how sophisticated the something needs to be.

I'll also admit my ignorance on how some of the GBean configuration references get resolved, since I've been working on the javamail base code, which is not really connected to the rest of Geronimo. Given I have an appropriate implementation of the Authenticator class to use, how do I configure the MailGBean so it is properly initialized with correct Authenticator instance?

Rick




Reply via email to