Hello,
  I tried to do a Singleton Instance of a class containing a Hashmap of
entried mapping IPs to session objects to be used later for session
invalidation. I instantiate the singleton instance with a generic servlet,
but I dont think it worked when I started the server because I didnt see my
println message when I started the server, and I can when I call the servlet
explicitly. How do I know if I correctly setup the servlet to startup when
the server starts?

Also, having a singleton instance, do I still need to import the class in
the jsp page I use it in? Should it find it anyways if I dont?

Also, when I do put it in the import, for some reason the singleton instance
is intantiated twice in different JSP pages, thus furthering my belief that
this class was created possibly in the first JSP page and discarded, then
recreated in the second JSP page. Somebody help, This is getting ridiculous
I originally tried this with application scope but it couldnt find the
instance in another jsp page though it was in the same application.

/***********************************************************************
 <servlet>
     <servlet-name>Hasher</servlet-name>
     <servlet-class>HasherServlet</servlet-class>
     <load-on-startup>-2147483646</load-on-startup>
 </servlet>
 <servlet-mapping>
     <servlet-name>Hasher<servlet-name>
     <url-pattern>/db/servlet/HasherServlet</url-pattern>
 </servlet-mapping>

/***********************************************************************

Warmest Regards,
Eric Dunn
Software Engineer
[EMAIL PROTECTED]

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to