On Sat, 24 Mar 2001, Remy Maucherat wrote:
> > craigmcc 01/03/24 12:52:08
> >
> > Modified: catalina build.xml
> > catalina/src/share/org/apache/naming/factory
> > ResourceFactory.java
> > Added: catalina/src/share/org/apache/naming/factory
> > MailSessionFactory.java
> > Log:
> > Add a naming context resource factory for javax.mail.Session resources
> > (compliant with J2EE requirements) so that web applications can look up
> > and utilize a preconfigured javax.mail.Session instance. The resource
> is
> > configured by creating <Resource> and <ResourceParams> elements nested
> in
> > the <Context> or <DefaultContext> element in "conf/server.xml" -- the
> > example application will be updated to demonstrate this shortly.
> >
> > NOTE: the mechanism by which new object factories are registered needs
> to
> > be generalized.
>
> Why ? You just need to specify a factory parameter in the reference
> parameters.
>
Where? This didn't work until I modified ResourceFactory to take care of
it, copying the way that the default resource factory for a DataSource is
set up.
Also, I noticed one other thing that I'm about to fix. The entries for
resources, EJB references, and so on are getting created in the
"java:com" context. According to the J2EE spec, they are supposed to be
in the "java:comp/env" context (along with environment entries). It's a
real simple patch, to be submitted shortly after I double check that it
works correctly.
> Remy
>
>
Craig