On Thu, 31 Mar 2011 06:55:08 -0400
Allen Johnson <[email protected]> wrote:

> > Is there some way to convince Jetty (or tomcat, or ...) to run the
> > init methods of a servlet before the first request comes in? Or maybe
> > a pointer to the appropriate forum?
> 
> You can tell a servlet to init on startup with something like this in
> your web.xml:
> 
> <servlet>
>   <servlet-name>test-servlet</servlet-name>
>   <servlet-class>myapp.servlet</servlet-class>
>   <load-on-startup>1</load-on-startup>
> </servlet>
> 
> This tells the container to initialize the servlet before any
> requests. The number is just the ordering in which the servlets are
> initialized.

Cool. Worked like a charm. Thanks.

      <mike

-- 
Mike Meyer <[email protected]>             http://www.mired.org/consulting.html
Independent Software developer/SCM consultant, email for more information.

O< ascii ribbon campaign - stop html mail - www.asciiribbon.org

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to