Re: JDNI factory name

Joseph Ottinger <[email protected]>
Newsgroups gmane.comp.web.sitemesh.general
Message-ID <[email protected]>
On Mon, 12 Apr 2004, Mathias Bogaert wrote:

> Yes you are right. I was mistaken.

No problems.

> I'm unsure if JMX would work.

Why not? I mean, exposing to JMX just involves an interface that exposes
control points - imagine an interface that had something like
"setFactoryClassName(String)" and "addNamedDecorator()", etc., things that
the internal XML configuration mechanism called to populate the initial
configuration anyway - those, plus a mechanism to SHOW the current
configuration, would allow runtime examination and modification of the
sitemesh config. Add in the ability to serialize the configuration and you
have a runtime configuration that *cranks.* (That's meant to be a good
thing.)

>
> ----- Original Message -----
> From: "Joseph Ottinger" <[email protected]>
> To: "Mathias Bogaert" <[email protected]>
> Cc: <[email protected]>
> Sent: Monday, April 12, 2004 2:33 PM
> Subject: Re: [Opensymphony-sitemesh] JDNI factory name
>
>
> > Doesn't java:comp/env refer to the current application's environment, as
> > opposed to a global reference? This would be specific to application
> > unless the app server itself returns the same reference for multiple
> > applications. Why couldn't you use both processes - look for it in the
> > filter attributes, then environment (i.e., env-entry), then JNDI.
> >
> > For that matter, would it be possible to use a JMX MBean to control
> > sitemesh?
> >
> > On Mon, 12 Apr 2004, Mathias Bogaert wrote:
> >
> > > Hi,
> > >
> > > I would like to change the way SiteMesh's Factory implementation class
> is
> > > being looked up. Currently it goes and look the JDNI InitialContext
> > > "java:comp/env/sitemesh.factory" property. IMO this is overkill and does
> not
> > > work well with multiple applications requiring a different SiteMesh
> factory
> > > while deployed on the same application server (JDNI spans multiple web
> > > applications). I therefore suggest using a context-param in web.xml
> (like
> > > spring).
> > >
> > > <context-param>
> > >     <param-name>sitemeshFactoryClass</param-name>
> > >
> > >
> <param-value>com.mycompany.util.sitemesh.SpecialSiteMeshFactory</param-value
> > > >
> > > </context-param>
> > >
> > > If not specified, it will automatically resolve into
> > > com.opensymphony.module.sitemesh.factory.DefaultFactory.
> > >
> > > Let me know if anyone finds this offensive :)
> > >
> > > Mathias
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This SF.Net email is sponsored by: IBM Linux Tutorials
> > > Free Linux tutorial presented by Daniel Robbins, President and CEO of
> > > GenToo technologies. Learn everything from fundamentals to system
> > > administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> > > _______________________________________________
> > > Opensymphony-sitemesh mailing list
> > > [email protected]
> > > https://lists.sourceforge.net/lists/listinfo/opensymphony-sitemesh
> > >
> >
> > -----------------------------------------------------------------------
> > Joseph B. Ottinger                             http://enigmastation.com
> > IT Consultant                                    [email protected]
> > Editor-in-Chief - Java Developer's Journal   [email protected]
> >
> >
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: IBM Linux Tutorials
> Free Linux tutorial presented by Daniel Robbins, President and CEO of
> GenToo technologies. Learn everything from fundamentals to system
> administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> _______________________________________________
> Opensymphony-sitemesh mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-sitemesh
>

-----------------------------------------------------------------------
Joseph B. Ottinger                             http://enigmastation.com
IT Consultant                                    [email protected]
Editor-in-Chief - Java Developer's Journal   [email protected]



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.