Instead of performing the necessary logic in the init method, why not try "lazy-loading." Only initialize whatever you need when it is requested the first time. By the way, what are you trying to do? I've never heard of anyone having this kind of requirement/architecture. Just curious.
----- Original Message ----- From: "Mayne, Peter" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Sent: Sunday, March 23, 2003 7:42 PM Subject: load-on-startup order > Tomcat 4.1.18 > > I have two applications, A and B, where a servlet in B depends on a servlet > in A being up, so I have > > in A's web.xml: > > <servlet> > ... > <load-on-startup>1</load-on-startup> > </servlet> > > in B's web.xml: > > <servlet> > ... > <load-on-startup>5</load-on-startup> > </servlet> > > which should make A start first. However, when Tomcat starts, B's init() is > called first. B's init() attempts to make a connection to A's servlet, but A > hasn't started yet, so everything hangs. > > Am I doing this correctly? > > Thanks. > > PJDM > -- > Peter Mayne > Technology Consultant > Spherion Technology Solutions > Level 1, 243 Northbourne Avenue, Lyneham, ACT, 2602 > T: 61 2 62689727 F: 61 2 62689777 > The information contained in this email and any attachments to it: > > (a) may be confidential and if you are not the intended recipient, any interference with, > use, disclosure or copying of this material is unauthorised and prohibited; and > > (b) may contain personal information of the recipient and/or the sender as defined > under the Privacy Act 1988 (Cth). Consent is hereby given by the recipient(s) to > collect, hold and use such information and any personal information contained in a > response to this email, for any reasonable purpose in the ordinary course of > Spherion's > business, including forwarding this email internally or disclosing it to a third party. All > personal information collected by Spherion will be handled in accordance with > Spherion's Privacy Policy. If you have received this email in error, please notify the > sender and delete it. > > (c) you agree not to employ or arrange employment for any candidate(s) supplied in > this email and any attachments without first entering into a contractual agreement with > Spherion. You further agree not to divulge any information contained in this document > to any person(s) or entities without the express permission of Spherion. > > > > > --------------------------------------------------------------------- > 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]
