xdmp.forestCounts( forest-id as (Number|String)[], [show-elements as String[]], [options as String[]] ) as Sequence
Returns detailed forest statistics for a given forest
as a Sequence of ObjectNodes.
This built-in may require significantly more processing
time than
xdmp.forestStatus
.
http://marklogic.com/xdmp/privileges/counts
The structure of the data returned is as follows:
forestId
forestName
currentTime
error
rebalancerError
standsCounts
This is an object with the following properties:
standCounts
This is an object with the following properties:
standId
path
activeFragmentCount
nascentFragmentCount
deletedFragmentCount
documentCount
directoryCount
allQueryRolesetsFragmentCount
This is an object with the following properties:
queryRolesetsFragmentCount
This is an object with the following properties:
queryRolesetsId
fragmentCount
reindexRefragmentFragmentCount
reindexRefragmentRate
forcedReindexFragmentCount
reindexFragmentCount
reindexPreviousVersionsCount
reindexStemmedSearchesCount
reindexWordSearchesCount
reindexOneCharacterSearchesCount
reindexTwoCharacterSearchesCount
reindexThreeCharacterSearchesCount
reindexFastPhraseSearchesCount
reindexFastCaseSensitiveSearchesCount
reindexFastElementWordSearchesCount
reindexFastElementPhraseSearchesCount
reindexFastElementCharacterSearchesCount
reindexFastElementTrailingWildcardSearchesCount
reindexWordPositionsCount
reindexScaledLogTfNormalizationCount
reindexUnscaledLogTfNormalizationCount
reindexElementWordPositionsCount
reindexElementValuePositionsCount
reindexAttributeValuePositionsCount
reindexFieldValueSearchesCount
reindexFieldValuePositionsCount
reindexThreeCharacterWordPositionsCount
reindexTripleIndexCount
reindexTriplePositionsCount
reindexTrailingWildcardSearchesCount
reindexTrailingWildcardWordPositionsCount
reindexFastDiacriticSensitiveSearchesCount
reindexWordLexiconCount
reindexBinaryThresholdCount
reindexDeletedStemmedSearchesCount
reindexDeletedWordSearchesCount
reindexDeletedOneCharacterSearchesCount
reindexDeletedTwoCharacterSearchesCount
reindexDeletedThreeCharacterSearchesCount
reindexDeletedFastPhraseSearchesCount
reindexDeletedFastCaseSensitiveSearchesCount
reindexDeletedFastElementWordSearchesCount
reindexDeletedFastElementPhraseSearchesCount
reindexDeletedFastElementCharacterSearchesCount
reindexDeletedFastElementTrailingWildcardSearchesCount
reindexDeletedWordPositionsCount
reindexDeletedElementWordPositionsCount
reindexDeletedElementValuePositionsCount
reindexDeletedFieldValueSearchesCount
reindexDeletedFieldValuePositionsCount
reindexDeletedAttributeValuePositionsCount
reindexDeletedThreeCharacterWordPositionsCount
reindexDeletedTripleIndexCount
reindexDeletedTriplePositionsCount
reindexDeletedTrailingWildcardSearchesCount
reindexDeletedTrailingWildcardWordPositionsCount
reindexDeletedFastDiacriticSensitiveSearchesCount
reindexUriLexiconCount
reindexDeletedUriLexiconCount
reindexCollectionLexiconCount
reindexDeletedCollectionLexiconCount
reindexElementWordQueryThroughs
This is an object with the following properties:
reindexElementWordQueryThrough
This is an object with the following properties:
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexPhraseThroughs
This is an object with the following properties:
reindexPhraseThrough
This is an object with the following properties:
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexPhraseArounds
This is an object with the following properties:
reindexPhraseAround
This is an object with the following properties:
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexRangeElementIndexes
This is an object with the following properties:
reindexRangeElementIndex
This is an object with the following properties:
namespaceUri
localname
scalarType
reindexFragmentCount
fragmentCount
reindexRangeFieldIndexes
This is an object with the following properties:
reindexRangeFieldIndex
This is an object with the following properties:
fieldName
scalarType
reindexFragmentCount
fragmentCount
reindexRangePathIndexes
This is an object with the following properties:
reindexRangePathIndex
This is an object with the following properties:
pathExpression
scalarType
reindexFragmentCount
fragmentCount
reindexRangeElementAttributeIndexes
This is an object with the following properties:
reindexRangeElementAttributeIndex
This is an object with the following properties:
parentNamespaceUri
parentLocalname
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexDeletedRangeIndexes
This is an object with the following properties:
fragmentCount
reindexElementWordLexicons
This is an object with the following properties:
reindexElementWordLexicon
This is an object with the following properties:
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexElementAttributeWordLexicons
This is an object with the following properties:
reindexElementAttributeWordLexicon
This is an object with the following properties:
parentNamespaceUri
parentLocalname
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexAllDeletedWordLexicons
This is an object with the following properties:
fragmentCount
reindexGeospatialElementIndexes
This is an object with the following properties:
reindexGeospatialElementIndex
This is an object with the following properties:
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexGeospatialElementChildIndexes
This is an object with the following properties:
reindexGeospatialElementChildIndex
This is an object with the following properties:
parentNamespaceUri
parentLocalname
namespaceUri
localname
reindexFragmentCount
fragmentCount
reindexGeospatialElementPairIndexes
This is an object with the following properties:
reindexGeospatialElementPairIndex
This is an object with the following properties:
parentNamespaceUri
parentLocalname
latitudeNamespaceUri
latitudeLocalname
longitudeNamespaceUri
longitudeLocalname
reindexFragmentCount
fragmentCount
reindexGeospatialElementAttributePairIndexes
This is an object with the following properties:
reindexGeospatialElementAttributePairIndex
This is an object with the following properties:
parentNamespaceUri
parentLocalname
latitudeNamespaceUri
latitudeLocalname
longitudeNamespaceUri
longitudeLocalname
reindexFragmentCount
fragmentCount
reindexGeospatialRegionIndexes
This is an object with the following properties:
reindexGeospatialRegionIndex
This is an object with the following properties:
pathExpression
coordinateSystem
reindexFragmentCount
fragmentCount
reindexDeletedGeospatialRegionIndexes
This is an object with the following properties:
fragmentCount
reindexProtectedPaths
This is an object with the following properties:
reindexProtectedPath
This is an object with the following properties:
pathExpression
reindexFragmentCount
fragmentCount
reindexDeletedProtectedPaths
This is an object with the following properties:
fragmentCount
reindexTdeTemplates
This is an object with the following properties:
reindexTdeTemplate
This is an object with the following properties:
tdeTemplate
reindexFragmentCount
fragmentCount
reindexDeletedTdeTemplates
This is an object with the following properties:
fragmentCount
refragmentDocumentCount
refragmentFragmentRoots
This is an object with the following properties:
refragmentFragmentParent
This is an object with the following properties:
namespaceUri
localname
refragmentDocumentCount
documentCount
refragmentFragmentParents
This is an object with the following properties:
refragmentFragmentParent
This is an object with the following properties:
namespaceUri
localname
refragmentDocumentCount
documentCount
refragmentNewFields
This is an object with the following properties:
refragmentNewField
This is an object with the following properties:
fieldName
refragmentDocumentCount
documentCount
refragmentModifiedFields
This is an object with the following properties:
refragmentModifiedField
This is an object with the following properties:
fieldName
refragmentDocumentCount
documentCount
refragmentRemovedConfigurations
This is an object with the following properties:
refragmentDocumentCount
reindexReverseSearchesFragmentCount
rebalanceFragmentCounts
This is an object with the following properties:
rebalanceFragmentCount
This is an object with the following properties:
rebalanceDestination
fragmentCount
rebalanceRate
xdmp.forestCounts(xdmp.forest("Documents")); => { "forestId": "18080252238750949856", "forestName": "Documents", "currentTime": "2015-01-09T11:08:36.008846-08:00", "standsCounts": [ { "standId": "10599000637920689925", "path": "/var/opt/MarkLogic/Forests/Documents/00000026", "activeFragmentCount": 32, "nascentFragmentCount": 0, "deletedFragmentCount": 4 } ], "documentCount": 16, "directoryCount": 0 }
// only calculate the document count xdmp.forestCounts(xdmp.forest("Documents"), ["document-count"]); => { "forestId": "18080252238750949856", "forestName": "Documents", "currentTime": "2015-01-09T11:13:35.642748-08:00", "documentCount": 16 }
// force everything to be calculated xdmp.forestCounts(xdmp.forest("Documents"), "*"); => the full output of xdmp:forest-counts { "forestId": "18080252238750949856", "forestName": "Documents", "currentTime": "2015-01-09T11:14:19.665315-08:00", "standsCounts": [ { "standId": "10599000637920689925", "path": "/var/opt/MarkLogic/Forests/Documents/00000026", "activeFragmentCount": 32, "nascentFragmentCount": 0, "deletedFragmentCount": 4 } ], "documentCount": 16, "directoryCount": 0, ...... ..... all of the other reindex counts ...... }
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.