if (getState() == OFFLINE)
{
LOG.warn("Repository " + getName() + " is OFFLINE.");
}
WorkspaceContainer workspaceContainer = repositoryContainer.getWorkspaceContainer(workspaceName);
if (workspaceContainer == null || !workspaceContainer.getWorkspaceInitializer().isWorkspaceInitialized())
{
throw new RepositoryException("Workspace " + workspaceName + " not found or workspace is not initialized");
}
SessionFactory sessionFactory = workspaceContainer.getSessionFactory();
Identity id = new Identity(DynamicIdentity.DYNAMIC, membershipEntries);
return sessionFactory.createSession(new ConversationState(id));
}