An example of using InvocableServlet.

Invoke Servlet Methods From Java Apps

David Tayouri
Listing 5. An example of using InvocableServlet.

public class MyServlet extends InvocableServlet
  public void doPost(
    HttpServletRequest req,
    HttpServletResponse res)
    throws ServletException, IOException
    invokeMethod(req, res);

  public void sendEvent(long popId)
    throws EventHandlingException
    System.out.println("sendEvent was called");


Sign up for our newsletter.

Terms and Privacy Policy consent

I agree to this site's Privacy Policy.

Upcoming Events