Sessions and keep-alives

Discussions

Web tier: servlets, JSP, Web frameworks: Sessions and keep-alives

  1. Sessions and keep-alives (1 messages)

    hi All!

    I'm involved in a project that integrates two disparate web applications: webapp A is using WebSphere and webapp B is using Tomcat.

    The integration involves Single Sign On, with webapp A being the primary webapp from which webapp B is launched. webapp B is launched as a popup-window.

    My question is: how can i ensure that while the user is working on the webapp B popup, the parent window webapp A, does not time-out?

    Thanks in advance!
  2. Sessions and keep-alives[ Go to top ]

    Hi

    in webapp A add a servlet like this:

    public class RefreshSession extends HttpServlet
    {
      private static final String CONTENT_TYPE = "text/html";

      /**Process the HTTP Get request*/
      public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
      {
        response.setContentType(CONTENT_TYPE);
        PrintWriter out = response.getWriter();
        out.println("/* Refresh session Ok */");
      }
    }

    and in EVERY html page of webapp B insert
     <LINK REL=STYLESHEET TYPE="text/css" HREF="/webapp_b/RefreshSessionServletURL">

    than every page in webapp B will made a http request to RefreshSession servlet

    Best regards, Stefano