@Bean(name="repository", active=true, parent=CounterDataLogger.class) public class CounterDataLoggerRepoBean extends MDRepositoryBeanWithStatistics<CounterDataLoggerRepositoryIfc> implements CounterDataLoggerRepositoryIfc
Modifier and Type | Class and Description |
---|---|
static class |
CounterDataLoggerRepoBean.CounterDataLoggerConfigBean |
MDRepositoryBean.MDRepositoryConfigBean<A extends DataSourceAware>, MDRepositoryBean.SelectorType
aliases, dataSourceSelection
BOSH_CONNS_COL, C2S_CONNS_COL, C2S_PACKETS_COL, CPU_USAGE_COL, EXT_PACKETS_COL, HOSTNAME_COL, IQS_COL, MEM_USAGE_COL, MESSAGES_COL, MUC_PACKETS_COL, PRESENCES_COL, PUBSUB_PACKETS_COL, REGISTERED_COL, S2S_CONNS_COL, S2S_PACKETS_COL, SM_CONNECTIONS_COL, SM_PACKETS_COL, SM_SESSIONS_COL, STATS_TABLE, UPTIME_COL, VHOSTS_COL, WS2S_CONNS_COL, WS2S_PACKETS_COL
Constructor and Description |
---|
CounterDataLoggerRepoBean() |
Modifier and Type | Method and Description |
---|---|
void |
addStatsLogEntry(String hostname,
float cpu_usage,
float mem_usage,
long uptime,
int vhosts,
long sm_packets,
long muc_packets,
long pubsub_packets,
long c2s_packets,
long ws2s_packets,
long s2s_packets,
long ext_packets,
long presences,
long messages,
long iqs,
long registered,
int c2s_conns,
int ws2s_conns,
int bosh_conns,
int s2s_conns,
int sm_sessions,
int sm_connections) |
protected Class<? extends CounterDataLoggerRepositoryIfc> |
findClassForDataSource(DataSource dataSource)
Method returns class implementing repository which supports data source instance provided in parameter.
|
Class<?> |
getDefaultBeanClass()
Returns default class for all bean which are defined using configuration as subbeans of bean implementing this
interface.
|
void |
register(Kernel kernel)
Method called when bean is being registered allowing developer to programatically register other beans.
|
void |
setDataSource(DataSource ds)
Method called to provide class with instance of a data source.
|
void |
unregister(Kernel kernel)
Method called while bean is being unregistered.
|
everyHour, everyMinute, everySecond, getRepositories, getRepository, getStatistics, setStatisticsEnabled, updateDataSourceAware, wrapInProxy
beforeUnregister, getName, initialize, initializeRepository, onDataSourceChange, registerIfNotExists, repositoriesStream, setDataSourceBean
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
belongsTo
public void addStatsLogEntry(String hostname, float cpu_usage, float mem_usage, long uptime, int vhosts, long sm_packets, long muc_packets, long pubsub_packets, long c2s_packets, long ws2s_packets, long s2s_packets, long ext_packets, long presences, long messages, long iqs, long registered, int c2s_conns, int ws2s_conns, int bosh_conns, int s2s_conns, int sm_sessions, int sm_connections)
addStatsLogEntry
in interface CounterDataLoggerRepositoryIfc
protected Class<? extends CounterDataLoggerRepositoryIfc> findClassForDataSource(DataSource dataSource) throws DBInitException
MDRepositoryBean
findClassForDataSource
in class MDRepositoryBean<CounterDataLoggerRepositoryIfc>
DBInitException
public Class<?> getDefaultBeanClass()
RegistrarBeanWithDefaultBeanClass
getDefaultBeanClass
in interface RegistrarBeanWithDefaultBeanClass
public void register(Kernel kernel)
RegistrarBean
register
in interface RegistrarBean
register
in class MDRepositoryBean<CounterDataLoggerRepositoryIfc>
kernel
- - instance from local scopepublic void setDataSource(DataSource ds)
DataSourceAware
setDataSource
in interface DataSourceAware
public void unregister(Kernel kernel)
RegistrarBean
unregister
in interface RegistrarBean
unregister
in class MDRepositoryBean<CounterDataLoggerRepositoryIfc>
kernel
- - instance from local scopeCopyright © 2004–2021 "Tigase, Inc.". All rights reserved.