On Thu, Feb 10, 2011 at 03:26:45PM +0100, helix84 wrote:
> Mark, thanks for providing the useful details.
> 
> On Thu, Feb 10, 2011 at 15:05, Mark H. Wood <[email protected]> wrote:
> > if you drop your app.s any Host's appBase
> 
> I didn't understand this part. Can you rephrase?

Oops.  If you drop your app.s *into* any Host's appBase

> > then Tomcat assumes *it* created their Context fragments and will
> 
> I have question here. How can I make Tomcat create a Context fragment?
> If I use Tomcat manager, will it take care of that?

Sorry, I always build mine by hand.  I don't recall what year it was, the
last time I touched Manager.

I think that any time an app. is automagically deployed from an
appBase, a fragment will be created for it. [reads] The v6
documentation is still not as explicit as I'd like, but it's clearer
than v5 and yes, this seems to be the case.  (I'm reading Automatic
Application Deployment in the page "The Host Container" from the 6.0
Apache Tomcat Configuration Reference.)  That's probably the source of
the old contest between Tomcat and me for control of the fragments.
Hmmm, it looks like the Official Term is "Context file".

When a webapp is outside of any appBase, its pre-existing Context file
is the only way Tomcat would know of its existence, so Tomcat doesn't
need to create a Context file and thus has no need to destroy it
later.

> > happily destroy those fragments when it is pleased to do so.  You need
> > to make sure that your fragment-controlled app.s are outside of any
> > appBase to avoid this power struggle.
> 
> So what's in <Context docBase="" /> shouldn't be on disk under the
> directory specified in <Host appBase="webapps" />, but in a separate
> directory, did I get that right? (it is so in my config) If my apps we

Right.  In the test environment I have a bunch of [DSpace]s under
/home/mwood/dspaces; in production we put them in /opt.  Then the
fragment points to e.g. '/home/mwood/dspaces/trunk-1.7/webapps/xmlui'.

Ah, it's documented now!

    When using automatic deployment, the docBase defined by an XML
    Context file should be outside of the appBase directory.  If this
    is not the case difficulties may be experienced deploying the web
    application or the application may be deployed twice.

Not to mention trashing your handmade Context file should Tomcat take
it into its head to redeploy.

> under webapps, tomcat could delete my app's directory and context
> fragment (during undeploy?), but not the .war file, is that right?

I've only ever seen it delete the Context fragment file.  Mmm, there's
an explicit recommendation to delete the unpacked WAR contents when
redeploying a .war with unpackWARs left true.

-- 
Mark H. Wood, Lead System Programmer   [email protected]
Asking whether markets are efficient is like asking whether people are smart.

Attachment: pgpU2jfEOIJiz.pgp
Description: PGP signature

------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to