Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/_docs/monitoring-metrics/custom-metrics.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ link:monitoring-metrics/new-metrics-system[Metric System].
Custom Metrics are local and are bound only to the local node.
====

== Custom metric creation.
== Custom Metric Creation

To register a custom metric, you need to add a new link:monitoring-metrics/new-metrics-system#registry[registry] first.
After that, metrics can be added to this registry.

=== Custom metric registry.
=== Custom Metric Registry

You can create custom metric registries via the `IgniteMetrics` interface which is obtained by `Ignite.metrics()`.

Expand All @@ -40,7 +40,7 @@ You can create custom metric registries via the `IgniteMetrics` interface which
* `void remove(String registryName)` removes the entire custom metric registry.


=== Custom metric creation.
=== Adding a Metric to a Registry

To register a new custom metric, use the `MetricRegistry` interface which is obtained by `IgniteMetrics.getOrCreate(...)`.

Expand All @@ -51,7 +51,7 @@ To register a new custom metric, use the `MetricRegistry` interface which is obt
* `void remove(String name);` removes a metric.


== Naming convention.
== Naming Convention
Names of the custom metrics (and its registries) are similar to the names of internal metrics. The name can have dot-separated
parts like 'process.status.suspended'.

Expand Down
21 changes: 14 additions & 7 deletions docs/_docs/monitoring-metrics/new-metrics-system.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
= Metrics System

:javaFile: {javaCodeDir}/ConfiguringMetrics.java
:table_opts: cols="2,1,4,1",opts="header"

== Overview

Expand Down Expand Up @@ -228,9 +229,10 @@ Configuration parameters:

== Histograms

The metrics that represent histograms are available in the JMX exporter only.
Histogram metrics are exported as a set of values where each value corresponds to a specific bucket and is available through a separate JMX bean attribute.
The attribute names of a histogram metric have the following format:
Histogram metrics are available through every exporter, but the format differs.

The JMX exporter, the OpenCensus exporter, and the `control.sh --metric` command expose each bucket as a separate value.
The names of the buckets have the following format:

```
{metric_name}_{low_bound}_{high_bound}
Expand All @@ -243,13 +245,18 @@ where
* `{high_bound}` - end of the bound. `inf` for the last bound.


Example of the metric names if the bounds are [10,100]:
Example of the bucket names if the bounds are [10,100]:

* `histogram_0_10` - less than 10.
* `histogram_10_100` - between 10 and 100.
* `histogram_100_inf` - more than 100.

== Common monitoring tasks
The `SYS.METRICS` system view and the log exporter report the whole histogram as a single value: an array of bucket
counters, for example `[3, 15, 2]`. Bucket bounds are not exposed there yet, so to see them read the same metric through
JMX, the OpenCensus exporter, or `control.sh --metric`, where every bucket name carries its bounds.


== Common Monitoring Tasks
=== Monitoring the Amount of Data

If you do not use link:persistence/native-persistence[Native persistence] (i.e., all your data is kept in memory), you would want to monitor RAM usage.
Expand Down Expand Up @@ -317,7 +324,7 @@ To monitor the size of the persistent storage on disk, use the following metrics

===== Data Region Size

For each configured data region, Metrics collection for data regions are disabled by default. You can link:monitoring-metrics/configuring-metrics#enabling-data-region-metrics[enable it in the data region configuration.
Metrics collection for data regions is disabled by default. You can link:monitoring-metrics/configuring-metrics#enabling-data-region-metrics[enable it in the data region configuration].

The size of the data region on a node comprises the size of all partitions (including backup partitions) that this node owns for all caches in that data region.

Expand Down Expand Up @@ -381,7 +388,7 @@ Topology refers to the set of nodes in a cluster. There are a number of metrics
| Attribute | Type | Description | Scope
| TotalServerNodes| long |The number of server nodes in the cluster.| Global
| TotalClientNodes| long |The number of client nodes in the cluster. | Global
| TotalBaselineNodes | long | The number of nodes that are registered in the link:clustering/baseline-topology[baseline topology]. When a node goes down, it remains registered in the baseline topology and you need to remote it manually. | Global
| TotalBaselineNodes | long | The number of nodes that are registered in the link:clustering/baseline-topology[baseline topology]. When a node goes down, it remains registered in the baseline topology and you need to remove it manually. | Global
| ActiveBaselineNodes | long | The number of nodes that are currently active in the baseline topology. | Global
|===

Expand Down
42 changes: 21 additions & 21 deletions docs/_docs/monitoring-metrics/new-metrics.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ Register name: `cache.{cache_name}.{near}`
|ConflictResolverMergedCount|long|Conflict resolver merged entries count.
|EntryProcessorHits | long|The total number of invocations on keys, which exist in cache.
|EntryProcessorInvokeTimeNanos | long | The total time of cache invocations for which this node is the initiator, in nanoseconds.
|EntryProcessorMaxInvocationTime |long | So far, the maximum time to execute cache invokes for which this node is the initiator.
|EntryProcessorMinInvocationTime |long | So far, the minimum time to execute cache invokes for which this node is the initiator.
|EntryProcessorMaxInvocationTime |long | So far, the maximum time to execute cache invokes for which this node is the initiator, in nanoseconds.
|EntryProcessorMinInvocationTime |long | So far, the minimum time to execute cache invokes for which this node is the initiator, in nanoseconds.
|EntryProcessorMisses |long|The total number of invocations on keys, which don't exist in cache.
|EntryProcessorPuts |long|The total number of cache invocations, caused update.
|EntryProcessorReadOnlyInvocations |long|The total number of cache invocations, caused no updates.
Expand Down Expand Up @@ -104,17 +104,17 @@ Register name: `cache.{cache_name}.{near}`
|QueryCompleted |long|Count of completed queries.
|QueryExecuted |long|Count of executed queries.
|QueryFailed |long|Count of failed queries.
|QueryMaximumTime |long| Maximum query execution time.
|QueryMinimalTime |long| Minimum query execution time.
|QuerySumTime |long| Query summary time.
|QueryMaximumTime |long| Maximum query execution time, in milliseconds.
|QueryMinimalTime |long| Minimum query execution time, in milliseconds.
|QuerySumTime |long| Query summary time, in milliseconds.
|RebalanceClearingPartitionsLeft |long| Number of partitions need to be cleared before actual rebalance start.
|RebalanceStartTime |long| Rebalance start time.
|RebalancedKeys |long| Number of already rebalanced keys.
|RebalancingBytesRate|long|Estimated rebalancing speed in bytes.
|RebalancingKeysRate |long|Estimated rebalancing speed in keys.
|RemoveAllConflictTime | histogram | RemoveAllConflict time for which this node is the initiator, in nanoseconds.
|RemoveAllTime | histogram | RemoveAll time for which this node is the initiator, in nanoseconds.
|RemoveTime | histogram | Remove time for which this node is the initiator. in nanoseconds.
|RemoveTime | histogram | Remove time for which this node is the initiator, in nanoseconds.
|RemoveTimeTotal | long | The total time of cache removal, in nanoseconds.
|RollbackTime|histogram| Rollback time in nanoseconds.
|RollbackTimeTotal |long|The total time of rollback, in nanoseconds.
Expand Down Expand Up @@ -164,11 +164,11 @@ Register name: `tx`
|OwnerTransactionsNumber |long| The number of active transactions for which this node is the initiator.
|TransactionsHoldingLockNumber | long| The number of active transactions holding at least one key lock.
|LastCommitTime |long| Last commit time.
|nodeSystemTimeHistogram| histogram| Transactions system times on node represented as histogram.
|nodeUserTimeHistogram| histogram| Transactions user times on node represented as histogram.
|nodeSystemTimeHistogram| histogram| Transactions system times on node represented as histogram, in milliseconds.
|nodeUserTimeHistogram| histogram| Transactions user times on node represented as histogram, in milliseconds.
|LastRollbackTime| long| Last rollback time.
|totalNodeSystemTime |long| Total transactions system time on node.
|totalNodeUserTime |long| Total transactions user time on node.
|totalNodeSystemTime |long| Total transactions system time on node, in milliseconds.
|totalNodeUserTime |long| Total transactions user time on node, in milliseconds.
|txCommits |integer| Number of transaction commits.
|txRollbacks |integer| Number of transaction rollbacks.
|txDeadlocks |integer| Number of transaction deadlocks.
Expand Down Expand Up @@ -200,12 +200,12 @@ Register name: `compute.jobs`
|Name| Type| Description
|compute.jobs.Active |long| Number of active jobs currently executing.
|compute.jobs.Canceled |long| Number of cancelled jobs that are still running.
|compute.jobs.ExecutionTime |long| Total execution time of jobs.
|compute.jobs.ExecutionTime |long| Total execution time of jobs, in milliseconds.
|compute.jobs.Finished |long| Number of finished jobs.
|compute.jobs.Rejected |long| Number of jobs rejected after more recent collision resolution operation.
|compute.jobs.Started |long| Number of started jobs.
|compute.jobs.Waiting |long| Number of currently queued jobs waiting to be executed.
|compute.jobs.WaitingTime |long| Total time jobs spent on waiting queue.
|compute.jobs.WaitingTime |long| Total time jobs spent on waiting queue, in milliseconds.
|===

== Thread Pools
Expand Down Expand Up @@ -251,7 +251,7 @@ Register name: `io.statistics.cacheGroups.{group_name}`
|===


== Sorted Indexes I/O statistics
== Sorted Indexes I/O Statistics

Register name: `io.statistics.sortedIndexes.{cache_name}.{index_name}`

Expand All @@ -267,7 +267,7 @@ Register name: `io.statistics.sortedIndexes.{cache_name}.{index_name}`
|startTime| long| Statistics collection start time
|===

== Sorted Indexes operations
== Sorted Indexes Operations

Contains metrics about low-level operations (such as `Insert`, `Search`, etc.) on pages of sorted secondary indexes.

Expand All @@ -281,7 +281,7 @@ Register name: `index.{schema_name}.{table_name}.{index_name}`
|===


== Hash Indexes I/O statistics
== Hash Indexes I/O Statistics

Register name: `io.statistics.hashIndexes.{cache_name}.{index_name}`

Expand Down Expand Up @@ -398,7 +398,7 @@ Register name: `io.dataregion.{data_region_name}`
|EmptyDataPages| long| Calculates empty data pages count for region. It counts only totally free pages that can be reused (e. g. pages that are contained in reuse bucket of free list).
|EvictionRate| hitrate| Eviction rate (pages per second).
|EvictionsStarted | boolean | True if page eviction was triggered due to data region memory pressure.
|LargeEntriesPagesCount| long| Count of pages that fully ocupied by large entries that go beyond page size
|LargeEntriesPagesCount| long| Count of pages that fully occupied by large entries that go beyond page size
|OffHeapSize| long| Offheap size in bytes.
|OffheapUsedSize| long| Offheap used size in bytes.
|PagesFillFactor| double| The average amount of data in non-empty pages as a ratio of the page size.
Expand Down Expand Up @@ -437,7 +437,7 @@ Register name: `io.datastorage`
|CheckpointPagesWriteHistogram| histogram | Histogram of checkpoint pages write duration in milliseconds.
|CheckpointSplitAndSortPagesHistogram| histogram | Histogram of splitting and sorting checkpoint pages duration in milliseconds.
|CheckpointTotalTime| long | Total duration of checkpoint
|CheckpointWalRecordFsyncHistogram| histogram | Histogram of the WAL fsync after logging ChTotalNodeseckpointRecord on begin of checkpoint duration in milliseconds.
|CheckpointWalRecordFsyncHistogram| histogram | Histogram of the WAL fsync after logging CheckpointRecord on begin of checkpoint duration in milliseconds.
|CheckpointWriteEntryHistogram| histogram | Histogram of entry buffer writing to file duration in milliseconds.
|LastArchivedSegment | long | Last archived segment index.
|LastCheckpointBeforeLockDuration| long | Duration of the checkpoint action before taken write lock in milliseconds.
Expand Down Expand Up @@ -485,7 +485,7 @@ Register name: `cluster`
|TotalServerNodes| integer | Server nodes count.
|===

== Cache processor
== Cache Processor

Cache processor metrics.

Expand All @@ -499,7 +499,7 @@ Register name: `cache`
|DataVersionClusterId| integer | Data version cluster id.
|===

== SQL parser metrics
== SQL Parser Metrics

Register name: `sql.parser.cache`

Expand All @@ -510,14 +510,14 @@ Register name: `sql.parser.cache`
|misses| long | The number of SQL queries that were parsed and planned.
|===

== SQL executor metrics
== SQL Executor Metrics

Register name: `sql.queries.user`

[cols="2,1,3",opts="header"]
|===
|Name| Type| Description
|success| long | The number of succesfully executed SQL queries.
|success| long | The number of successfully executed SQL queries.
|failed| long | The number of failed SQL queries (including canceled).
|canceled| long | The number of canceled SQL queries.
|===
2 changes: 1 addition & 1 deletion docs/_docs/monitoring-metrics/system-views.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -249,11 +249,11 @@ methods. The parameter is empty, if you use `IgniteCompute` APIs that don't targ

[{table_opts}]
|===
| Column | Type | Description
|AFFINITY_KEY | string | Affinity key value for service
|CACHE_NAME | string | Cache name
|MAX_PER_NODE_COUNT | int | Maximum count of services instances per node
|NAME | string | Service name
|NAME | TYPE | DESCRIPTION
|NODE_FILTER | string | String representation of node filter
|ORIGIN_NODE_ID | UUID | Originating node ID
|SERVICE_CLASS | string | Service class name
Expand Down
2 changes: 1 addition & 1 deletion docs/_docs/perf-and-troubleshooting/sql-tuning.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ Note that you will only have to set the inline size for the index on `stringFiel

Refer to the link:SQL/indexes#configuring-index-inline-size[Configuring Index Inline Size] section for the information on how to change the inline size.

You can check the inline size of an existing index in the link:monitoring-metrics/system-views#indexes-view[INDEXES] system view.
You can check the inline size of an existing index in the link:monitoring-metrics/system-views#indexes[INDEXES] system view.

[WARNING]
====
Expand Down
4 changes: 2 additions & 2 deletions docs/_docs/persistence/change-data-capture.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ CDC is configured in the same way as the Ignite node - via the spring XML file:
| `checkFrequency` | Amount of time application sleeps between subsequent checks when no new files available. | 1000 milliseconds.
| `keepBinary` | Flag to specify if key and value of changed entries should be provided in link:key-value-api/binary-objects[binary format]. | `true`
| `consumer` | Implementation of `org.apache.ignite.cdc.CdcConsumer` that consumes entries changes. | null
| `metricExporterSpi` | Array of SPI's to export CDC metrics. See link:monitoring-metrics/new-metrics-system#_metric_exporters[metrics] documentation, also. | null
| `metricExporterSpi` | Array of SPI's to export CDC metrics. See link:monitoring-metrics/new-metrics-system#metric-exporters[metrics] documentation, also. | null
|===

=== Distributed properties
Expand All @@ -93,7 +93,7 @@ Below is a single change of the data reflected by `CdcEvent`.
|Name |Description
| `key()` | Key for the changed entry.
| `value()` | Value for the changed entry. This method will return `null` if the event reflects removal.
| `cacheId()` | ID of the cache where the change happens. The value is equal to the `CACHE_ID` from link:monitoring-metrics/system-views#_CACHES[`SYS.CACHES`].
| `cacheId()` | ID of the cache where the change happens. The value is equal to the `CACHE_ID` from link:monitoring-metrics/system-views#caches[`SYS.CACHES`].
| `partition()` | Partition of the changed entry.
| `primary()` | Flag to distinguish if operation happens on the primary or a backup node.
| `version()` | `Comparable` version of the changed entry. Internally, Ignite maintains ordered versions of each entry so any changes of the same entry can be sorted.
Expand Down
6 changes: 3 additions & 3 deletions docs/_docs/tools/control-script.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -1053,9 +1053,9 @@ control.bat --metric sys

Example of the metric output:
[source, text]
control.sh --metric sysCurrentThreadCpuTime
control.sh --metric sys.CurrentThreadCpuTime
Command [METRIC] started
Arguments: --metric sys
Arguments: --metric sys.CurrentThreadCpuTime
--------------------------------------------------------------------------------
metric value
sys.CurrentThreadCpuTime 17270000
Expand All @@ -1066,7 +1066,7 @@ Example of the metric registry output:
[source, text]
control.sh --metric io.dataregion.default
Command [METRIC] started
Arguments: --metric sys
Arguments: --metric io.dataregion.default
--------------------------------------------------------------------------------
metric value
io.dataregion.default.TotalAllocatedSize 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,10 +305,10 @@ public CacheMetricsImpl(GridCacheContext<?, ?> cctx, boolean isNear) {
"The total time of cache invocations for which this node is the initiator, in nanoseconds.");

entryProcessorMinInvocationTime = mreg.longMetric("EntryProcessorMinInvocationTime",
"So far, the minimum time to execute cache invokes for which this node is the initiator.");
"So far, the minimum time to execute cache invokes for which this node is the initiator, in nanoseconds.");

entryProcessorMaxInvocationTime = mreg.longMetric("EntryProcessorMaxInvocationTime",
"So far, the maximum time to execute cache invokes for which this node is the initiator.");
"So far, the maximum time to execute cache invokes for which this node is the initiator, in nanoseconds.");

entryProcessorHits = mreg.longMetric("EntryProcessorHits",
"The total number of invocations on keys, which exist in cache.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,19 +110,19 @@ public TransactionMetricsAdapter(GridKernalContext ctx) {
txDeadlocks = mreg.intMetric("txDeadlocks", "Number of transaction deadlocks.");
commitTime = mreg.longMetric("commitTime", "Last commit time.");
rollbackTime = mreg.longMetric("rollbackTime", "Last rollback time.");
totalTxSystemTime = mreg.longAdderMetric(METRIC_TOTAL_SYSTEM_TIME, "Total transactions system time on node.");
totalTxUserTime = mreg.longAdderMetric(METRIC_TOTAL_USER_TIME, "Total transactions user time on node.");
totalTxSystemTime = mreg.longAdderMetric(METRIC_TOTAL_SYSTEM_TIME, "Total transactions system time on node, in milliseconds.");
totalTxUserTime = mreg.longAdderMetric(METRIC_TOTAL_USER_TIME, "Total transactions user time on node, in milliseconds.");

txSystemTimeHistogram = mreg.histogram(
METRIC_SYSTEM_TIME_HISTOGRAM,
METRIC_TIME_BUCKETS,
"Transactions system times on node represented as histogram."
"Transactions system times on node represented as histogram, in milliseconds."
);

txUserTimeHistogram = mreg.histogram(
METRIC_USER_TIME_HISTOGRAM,
METRIC_TIME_BUCKETS,
"Transactions user times on node represented as histogram."
"Transactions user times on node represented as histogram, in milliseconds."
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -376,9 +376,9 @@ public GridJobProcessor(GridKernalContext ctx) {

finishedJobsMetric = mreg.longMetric(FINISHED, "Number of finished jobs.");

totalExecutionTimeMetric = mreg.longMetric(EXECUTION_TIME, "Total execution time of jobs.");
totalExecutionTimeMetric = mreg.longMetric(EXECUTION_TIME, "Total execution time of jobs, in milliseconds.");

totalWaitTimeMetric = mreg.longMetric(WAITING_TIME, "Total time jobs spent on waiting queue.");
totalWaitTimeMetric = mreg.longMetric(WAITING_TIME, "Total time jobs spent on waiting queue, in milliseconds.");

ctx.systemView().registerInnerCollectionView(JOBS_VIEW, JOBS_VIEW_DESC,
new ComputeJobViewWalker(),
Expand Down
Loading