Package io.antmedia.datastore.db
Class DataStoreFactory
java.lang.Object
io.antmedia.datastore.db.DataStoreFactory
- All Implemented Interfaces:
IDataStoreFactory
,Aware
,ApplicationContextAware
-
Field Summary
Modifier and TypeFieldDescriptionprivate AppSettings
private DataStore
static final String
static final String
static final String
static final String
private String
private String
private String
private String
One of the DB_TYPE_*private String
private String
private static org.slf4j.Logger
static final String
static final String
static final String
static final String
static final String
private io.vertx.core.Vertx
private boolean
private boolean
Fields inherited from interface io.antmedia.datastore.db.IDataStoreFactory
BEAN_NAME
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
init()
boolean
boolean
void
setApplicationContext
(ApplicationContext applicationContext) void
setDataStore
(DataStore dataStore) void
void
void
setDbPassword
(String dbPassword) void
void
void
setWriteStatsToDatastore
(boolean writeStatsToDatastore) void
setWriteSubscriberEventsToDatastore
(boolean writeSubscriberEventsToDatastore)
-
Field Details
-
DB_TYPE_MEMORYDB
- See Also:
-
DB_TYPE_MAPDB
- See Also:
-
DB_TYPE_MONGODB
- See Also:
-
DB_TYPE_REDISDB
- See Also:
-
SETTINGS_DB_NAME
- See Also:
-
SETTINGS_DB_TYPE
- See Also:
-
SETTINGS_DB_HOST
- See Also:
-
SETTINGS_DB_USER
- See Also:
-
SETTINGS_DB_PASS
- See Also:
-
logger
private static org.slf4j.Logger logger -
dataStore
-
dbName
-
dbType
One of the DB_TYPE_* -
dbHost
-
dbUser
-
dbPassword
-
hostAddress
-
vertx
private io.vertx.core.Vertx vertx -
writeStatsToDatastore
private boolean writeStatsToDatastore -
writeSubscriberEventsToDatastore
private boolean writeSubscriberEventsToDatastore -
appSettings
-
-
Constructor Details
-
DataStoreFactory
public DataStoreFactory()
-
-
Method Details
-
getDbName
-
setDbName
-
getDbType
-
setDbType
-
getDbHost
-
setDbHost
-
getDbUser
-
setDbUser
-
setDbPassword
-
init
public void init() -
getDataStore
- Specified by:
getDataStore
in interfaceIDataStoreFactory
-
setDataStore
-
isWriteStatsToDatastore
public boolean isWriteStatsToDatastore() -
setWriteStatsToDatastore
public void setWriteStatsToDatastore(boolean writeStatsToDatastore) -
setApplicationContext
- Specified by:
setApplicationContext
in interfaceApplicationContextAware
- Throws:
BeansException
-
setWriteSubscriberEventsToDatastore
public void setWriteSubscriberEventsToDatastore(boolean writeSubscriberEventsToDatastore) -
isWriteSubscriberEventsToDatastore
public boolean isWriteSubscriberEventsToDatastore()
-