Package org.apache.catalina

Examples of org.apache.catalina.Manager.findSession()


                    String sessionId = ss[0];
                    String appName = ss[1];
                    Context context = getContainerWrapper().getTomcatContainer().findContext(appName);
                    if (context != null) {
                        Manager manager = context.getManager();
                        Session session = manager.findSession(sessionId);
                        if (session != null && session.isValid()) {
                            session.expire();
                        }
                    } else {
                        return new ModelAndView("errors/paramerror");
View Full Code Here


  
   private Session createAndUseSession(JBossCacheManager<?> manager, String id, boolean canCreate, boolean access) throws Exception
   {
      //    Shift to Manager interface when we simulate Tomcat
      Manager mgr = manager;
      Session sess = mgr.findSession(id);
      assertNull("session does not exist", sess);
      try
      {
         sess = mgr.createSession(id);
         if (!canCreate)
View Full Code Here

  
   private void useSession(JBossCacheManager<?> manager, String id) throws Exception
   {
      //    Shift to Manager interface when we simulate Tomcat
      Manager mgr = manager;
      Session sess = mgr.findSession(id);
      assertNotNull("session exists", sess);
     
      sess.access();
      sess.getSession().setAttribute("test", "test");
     
View Full Code Here

                           boolean canCreate, boolean access)
         throws Exception
   {
      //    Shift to Manager interface when we simulate Tomcat
      Manager mgr = dspm;
      Session sess = mgr.findSession(id);
      assertNull("session does not exist", sess);
      try
      {
         sess = mgr.createSession(id);
         if (!canCreate)
View Full Code Here

   private Session useSession(DataSourcePersistentManager dspm, String id)
         throws Exception
   {
      //    Shift to Manager interface when we simulate Tomcat
      Manager mgr = dspm;
      Session sess = mgr.findSession(id);
      assertNotNull("session exists", sess);
     
      sess.access();
      sess.getSession().setAttribute("test", "test");
     
View Full Code Here

  
   private Session createAndUseSession(JBossCacheManager<?> manager, String id, boolean canCreate, boolean access) throws Exception
   {
      //    Shift to Manager interface when we simulate Tomcat
      Manager mgr = manager;
      Session sess = mgr.findSession(id);
      assertNull("session does not exist", sess);
      try
      {
         sess = mgr.createSession(id);
         if (!canCreate)
View Full Code Here

            Manager manager = container.getManager();
            if (manager != null && hsession != null)
            {
               try
               {
                  session = manager.findSession(hsession.getId());
               }
               catch (IOException ignore)
               {
               }
            }
View Full Code Here

            Manager manager = container.getManager();
            if (manager != null && hsession != null)
            {
               try
               {
                  session = manager.findSession(hsession.getId());
               }
               catch (IOException ignore)
               {
               }
            }
View Full Code Here

            Manager manager = context.getManager();
            if (manager == null)
                return (false);
            Session session = null;
            try {
                session = manager.findSession(requestedSessionId);
            } catch (IOException e) {
                session = null;
            }
            if ((session != null) && session.isValid()) {
                return (true);
View Full Code Here

     */
    protected void createPrimaryIndicator(Request request) throws IOException {
        String id = request.getRequestedSessionId();
        if ((id != null) && (id.length() > 0)) {
            Manager manager = request.getContext().getManager();
            Session session = manager.findSession(id);
            if (session instanceof ClusterSession) {
                ClusterSession cses = (ClusterSession) session;
                if (cses != null) {
                    Boolean isPrimary = new Boolean(cses.isPrimarySession());
                    if (log.isDebugEnabled())
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.