title: Execute servlet on startup of the application
body: <p>I build a web application with JSPs and in my servlet I have:</p>
  
  <pre><code>public class MyServlet extends HttpServlet {
      protected void processRequest(HttpServletRequest request, HttpServletResponse response)
          throws ServletException, IOException {
  
             init();        
             HttpSession session = request.getSession(true);
             //more code...
      }
  }
  </code></pre>
  
  <p>Till now my serlvet is called, when the JSP page calls it like <code>&lt;a href="MyServlet.."&gt;</code>. What I want is whenever the application starts, the servlet to be executed as well. I could have a button in my 1st page like "START" and there to call the servlet.. But, can I avoid this?   </p>