public Session createWithAgent(final Principal _principal, final String credentials, String agent, String ip) { final CreationRequest req = new CreationRequest(); req.principal = _principal; req.credentials = credentials; req.agent = agent; req.ip = ip; return createFromRequest(req); }
public Object call() throws Exception { sessionManager.close(uuid); return null; } });
@Override public void executeCloseSession(String uuid) { /* working through all readers because we want a failure exception if the session exists as read-only */ for (final P provider : read) { if (provider.findSessionIdByUuid(uuid) != null) { provider.executeCloseSession(uuid); } } }
public int getReferenceCount(String uuid) { SessionContext ctx = cache.getSessionContext(uuid); return ctx.count().get(); }
@Override public Session findSessionById(long id, org.hibernate.Session hibernateSession) { for (final P provider : read) { final Session session = provider.findSessionById(id, hibernateSession); if (session != null) { return session; } } return null; }
@Override public Long findSessionIdByUuid(String uuid, ServiceFactory sf) { for (final P provider : read) { final Long sessionId = provider.findSessionIdByUuid(uuid, sf); if (sessionId != null) { return sessionId; } } return null; }
public Session call() throws Exception { return mgr.update(session); }}); return ex.get(future);
private boolean executeCheckPassword(final Principal _principal, final String credentials) { Boolean ok = executeCheckPasswordRO(_principal, credentials); if (ok == null) { ok = executeCheckPasswordRW(_principal, credentials); } return ok; }
public void setOutput(String session, String key, Object object) throws RemovedSessionException { setEnvironmentVariable(session, key, object, OUTPUT_ENVIRONMENT); }
public Object getInput(String session, String key) throws RemovedSessionException { return getEnvironmentVariable(session, key, INPUT_ENVIRONMENT); }
public List<Session> call() throws Exception { return mgr.findSameUser(uuid, agent); }}); return ex.get(future);
@Override public Long findSessionIdByUuid(String uuid, ServiceFactory sf) { return findSessionIdByUuid(uuid); }
@Override public Session findSessionById(long id, org.hibernate.Session session) { return findSessionById(id, (ServiceFactory) null); }
public Map<String, Object> outputEnvironment(String session) { return environment(session, OUTPUT_ENVIRONMENT); }
public Session createWithAgent(Principal principal, String agent, String ip) { final CreationRequest req = new CreationRequest(); req.principal = principal; req.agent = agent; req.ip = ip; return createFromRequest(req); }
@Override public Session findSessionById(long id, ServiceFactory sf) { for (final P provider : read) { final Session session = provider.findSessionById(id, sf); if (session != null) { return session; } } return null; }
@Override public Long findSessionIdByUuid(String uuid) { for (final P provider : read) { final Long sessionId = provider.findSessionIdByUuid(uuid); if (sessionId != null) { return sessionId; } } return null; } }
public void setInput(String session, String key, Object object) throws RemovedSessionException { setEnvironmentVariable(session, key, object, INPUT_ENVIRONMENT); }
public Object getOutput(String session, String key) throws RemovedSessionException { return getEnvironmentVariable(session, key, OUTPUT_ENVIRONMENT); }
public List<Session> call() throws Exception { return mgr.findSameUser(uuid, "OMERO.insight", "OMERO.web", "OMERO.importer"); }}); return ex.get(future);