public class DocumentStoreStats extends java.lang.Object implements DocumentStoreStatsCollector, DocumentStoreStatsMBean
Modifier and Type | Field and Description |
---|---|
static int |
PERF_LOG_THRESHOLD |
TYPE
Constructor and Description |
---|
DocumentStoreStats(StatisticsProvider provider) |
Modifier and Type | Method and Description |
---|---|
void |
doneCreate(long timeTakenNanos,
Collection<? extends Document> collection,
java.util.List<java.lang.String> ids,
boolean insertSuccess)
Called when a document is created in the given collection
|
void |
doneCreateOrUpdate(long timeTakenNanos,
Collection<? extends Document> collection,
java.util.List<java.lang.String> ids)
Called when multiple document are either created or updated.
|
void |
doneFindAndModify(long timeTakenNanos,
Collection<? extends Document> collection,
java.lang.String key,
boolean newEntry,
boolean success,
int retryCount)
Called when a update operation was completed which affected single
document.
|
void |
doneFindCached(Collection<? extends Document> collection,
java.lang.String key)
Called when a document with given key is found from the cache
|
void |
doneFindUncached(long timeTakenNanos,
Collection<? extends Document> collection,
java.lang.String key,
boolean docFound,
boolean isSlaveOk)
Called when a document with given key is read from remote store
|
void |
doneQuery(long timeTakenNanos,
Collection<? extends Document> collection,
java.lang.String fromKey,
java.lang.String toKey,
boolean indexedProperty,
int resultSize,
long lockTime,
boolean isSlaveOk)
Called when query with given parameters is performed
|
void |
doneRemove(long timeTakenNanos,
Collection<? extends Document> collection,
int removeCount)
Called when a remove operation for documents was completed.
|
javax.management.openmbean.CompositeData |
getCreateJournalHistory() |
javax.management.openmbean.CompositeData |
getCreateNodesHistory() |
javax.management.openmbean.CompositeData |
getFindCachedNodesHistory() |
javax.management.openmbean.CompositeData |
getFindNodesFromPrimaryHistory() |
javax.management.openmbean.CompositeData |
getFindNodesFromSlaveHistory() |
javax.management.openmbean.CompositeData |
getFindNodesMissingHistory() |
javax.management.openmbean.CompositeData |
getFindSplitNodesHistory() |
long |
getJournalCreateCount() |
long |
getJournalReadCount() |
long |
getNodesCreateCount() |
long |
getNodesFindCount() |
long |
getNodesFindMissingCount() |
long |
getNodesFindQueryCount() |
long |
getNodesReadByQueryCount() |
long |
getNodesRemoveCount() |
long |
getNodesUpdateCount() |
javax.management.openmbean.CompositeData |
getQueryJournalHistory() |
javax.management.openmbean.CompositeData |
getQueryNodesFromPrimaryHistory() |
javax.management.openmbean.CompositeData |
getQueryNodesFromSlaveHistory() |
javax.management.openmbean.CompositeData |
getQueryNodesLockHistory() |
javax.management.openmbean.CompositeData |
getRemoveNodesHistory() |
javax.management.openmbean.CompositeData |
getUpdateNodesFailureHistory() |
javax.management.openmbean.CompositeData |
getUpdateNodesHistory() |
javax.management.openmbean.CompositeData |
getUpdateNodesRetryHistory() |
public static final int PERF_LOG_THRESHOLD
public DocumentStoreStats(StatisticsProvider provider)
public void doneFindCached(Collection<? extends Document> collection, java.lang.String key)
DocumentStoreStatsCollector
doneFindCached
in interface DocumentStoreStatsCollector
collection
- the collectionkey
- collection key which is foundpublic void doneFindUncached(long timeTakenNanos, Collection<? extends Document> collection, java.lang.String key, boolean docFound, boolean isSlaveOk)
DocumentStoreStatsCollector
doneFindUncached
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionkey
- collection keydocFound
- true if document is foundisSlaveOk
- true if find was performed against a secondary instancepublic void doneQuery(long timeTakenNanos, Collection<? extends Document> collection, java.lang.String fromKey, java.lang.String toKey, boolean indexedProperty, int resultSize, long lockTime, boolean isSlaveOk)
DocumentStoreStatsCollector
doneQuery
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionfromKey
- the start value (excluding)toKey
- the end value (excluding)indexedProperty
- true if indexedProperty was specifiedresultSize
- number of documents found for given querylockTime
- time in millis to acquire any lock (-1
if no lock was required)isSlaveOk
- true if find was performed against a secondary instancepublic void doneCreate(long timeTakenNanos, Collection<? extends Document> collection, java.util.List<java.lang.String> ids, boolean insertSuccess)
DocumentStoreStatsCollector
doneCreate
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionids
- list of ids request to be createdinsertSuccess
- true if the insert was successfulpublic void doneCreateOrUpdate(long timeTakenNanos, Collection<? extends Document> collection, java.util.List<java.lang.String> ids)
DocumentStoreStatsCollector
doneCreateOrUpdate
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionids
- list of ids request to be created or updatedpublic void doneFindAndModify(long timeTakenNanos, Collection<? extends Document> collection, java.lang.String key, boolean newEntry, boolean success, int retryCount)
DocumentStoreStatsCollector
doneFindAndModify
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionkey
- collection which got updated or insertednewEntry
- true if the document was newly created due to given operationsuccess
- true if the update was successretryCount
- number of retries done to get the updatepublic void doneRemove(long timeTakenNanos, Collection<? extends Document> collection, int removeCount)
DocumentStoreStatsCollector
doneRemove
in interface DocumentStoreStatsCollector
timeTakenNanos
- time takencollection
- the collectionremoveCount
- the number of removed documentspublic long getNodesFindCount()
getNodesFindCount
in interface DocumentStoreStatsMBean
public long getNodesFindQueryCount()
getNodesFindQueryCount
in interface DocumentStoreStatsMBean
public long getNodesFindMissingCount()
getNodesFindMissingCount
in interface DocumentStoreStatsMBean
public long getNodesReadByQueryCount()
getNodesReadByQueryCount
in interface DocumentStoreStatsMBean
public long getNodesCreateCount()
getNodesCreateCount
in interface DocumentStoreStatsMBean
public long getNodesUpdateCount()
getNodesUpdateCount
in interface DocumentStoreStatsMBean
public long getNodesRemoveCount()
getNodesRemoveCount
in interface DocumentStoreStatsMBean
public long getJournalCreateCount()
getJournalCreateCount
in interface DocumentStoreStatsMBean
public long getJournalReadCount()
getJournalReadCount
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getFindCachedNodesHistory()
getFindCachedNodesHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getFindSplitNodesHistory()
getFindSplitNodesHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getFindNodesFromPrimaryHistory()
getFindNodesFromPrimaryHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getFindNodesFromSlaveHistory()
getFindNodesFromSlaveHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getFindNodesMissingHistory()
getFindNodesMissingHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getQueryNodesFromSlaveHistory()
getQueryNodesFromSlaveHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getQueryNodesFromPrimaryHistory()
getQueryNodesFromPrimaryHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getQueryNodesLockHistory()
getQueryNodesLockHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getQueryJournalHistory()
getQueryJournalHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getCreateJournalHistory()
getCreateJournalHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getCreateNodesHistory()
getCreateNodesHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getUpdateNodesHistory()
getUpdateNodesHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getUpdateNodesRetryHistory()
getUpdateNodesRetryHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getUpdateNodesFailureHistory()
getUpdateNodesFailureHistory
in interface DocumentStoreStatsMBean
public javax.management.openmbean.CompositeData getRemoveNodesHistory()
getRemoveNodesHistory
in interface DocumentStoreStatsMBean
Copyright © 2012–2022 The Apache Software Foundation. All rights reserved.