/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. */ public synchronized void idle() throws Exception { save(false); _idled = true; }
/** * Idle the session to reduce session memory footprint. * * The session is idled by persisting it, then clearing the session values attribute map and finally setting * it to an idled state. * @throws Exception if unable to save session */ public synchronized void idle() throws Exception { save(false); _idled = true; }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { __log.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(true); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { LOG.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(reactivate); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { LOG.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(reactivate); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { LOG.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(reactivate); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { __log.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(true); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { __log.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(true); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { __log.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(true); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { LOG.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(reactivate); }
public void saveSessions(boolean reactivate) throws Exception { if (_storeDir==null || !_storeDir.exists()) { return; } if (!_storeDir.canWrite()) { __log.warn ("Unable to save Sessions: Session persistence storage directory "+_storeDir.getAbsolutePath()+ " is not writeable"); return; } for (HashedSession session : _sessions.values()) session.save(true); }
/** * @see org.eclipse.jetty.server.SessionManager#renewSessionId(java.lang.String, java.lang.String, java.lang.String, java.lang.String) */ @Override public void renewSessionId(String oldClusterId, String oldNodeId, String newClusterId, String newNodeId) { try { Map<String,HashedSession> sessions=_sessions; if (sessions == null) return; HashedSession session = sessions.remove(oldClusterId); if (session == null) return; session.remove(); //delete any previously saved session session.setClusterId(newClusterId); //update ids session.setNodeId(newNodeId); session.save(); //save updated session: TODO consider only saving file if idled sessions.put(newClusterId, session); } catch (Exception e) { LOG.warn(e); } }
synchronized void save(boolean reactivate) throws Exception { // Only idle the session if not already idled and no previous save/idle has failed if (!isIdled() && !_saveFailed) { if (LOG.isDebugEnabled()) LOG.debug("Saving {} {}",super.getId(),reactivate); try { willPassivate(); save(); if (reactivate) didActivate(); else clearAttributes(); } catch (Exception e) { LOG.warn("Problem saving session " + super.getId(), e); _idled=false; // assume problem was before _values.clear(); } } }