Pull the code from JSP, place it in a servlet and define a servlet to be initiated automatically in web.xml.
<servlet>
<servlet-name>myServlet</servlet-name>
<servlet-class>com.class.MyServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
(Servlet can forward to the same JSP so that requests could still get that JSP)