Something I do often is create a servlet that is loaded at app startup that
loads and populates a variety of objects that I need for general use in its
init method.

If I can't guarantee that users will always use a single point of entry
(never the case in a content-heavy site), I avoid depending on a single
action to do app-wide heavy lifting.

For whatever that's worth - probably a "worst practice"...

Chris

> -----Original Message-----
> From: Jerry Jalenak [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, June 24, 2003 8:53 AM
> To: 'Struts Users Mailing List'; '[EMAIL PROTECTED]'
> Subject: RE: Best practices - help
>
>
> This is something we do that works extremely well.  The path on the
> <global-forward/> can point to a set up action where you can initialize /
> populate all of those things that you application needs.  The set
> up action
> would then forward to your first .JSP or tile definition.
>
>
>
> Jerry Jalenak
> Team Lead, Web Publishing
> LabOne, Inc.
> 10101 Renner Blvd.
> Lenexa, KS  66219
> (913) 577-1496
>
> [EMAIL PROTECTED]
>
>
> -----Original Message-----
> From: Steve Raeburn [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, June 24, 2003 6:32 AM
> To: Struts Users Mailing List
> Subject: RE: Best practices - help
>
>
> have a welcome jsp page that redirects to your action:
>
> struts-config.xml:
>
>   <global-forwards>
>     <forward name="welcome" path="/myaction.do"/>
>   </global-forwards>
>
> index.jsp:
>
>   <%@ taglib uri="http://jakarta.apache.org/struts/tags-logic";
> prefix="logic" %>
>   <logic:redirect forward="welcome"/>
>
> (that's the whole jsp file, not just a snippet!)
>
> Steve
>
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> > Sent: June 24, 2003 4:11 AM
> > To: [EMAIL PROTECTED]
> > Subject: Re: Best practices - help
> >
> >
> > Hi Steve,
> >
> > The problem is that /MyLayer.jsp happens to be my welcome page.
> >
> > This page has to be displayed on start up.How  do I get struts
> process my
> > Action servlet,myAction, in order to give /MyLayer.jsp the
> > content it needs?
> >
> > Thanks
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> This transmission (and any information attached to it) may be
> confidential and is intended solely for the use of the individual
> or entity to which it is addressed. If you are not the intended
> recipient or the person responsible for delivering the
> transmission to the intended recipient, be advised that you have
> received this transmission in error and that any use,
> dissemination, forwarding, printing, or copying of this
> information is strictly prohibited. If you have received this
> transmission in error, please immediately notify LabOne at the
> following email address: [EMAIL PROTECTED]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to