public class MongoSessionDataStoreFactory extends AbstractSessionDataStoreFactory
Modifier and Type | Field and Description |
---|---|
(package private) java.lang.String |
_collectionName |
(package private) java.lang.String |
_connectionString |
(package private) java.lang.String |
_dbName |
(package private) java.lang.String |
_host |
(package private) int |
_port |
Constructor and Description |
---|
MongoSessionDataStoreFactory() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getCollectionName() |
java.lang.String |
getConnectionString() |
java.lang.String |
getDbName() |
java.lang.String |
getHost() |
int |
getPort() |
SessionDataStore |
getSessionDataStore(SessionHandler handler) |
void |
setCollectionName(java.lang.String collectionName) |
void |
setConnectionString(java.lang.String connectionString) |
void |
setDbName(java.lang.String dbName) |
void |
setHost(java.lang.String host) |
void |
setPort(int port) |
getGracePeriodSec, getSavePeriodSec, setGracePeriodSec, setSavePeriodSec
java.lang.String _dbName
java.lang.String _collectionName
java.lang.String _host
java.lang.String _connectionString
int _port
public java.lang.String getHost()
public void setHost(java.lang.String host)
host
- the host to setpublic int getPort()
public void setPort(int port)
port
- the port to setpublic java.lang.String getDbName()
public void setDbName(java.lang.String dbName)
dbName
- the dbName to setpublic java.lang.String getConnectionString()
public void setConnectionString(java.lang.String connectionString)
connectionString
- the connection string to set. This has priority over dbHost and portpublic java.lang.String getCollectionName()
public void setCollectionName(java.lang.String collectionName)
collectionName
- the collectionName to setpublic SessionDataStore getSessionDataStore(SessionHandler handler) throws java.lang.Exception
java.lang.Exception
- UnknownHostException
if any issue while resolving MongoDB HostSessionDataStoreFactory.getSessionDataStore(org.eclipse.jetty.server.session.SessionHandler)