diff --git a/aerospike-mixin/alerts/alerts.libsonnet b/aerospike-mixin/alerts.libsonnet similarity index 78% rename from aerospike-mixin/alerts/alerts.libsonnet rename to aerospike-mixin/alerts.libsonnet index 46b09a493..d24ded61a 100644 --- a/aerospike-mixin/alerts/alerts.libsonnet +++ b/aerospike-mixin/alerts.libsonnet @@ -1,14 +1,14 @@ { - prometheusAlerts+:: { - groups+: [ + new(this): { + groups: [ { - name: 'aerospike', + name: 'aerospike.rules', rules: [ { alert: 'AerospikeNodeHighMemoryUsage', expr: ||| 100 - sum without (service) (aerospike_node_stats_system_free_mem_pct) >= %(alertsCriticalNodeHighMemoryUsage)s - ||| % $._config, + ||| % this.config, 'for': '5m', labels: { severity: 'critical', @@ -19,14 +19,14 @@ ( '{{ printf "%%.0f" $value }} percent of system memory used on node {{$labels.instance}} on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsCriticalNodeHighMemoryUsage)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeNamespaceHighDiskUsage', expr: ||| 100 - sum without (service) (aerospike_namespace_device_free_pct) >= %(alertsCriticalNamespaceHighDiskUsage)s - ||| % $._config, + ||| % this.config, 'for': '5m', labels: { severity: 'critical', @@ -37,14 +37,14 @@ ( '{{ printf "%%.0f" $value }} percent of disk space available for namespace {{$labels.ns}} on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsCriticalNamespaceHighDiskUsage)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeUnavailablePartitions', expr: ||| sum without(service) (aerospike_namespace_unavailable_partitions) > %(alertsCriticalUnavailablePartitions)s - ||| % $._config, + ||| % this.config, 'for': '5m', labels: { severity: 'critical', @@ -55,14 +55,14 @@ ( '{{ printf "%%.0f" $value }} unavailable partition(s) in namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsCriticalUnavailablePartitions)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeDeadPartitions', expr: ||| sum without(service) (aerospike_namespace_dead_partitions) > %(alertsCriticalDeadPartitions)s - ||| % $._config, + ||| % this.config, 'for': '5m', labels: { severity: 'critical', @@ -73,14 +73,14 @@ ( '{{ printf "%%.0f" $value }} dead partition(s) in namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsCriticalDeadPartitions)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeNamespaceRejectingWrites', expr: ||| sum without(service) (aerospike_namespace_stop_writes + aerospike_namespace_clock_skew_stop_writes) > %(alertsCriticalSystemRejectingWrites)s - ||| % $._config, + ||| % this.config, 'for': '5m', labels: { severity: 'critical', @@ -90,14 +90,14 @@ description: ( 'Namespace {{$labels.ns}} on node {{$labels.instance}} on cluster {{$labels.aerospike_cluster}} is currently rejecting all client-originated writes.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeHighClientReadErrorRate', expr: ||| - sum without(service) (rate(aerospike_namespace_client_read_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_read_error[5m])) + sum without(service) (rate(aerospike_namespace_client_read_success[5m])), 1)) > %(alertsWarningHighClientReadErrorRate)s - ||| % $._config, + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_success[5m])), 1)) > %(alertsWarningHighClientReadErrorRate)s + ||| % this.config, 'for': '5m', labels: { severity: 'warning', @@ -108,14 +108,14 @@ ( '{{ printf "%%.0f" $value }} percent of client read transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsWarningHighClientReadErrorRate)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeHighClientWriteErrorRate', expr: ||| - sum without(service) (rate(aerospike_namespace_client_write_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_write_error[5m])) + sum without(service) (rate(aerospike_namespace_client_write_success[5m])), 1)) > %(alertsWarningHighClientWriteErrorRate)s - ||| % $._config, + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_success[5m])), 1)) > %(alertsWarningHighClientWriteErrorRate)s + ||| % this.config, 'for': '5m', labels: { severity: 'warning', @@ -126,14 +126,14 @@ ( '{{ printf "%%.0f" $value }} percent of client write transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsWarningHighClientWriteErrorRate)s.' - ) % $._config, + ) % this.config, }, }, { alert: 'AerospikeHighClientUDFErrorRate', expr: ||| - sum without(service) (rate(aerospike_namespace_client_udf_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_udf_error[5m])) + sum without(service) (rate(aerospike_namespace_client_udf_complete[5m])), 1)) > %(alertsWarningHighClientUDFErrorRate)s - ||| % $._config, + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_complete[5m])), 1)) > %(alertsWarningHighClientUDFErrorRate)s + ||| % this.config, 'for': '5m', labels: { severity: 'warning', @@ -144,7 +144,7 @@ ( '{{ printf "%%.0f" $value }} percent of client UDF transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, ' + 'which is above the threshold of %(alertsWarningHighClientUDFErrorRate)s.' - ) % $._config, + ) % this.config, }, }, ], diff --git a/aerospike-mixin/config.libsonnet b/aerospike-mixin/config.libsonnet index 5a8a4f699..15e82c736 100644 --- a/aerospike-mixin/config.libsonnet +++ b/aerospike-mixin/config.libsonnet @@ -1,25 +1,41 @@ { - _config+:: { - enableMultiCluster: false, - aerospikeSelector: if self.enableMultiCluster then 'job=~"$job", cluster=~"$cluster"' else 'job=~"$job"', - multiclusterSelector: 'job=~"$job"', - filterSelector: 'job=~"integrations/aerospike"', + local this = self, + filteringSelector: 'job="integrations/aerospike"', + groupLabels: ['job', 'aerospike_cluster', 'cluster'], + logLabels: ['job', 'cluster', 'instance'], + instanceLabels: ['instance', 'ns'], // ns == namespace - dashboardTags: ['aerospike-mixin'], - dashboardPeriod: 'now-30m', - dashboardTimezone: 'default', - dashboardRefresh: '1m', + dashboardTags: [self.uid], + uid: 'aerospike', + dashboardNamePrefix: 'Aerospike', + dashboardPeriod: 'now-30m', + dashboardTimezone: 'default', + dashboardRefresh: '1m', + metricsSource: [ + 'prometheusAerospike7', // For queries that are required for Aerospike 7.0+ with metric changes + 'prometheus', // For Aerospike < 7.0 + ], - // alerts thresholds - alertsCriticalNodeHighMemoryUsage: 80, // % - alertsCriticalNamespaceHighDiskUsage: 80, // % - alertsCriticalUnavailablePartitions: 0, // count - alertsCriticalDeadPartitions: 0, // count - alertsCriticalSystemRejectingWrites: 0, // count - alertsWarningHighClientReadErrorRate: 25, // % - alertsWarningHighClientWriteErrorRate: 25, // % - alertsWarningHighClientUDFErrorRate: 25, // % + // Logging configuration + enableLokiLogs: true, + extraLogLabels: ['level'], // Required by logs-lib + logsVolumeGroupBy: 'level', + showLogsVolume: true, - enableLokiLogs: true, + // Alerts thresholds + alertsCriticalNodeHighMemoryUsage: 80, // % + alertsCriticalNamespaceHighDiskUsage: 80, // % + alertsCriticalUnavailablePartitions: 0, // count + alertsCriticalDeadPartitions: 0, // count + alertsCriticalSystemRejectingWrites: 0, // count + alertsWarningHighClientReadErrorRate: 25, // % + alertsWarningHighClientWriteErrorRate: 25, // % + alertsWarningHighClientUDFErrorRate: 25, // % + + // Signals configuration + signals+: { + overview: (import './signals/overview.libsonnet')(this), + namespace: (import './signals/namespace.libsonnet')(this), + instance: (import './signals/instance.libsonnet')(this), }, } diff --git a/aerospike-mixin/dashboards.libsonnet b/aerospike-mixin/dashboards.libsonnet new file mode 100644 index 000000000..9dd145b3f --- /dev/null +++ b/aerospike-mixin/dashboards.libsonnet @@ -0,0 +1,135 @@ +local g = import './g.libsonnet'; +local commonlib = import 'common-lib/common/main.libsonnet'; +local logslib = import 'logs-lib/logs/main.libsonnet'; + +{ + local root = self, + new(this):: + local prefix = this.config.dashboardNamePrefix; + local links = this.grafana.links; + local tags = this.config.dashboardTags; + local uid = g.util.string.slugify(this.config.uid); + local vars = this.grafana.variables; + local annotations = this.grafana.annotations; + local refresh = this.config.dashboardRefresh; + local period = this.config.dashboardPeriod; + local timezone = this.config.dashboardTimezone; + { + 'aerospike-overview.json': + g.dashboard.new(prefix + ' overview') + + g.dashboard.withPanels( + g.util.panel.resolveCollapsedFlagOnRows( + g.util.grid.wrapPanels( + [ + this.grafana.rows.clusterOverview, + ] + ) + ) + ) + root.applyCommon( + vars.multiInstance + [ + g.dashboard.variable.custom.new( + 'k', + values=['2', '4', '6', '8', '10'], + ) + g.dashboard.variable.custom.generalOptions.withCurrent('2') + + g.dashboard.variable.custom.generalOptions.withLabel('Top node count') + + g.dashboard.variable.custom.selectionOptions.withMulti(false) + + g.dashboard.variable.custom.selectionOptions.withIncludeAll(false), + ], + uid + '_overview', + tags, + links { aerospikeOverview:: {} }, + annotations, + timezone, + refresh, + period, + ), + + + 'aerospike-instance-overview.json': + g.dashboard.new(prefix + ' instance overview') + + g.dashboard.withPanels( + g.util.panel.resolveCollapsedFlagOnRows( + g.util.grid.wrapPanels( + [ + this.grafana.rows.instanceOverview, + ] + ) + ) + ) + root.applyCommon( + vars.multiInstance, + uid + '_instance_overview', + tags, + links { aerospikeInstanceOverview:: {} }, + annotations, + timezone, + refresh, + period, + ), + + 'aerospike-namespace-overview.json': + g.dashboard.new(prefix + ' namespace overview') + + g.dashboard.withPanels( + g.util.panel.resolveCollapsedFlagOnRows( + g.util.grid.wrapPanels( + [ + this.grafana.rows.namespaceOverview, + ] + ) + ) + ) + root.applyCommon( + vars.multiInstance, + uid + '_namespace_overview', + tags, + links { aerospikeNamespaceOverview:: {} }, + annotations, + timezone, + refresh, + period, + ), + } + + + if this.config.enableLokiLogs then + { + 'aerospike-logs-overview.json': + logslib.new( + prefix + ' logs', + datasourceName=this.grafana.variables.datasources.loki.name, + datasourceRegex=this.grafana.variables.datasources.loki.regex, + filterSelector=this.config.filteringSelector, + labels=this.config.groupLabels + this.config.extraLogLabels, + formatParser=null, + showLogsVolume=this.config.showLogsVolume, + ) + { + dashboards+: + { + logs+: + root.applyCommon(super.logs.templating.list, uid=uid + '-logs', tags=tags, links=links { logs+:: {} }, annotations=annotations, timezone=timezone, refresh=refresh, period=period), + }, + panels+: + { + logs+: + g.panel.logs.options.withEnableLogDetails(true) + + g.panel.logs.options.withShowTime(false) + + g.panel.logs.options.withWrapLogMessage(false), + }, + variables+: { + toArray+: [ + this.grafana.variables.datasources.prometheus { hide: 2 }, + ], + }, + }.dashboards.logs, + } + else {}, + + + applyCommon(vars, uid, tags, links, annotations, timezone, refresh, period): + g.dashboard.withTags(tags) + + g.dashboard.withUid(uid) + + g.dashboard.withLinks(std.objectValues(links)) + + g.dashboard.withTimezone(timezone) + + g.dashboard.withRefresh(refresh) + + g.dashboard.time.withFrom(period) + + g.dashboard.withVariables(vars) + + g.dashboard.withAnnotations(std.objectValues(annotations)), +} diff --git a/aerospike-mixin/dashboards/aerospike-instance-overview.libsonnet b/aerospike-mixin/dashboards/aerospike-instance-overview.libsonnet deleted file mode 100644 index 736f2a099..000000000 --- a/aerospike-mixin/dashboards/aerospike-instance-overview.libsonnet +++ /dev/null @@ -1,973 +0,0 @@ -local g = (import 'grafana-builder/grafana.libsonnet'); -local grafana = (import 'grafonnet/grafana.libsonnet'); -local dashboard = grafana.dashboard; -local template = grafana.template; -local prometheus = grafana.prometheus; - -local dashboardUid = 'aerospike-instance-overview'; - -local promDatasourceName = 'prometheus_datasource'; -local lokiDatasourceName = 'loki_datasource'; - -local promDatasource = { - uid: '${%s}' % promDatasourceName, -}; - -local lokiDatasource = { - uid: '${%s}' % lokiDatasourceName, -}; - -local unavailablePartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster, instance) (aerospike_namespace_unavailable_partitions{' + matcher + ', instance=~"$instance"})', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'bargauge', - title: 'Unavailable partitions', - description: 'Number of unavailable data partitions in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'auto', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', -}; - -local memoryUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - '100 - aerospike_node_stats_system_free_mem_pct{' + matcher + ', instance=~"$instance"}', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Memory usage', - description: 'Memory utilization in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'continuous-BlYlRd', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'scheme', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local deadPartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster, instance) (aerospike_namespace_dead_partitions{' + matcher + ', instance=~"$instance"})', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'bargauge', - title: 'Dead partitions', - description: 'Number of dead data partitions in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'auto', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', -}; - -local diskUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - '100 - sum by(job, aerospike_cluster, instance) (aerospike_namespace_device_free_pct{' + matcher + ', instance=~"$instance"})', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Disk usage', - description: 'Disk utilization in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'continuous-BlYlRd', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'scheme', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local heapMemoryEfficiencyPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'aerospike_node_stats_heap_efficiency_pct{' + matcher + ', instance=~"$instance"}', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Heap memory efficiency', - description: 'Fragmentation rate for the jemalloc heap in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'scheme', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'red', - value: null, - }, - { - color: '#EAB839', - value: 33, - }, - { - color: 'blue', - value: 66, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local connectionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'aerospike_node_stats_client_connections{' + matcher + ', instance=~"$instance"}', - datasource=promDatasource, - legendFormat='{{instance}} - client', - format='time_series', - ), - prometheus.target( - 'aerospike_node_stats_fabric_connections{' + matcher + ', instance=~"$instance"}', - datasource=promDatasource, - legendFormat='{{instance}} - fabric', - format='time_series', - ), - prometheus.target( - 'aerospike_node_stats_heartbeat_connections{' + matcher + ', instance=~"$instance"}', - datasource=promDatasource, - legendFormat='{{instance}} - heartbeat', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Connections', - description: 'Number of active connections to an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 19, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientReadsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_success{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - success', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_error{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_filtered_out{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_timeout{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - timeout', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_not_found{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - not found', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client reads', - description: 'Rate of client read transactions in an Aerospike node organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'rps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientWritesPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_success{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - success', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_error{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_filtered_out{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_timeout{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - timeout', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client writes', - description: 'Rate of client write transactions in an Aerospike node organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'wps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientUDFTransactionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_complete{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - complete', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_error{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_filtered_out{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_timeout{' + matcher + ', instance=~"$instance"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{instance}} - timeout', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client UDF transactions', - description: 'Rate of client UDF transactions in an Aerospike node organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'ops', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local cacheReadUtilizationPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'avg by(job, aerospike_cluster, instance) (aerospike_namespace_cache_read_pct{' + matcher + ', instance=~"$instance"})', - datasource=promDatasource, - legendFormat='{{instance}}', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Cache read utilization', - description: 'Percentage of read transactions that are resolved by a cache hit in an Aerospike node.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local getMatcher(cfg) = '%(aerospikeSelector)s, aerospike_cluster=~"$aerospike_cluster"' % cfg; - -{ - grafanaDashboards+:: { - 'aerospike-instance-overview.json': - dashboard.new( - 'Aerospike instance overview', - time_from='%s' % $._config.dashboardPeriod, - tags=($._config.dashboardTags), - timezone='%s' % $._config.dashboardTimezone, - refresh='%s' % $._config.dashboardRefresh, - description='', - uid=dashboardUid, - ) - .addLink(grafana.link.dashboards( - asDropdown=false, - title='Other Aerospike Dashboards', - includeVars=true, - keepTime=true, - tags=($._config.dashboardTags), - )) - .addTemplates( - std.flattenArrays([ - [ - template.datasource( - promDatasourceName, - 'prometheus', - null, - label='Data source', - refresh='load' - ), - ], - [ - template.new( - 'job', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size,job)', - label='Job', - refresh=2, - includeAll=true, - multi=true, - allValues='.+', - sort=0 - ), - template.new( - 'cluster', - promDatasource, - 'label_values(aerospike_node_stats_heap_efficiency_pct{%(multiclusterSelector)s}, cluster)' % $._config, - label='Cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='.*', - hide=if $._config.enableMultiCluster then '' else 'variable', - sort=0 - ), - template.new( - 'aerospike_cluster', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size{%(aerospikeSelector)s}, aerospike_cluster)' % $._config, - label='Aerospike cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='', - sort=0 - ), - template.new( - 'instance', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size{%(aerospikeSelector)s, aerospike_cluster=~"$aerospike_cluster"}, instance)' % $._config, - label='Instance', - refresh=2, - includeAll=true, - multi=true, - allValues='.+', - sort=0, - ), - ], - ]) - ) - .addPanels( - std.flattenArrays([ - [ - unavailablePartitionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 7, x: 0, y: 0 } }, - memoryUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 17, x: 7, y: 0 } }, - deadPartitionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 7, x: 0, y: 8 } }, - diskUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 17, x: 7, y: 8 } }, - heapMemoryEfficiencyPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 16 } }, - connectionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 16 } }, - clientReadsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 24 } }, - clientWritesPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 24 } }, - clientUDFTransactionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 32 } }, - cacheReadUtilizationPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 32 } }, - ], - [], - ]) - ), - }, -} diff --git a/aerospike-mixin/dashboards/aerospike-logs-overview.libsonnet b/aerospike-mixin/dashboards/aerospike-logs-overview.libsonnet deleted file mode 100644 index bb80f7ca4..000000000 --- a/aerospike-mixin/dashboards/aerospike-logs-overview.libsonnet +++ /dev/null @@ -1,32 +0,0 @@ -local g = import 'github.com/grafana/grafonnet/gen/grafonnet-latest/main.libsonnet'; -local logsDashboard = import 'github.com/grafana/jsonnet-libs/logs-lib/logs/main.libsonnet'; -{ - grafanaDashboards+:: - if $._config.enableLokiLogs then { - local aerospikeLogs = - logsDashboard.new( - 'Aerospike logs', - datasourceName='loki_datasource', - datasourceRegex='', - filterSelector=$._config.filterSelector, - labels=['job', 'aerospike_cluster', 'instance', 'context', 'level'], - formatParser=null, - showLogsVolume=true - ) - { - panels+: - { - logs+: - // Aerospike logs already have timestamp - g.panel.logs.options.withShowTime(false), - }, - dashboards+: - { - logs+: g.dashboard.withLinksMixin($.grafanaDashboards['aerospike-overview.json'].links) - + g.dashboard.withTags($._config.dashboardTags) - + g.dashboard.withRefresh($._config.dashboardRefresh), - }, - }, - 'aerospike-logs.json': aerospikeLogs.dashboards.logs, - } else {}, -} diff --git a/aerospike-mixin/dashboards/aerospike-namespace-overview.libsonnet b/aerospike-mixin/dashboards/aerospike-namespace-overview.libsonnet deleted file mode 100644 index 73e784b0f..000000000 --- a/aerospike-mixin/dashboards/aerospike-namespace-overview.libsonnet +++ /dev/null @@ -1,763 +0,0 @@ -local g = (import 'grafana-builder/grafana.libsonnet'); -local grafana = (import 'grafonnet/grafana.libsonnet'); -local dashboard = grafana.dashboard; -local template = grafana.template; -local prometheus = grafana.prometheus; - -local dashboardUid = 'aerospike-namespace-overview'; - -local promDatasourceName = 'prometheus_datasource'; - -local promDatasource = { - uid: '${%s}' % promDatasourceName, -}; - -local unavailablePartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'aerospike_namespace_unavailable_partitions{' + matcher + ', ns=~"$ns"}', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}}', - ), - ], - type: 'bargauge', - title: 'Unavailable partitions', - description: 'Number of unavailable data partitions in an Aerospike namespace.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'vertical', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', -}; - -local diskUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - '100 - aerospike_namespace_device_free_pct{' + matcher + ', ns=~"$ns"}', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}}', - ), - ], - type: 'timeseries', - title: 'Disk usage', - description: 'Disk utilization in an Aerospike namespace.', - fieldConfig: { - defaults: { - color: { - mode: 'continuous-BlYlRd', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'scheme', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local deadPartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'aerospike_namespace_dead_partitions{' + matcher + ', ns=~"$ns"}', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}}', - ), - ], - type: 'bargauge', - title: 'Dead partitions', - description: 'Number of dead data partitions in an Aerospike namespace.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'auto', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', -}; - -local memoryUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - '100 - aerospike_namespace_memory_free_pct{' + matcher + ', ns=~"$ns"}', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}}', - ), - ], - type: 'timeseries', - title: 'Memory usage', - description: 'Memory utilization in an Aerospike namespace.', - fieldConfig: { - defaults: { - color: { - mode: 'continuous-BlYlRd', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'scheme', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientReadsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_success{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - success', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_error{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - error', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_filtered_out{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - filtered', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_timeout{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - timeout', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_not_found{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - not found', - ), - ], - type: 'timeseries', - title: 'Client reads', - description: 'Rate of client read transactions in an Aerospike namespace organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'rps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientWritesPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_success{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - success', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_error{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - error', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_filtered_out{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - filtered', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_timeout{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - timeout', - ), - ], - type: 'timeseries', - title: 'Client writes', - description: 'Rate of client write transactions in an Aerospike namespace organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'wps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientUDFTransactionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_complete{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - complete', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_error{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - error', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_filtered_out{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - filtered', - ), - prometheus.target( - 'sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_timeout{' + matcher + ', ns=~"$ns"}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}} - timeout', - ), - ], - type: 'timeseries', - title: 'Client UDF transactions', - description: 'Rate of client UDF transactions in an Aerospike namespace organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'ops', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local cacheReadUtilizationPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'aerospike_namespace_cache_read_pct{' + matcher + ', ns=~"$ns"}', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - {{ns}}', - ), - ], - type: 'timeseries', - title: 'Cache read utilization', - description: 'Percentage of read transactions that are resolved by a cache hit in an Aerospike namespace.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'none', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - min: 0, - max: 100, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'percent', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'bottom', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local getMatcher(cfg) = '%(aerospikeSelector)s, aerospike_cluster=~"$aerospike_cluster"' % cfg; - -{ - grafanaDashboards+:: { - 'aerospike-namespace-overview.json': - dashboard.new( - 'Aerospike namespace overview', - time_from='%s' % $._config.dashboardPeriod, - tags=($._config.dashboardTags), - timezone='%s' % $._config.dashboardTimezone, - refresh='%s' % $._config.dashboardRefresh, - description='', - uid=dashboardUid, - ) - .addLink(grafana.link.dashboards( - asDropdown=false, - title='Other Aerospike Dashboards', - includeVars=true, - keepTime=true, - tags=($._config.dashboardTags), - )) - .addTemplates( - [ - template.datasource( - promDatasourceName, - 'prometheus', - null, - label='Data source', - refresh='load' - ), - template.new( - 'job', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size,job)', - label='Job', - refresh=2, - includeAll=true, - multi=true, - allValues='.+', - sort=0 - ), - template.new( - 'cluster', - promDatasource, - 'label_values(aerospike_namespace_dead_partitions{%(multiclusterSelector)s}, cluster)' % $._config, - label='Cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='.*', - hide=if $._config.enableMultiCluster then '' else 'variable', - sort=0 - ), - template.new( - 'aerospike_cluster', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size{%(aerospikeSelector)s}, aerospike_cluster)' % $._config, - label='Aerospike cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='', - sort=0 - ), - template.new( - 'ns', - promDatasource, - 'label_values(aerospike_namespace_xmem_id{%(aerospikeSelector)s}, ns)' % $._config, - label='Namespace', - refresh=2, - includeAll=true, - multi=true, - allValues='', - sort=0 - ), - ] - ) - .addPanels( - [ - unavailablePartitionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 8, x: 0, y: 0 } }, - diskUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 16, x: 8, y: 0 } }, - deadPartitionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 8, x: 0, y: 8 } }, - memoryUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 16, x: 8, y: 8 } }, - clientReadsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 16 } }, - clientWritesPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 16 } }, - clientUDFTransactionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 24 } }, - cacheReadUtilizationPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 24 } }, - ] - ), - }, -} diff --git a/aerospike-mixin/dashboards/aerospike-overview.libsonnet b/aerospike-mixin/dashboards/aerospike-overview.libsonnet deleted file mode 100644 index 78f0593b8..000000000 --- a/aerospike-mixin/dashboards/aerospike-overview.libsonnet +++ /dev/null @@ -1,1269 +0,0 @@ -local g = (import 'grafana-builder/grafana.libsonnet'); -local grafana = (import 'grafonnet/grafana.libsonnet'); -local dashboard = grafana.dashboard; -local template = grafana.template; -local prometheus = grafana.prometheus; - -local dashboardUid = 'aerospike-overview'; - -local promDatasourceName = 'prometheus_datasource'; - -local promDatasource = { - uid: '${%s}' % promDatasourceName, -}; - -local nodesPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster, instance) (aerospike_namespace_ns_cluster_size{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{instance}}', - format='table', - instant=true, - ), - ], - type: 'table', - title: 'Nodes', - description: 'Number of nodes in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - fixedColor: 'green', - mode: 'fixed', - }, - custom: { - align: 'left', - cellOptions: { - type: 'auto', - }, - filterable: false, - inspect: false, - minWidth: 50, - }, - links: [], - mappings: [], - max: 256, - min: 0, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - ], - }, - unit: 'none', - }, - overrides: [ - { - matcher: { - id: 'byName', - options: 'Value', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'Time', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'instance', - }, - properties: [ - { - id: 'custom.filterable', - value: true, - }, - { - id: 'links', - value: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'aerospike_cluster', - }, - properties: [ - { - id: 'displayName', - value: 'Aerospike cluster', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'job', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - ], - }, - links: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - options: { - cellHeight: 'md', - footer: { - countRows: false, - enablePagination: false, - fields: [], - reducer: [ - 'sum', - ], - show: false, - }, - frameIndex: 0, - showHeader: true, - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local namespacesPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster, instance, ns) (aerospike_namespace_ns_cluster_size{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{ns}}', - format='table', - instant=true - ), - ], - type: 'table', - title: 'Namespaces', - description: 'Number of namespaces in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - fixedColor: 'green', - mode: 'fixed', - }, - custom: { - align: 'left', - cellOptions: { - type: 'auto', - }, - inspect: false, - }, - links: [], - mappings: [], - max: 32, - min: 0, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - ], - }, - unit: 'none', - }, - overrides: [ - { - matcher: { - id: 'byName', - options: 'Value', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'Time', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'instance', - }, - properties: [ - { - id: 'custom.filterable', - value: true, - }, - { - id: 'links', - value: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'aerospike_cluster', - }, - properties: [ - { - id: 'displayName', - value: 'Aerospike cluster', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'ns', - }, - properties: [ - { - id: 'displayName', - value: 'namespace', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'job', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - ], - }, - links: [ - { - title: 'Namespace overview', - url: '/d/aerospike-namespace-overview', - }, - ], - options: { - cellHeight: 'md', - footer: { - countRows: false, - fields: '', - reducer: [ - 'sum', - ], - show: false, - }, - showHeader: true, - sortBy: [], - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local unavailablePartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster) (aerospike_namespace_unavailable_partitions{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}}', - format='time_series', - ), - ], - type: 'bargauge', - title: 'Unavailable partitions', - description: 'Number of unavailable data partitions in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - decimals: 0, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'auto', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local deadPartitionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(job, aerospike_cluster) (aerospike_namespace_dead_partitions{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}}', - format='time_series', - ), - ], - type: 'bargauge', - title: 'Dead partitions', - description: 'Number of dead data partitions in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - mode: 'thresholds', - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 1, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - displayMode: 'gradient', - minVizHeight: 10, - minVizWidth: 0, - orientation: 'auto', - reduceOptions: { - calcs: [ - 'lastNotNull', - ], - fields: '', - values: false, - }, - showUnfilled: true, - text: { - valueSize: 100, - }, - valueMode: 'color', - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local topNodesByMemoryUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'topk($k, 100 - sum by(job, aerospike_cluster, instance) (avg_over_time(aerospike_node_stats_system_free_mem_pct{' + matcher + '}[$__interval])))', - datasource=promDatasource, - legendFormat='{{instance}}', - format='table', - instant=true - ), - ], - type: 'table', - title: 'Top nodes by memory usage', - description: 'Memory utilization for the top k nodes in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - fixedColor: 'green', - mode: 'fixed', - }, - custom: { - align: 'left', - cellOptions: { - type: 'auto', - }, - inspect: false, - }, - mappings: [], - max: 100, - min: 0, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - ], - }, - unit: 'percent', - }, - overrides: [ - { - matcher: { - id: 'byName', - options: 'Time', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'instance', - }, - properties: [ - { - id: 'custom.filterable', - value: true, - }, - { - id: 'links', - value: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'aerospike_cluster', - }, - properties: [ - { - id: 'displayName', - value: 'Aerospike cluster', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'Value', - }, - properties: [ - { - id: 'displayName', - value: 'usage', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'job', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - ], - }, - links: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - options: { - cellHeight: 'md', - footer: { - countRows: false, - fields: '', - reducer: [ - 'sum', - ], - show: false, - }, - showHeader: true, - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local topNodesByDiskUsagePanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'topk($k, 100 - sum by(job, aerospike_cluster, instance) (avg_over_time(aerospike_namespace_device_free_pct{' + matcher + '}[$__interval])))', - datasource=promDatasource, - legendFormat='{{instance}}', - format='table', - instant=true - ), - ], - type: 'table', - title: 'Top nodes by disk usage', - description: 'Disk utilization for the top k nodes in an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - fixedColor: 'green', - mode: 'fixed', - }, - custom: { - align: 'left', - cellOptions: { - type: 'auto', - }, - filterable: false, - inspect: false, - }, - mappings: [], - max: 100, - min: 0, - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - ], - }, - unit: 'percent', - }, - overrides: [ - { - matcher: { - id: 'byName', - options: 'Time', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'instance', - }, - properties: [ - { - id: 'custom.filterable', - value: true, - }, - { - id: 'links', - value: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'aerospike_cluster', - }, - properties: [ - { - id: 'displayName', - value: 'Aerospike cluster', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'Value', - }, - properties: [ - { - id: 'displayName', - value: 'usage', - }, - ], - }, - { - matcher: { - id: 'byName', - options: 'job', - }, - properties: [ - { - id: 'custom.hidden', - value: true, - }, - ], - }, - ], - }, - links: [ - { - title: 'Instance overview', - url: '/d/aerospike-instance-overview', - }, - ], - options: { - cellHeight: 'md', - footer: { - countRows: false, - fields: '', - reducer: [ - 'sum', - ], - show: false, - }, - showHeader: true, - }, - pluginVersion: '10.2.0-59542pre', - transformations: [ - { - id: 'sortBy', - options: { - fields: {}, - sort: [ - { - desc: true, - field: 'Time', - }, - ], - }, - }, - ], -}; - -local clientReadsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_success{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - success', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_error{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_filtered_out{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_timeout{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - timeout', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_not_found{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - not found', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client reads', - description: 'Rate of client read transactions in an Aerospike cluster organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'rps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientWritesPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_success{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - success', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_error{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_filtered_out{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_timeout{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - timeout', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client writes', - description: 'Rate of client write transactions in an Aerospike cluster organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'wps', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local clientUDFTransactionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_complete{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - complete', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_error{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - error', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_filtered_out{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - filtered', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_timeout{' + matcher + '}[$__rate_interval]))', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - timeout', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Client UDF transactions', - description: 'Rate of client UDF transactions in an Aerospike cluster organized by result.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'ops', - }, - overrides: [], - }, - options: { - legend: { - calcs: [ - 'min', - 'mean', - 'max', - ], - displayMode: 'table', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local connectionsPanel(matcher) = { - datasource: promDatasource, - targets: [ - prometheus.target( - 'sum by(aerospike_cluster, job) (aerospike_node_stats_client_connections{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - client', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (aerospike_node_stats_fabric_connections{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - fabric', - format='time_series', - ), - prometheus.target( - 'sum by(aerospike_cluster, job) (aerospike_node_stats_heartbeat_connections{' + matcher + '})', - datasource=promDatasource, - legendFormat='{{aerospike_cluster}} - heartbeat', - format='time_series', - ), - ], - type: 'timeseries', - title: 'Connections', - description: 'Number of active connections to an Aerospike cluster.', - fieldConfig: { - defaults: { - color: { - mode: 'palette-classic', - }, - custom: { - axisCenteredZero: false, - axisColorMode: 'text', - axisLabel: '', - axisPlacement: 'auto', - barAlignment: 0, - drawStyle: 'line', - fillOpacity: 20, - gradientMode: 'none', - hideFrom: { - legend: false, - tooltip: false, - viz: false, - }, - insertNulls: false, - lineInterpolation: 'smooth', - lineWidth: 2, - pointSize: 5, - scaleDistribution: { - type: 'linear', - }, - showPoints: 'never', - spanNulls: false, - stacking: { - group: 'A', - mode: 'normal', - }, - thresholdsStyle: { - mode: 'off', - }, - }, - mappings: [], - thresholds: { - mode: 'absolute', - steps: [ - { - color: 'green', - value: null, - }, - { - color: 'red', - value: 80, - }, - ], - }, - unit: 'none', - }, - overrides: [], - }, - options: { - legend: { - calcs: [], - displayMode: 'list', - placement: 'right', - showLegend: true, - }, - tooltip: { - mode: 'multi', - sort: 'desc', - }, - }, -}; - -local getMatcher(cfg) = '%(aerospikeSelector)s, aerospike_cluster=~"$aerospike_cluster"' % cfg; - -{ - grafanaDashboards+:: { - 'aerospike-overview.json': - dashboard.new( - 'Aerospike overview', - time_from='%s' % $._config.dashboardPeriod, - tags=($._config.dashboardTags), - timezone='%s' % $._config.dashboardTimezone, - refresh='%s' % $._config.dashboardRefresh, - description='', - uid=dashboardUid, - ) - .addLink(grafana.link.dashboards( - asDropdown=false, - title='Other Aerospike Dashboards', - includeVars=false, - keepTime=true, - tags=($._config.dashboardTags), - )) - .addTemplates( - [ - template.datasource( - promDatasourceName, - 'prometheus', - null, - label='Data source', - refresh='load' - ), - template.new( - 'job', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size,job)', - label='Job', - refresh=2, - includeAll=true, - multi=true, - allValues='.+', - sort=0 - ), - template.new( - 'cluster', - promDatasource, - 'label_values(aerospike_node_up{%(multiclusterSelector)s}, cluster)' % $._config, - label='Cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='.*', - hide=if $._config.enableMultiCluster then '' else 'variable', - sort=0 - ), - template.new( - 'aerospike_cluster', - promDatasource, - 'label_values(aerospike_namespace_ns_cluster_size{%(aerospikeSelector)s},aerospike_cluster)' % $._config, - label='Aerospike cluster', - refresh=2, - includeAll=true, - multi=true, - allValues='', - sort=0 - ), - template.custom( - 'k', - query='5,10,20,50', - current='5', - label='Top node count', - refresh='never', - includeAll=false, - multi=false, - allValues='', - ), - ] - ) - .addPanels( - [ - nodesPanel(getMatcher($._config)) { gridPos: { h: 7, w: 7, x: 0, y: 0 } }, - namespacesPanel(getMatcher($._config)) { gridPos: { h: 7, w: 7, x: 7, y: 0 } }, - unavailablePartitionsPanel(getMatcher($._config)) { gridPos: { h: 7, w: 5, x: 14, y: 0 } }, - deadPartitionsPanel(getMatcher($._config)) { gridPos: { h: 7, w: 5, x: 19, y: 0 } }, - topNodesByMemoryUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 7 } }, - topNodesByDiskUsagePanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 7 } }, - clientReadsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 15 } }, - clientWritesPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 15 } }, - clientUDFTransactionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 0, y: 23 } }, - connectionsPanel(getMatcher($._config)) { gridPos: { h: 8, w: 12, x: 12, y: 23 } }, - ] - ), - }, -} diff --git a/aerospike-mixin/dashboards/dashboards.libsonnet b/aerospike-mixin/dashboards/dashboards.libsonnet deleted file mode 100644 index 67a4e5a78..000000000 --- a/aerospike-mixin/dashboards/dashboards.libsonnet +++ /dev/null @@ -1,4 +0,0 @@ -(import 'aerospike-overview.libsonnet') + -(import 'aerospike-instance-overview.libsonnet') + -(import 'aerospike-namespace-overview.libsonnet') + -(import 'aerospike-logs-overview.libsonnet') diff --git a/aerospike-mixin/dashboards_out/aerospike-instance-overview.json b/aerospike-mixin/dashboards_out/aerospike-instance-overview.json index 8f2dd083c..8558ee8a9 100644 --- a/aerospike-mixin/dashboards_out/aerospike-instance-overview.json +++ b/aerospike-mixin/dashboards_out/aerospike-instance-overview.json @@ -1,94 +1,96 @@ { - "__inputs": [ ], - "__requires": [ ], "annotations": { "list": [ ] }, - "description": "", "editable": false, - "gnetId": null, - "graphTooltip": 0, - "hideControls": false, "id": null, "links": [ { - "asDropdown": false, - "icon": "external link", + "keepTime": true, + "title": "Aerospike namespace overview", + "type": "link", + "url": "/d/aerospike_namespace_overview" + }, + { + "keepTime": true, + "title": "Aerospike overview", + "type": "link", + "url": "/d/aerospike_overview" + }, + { + "keepTime": true, + "title": "Aerospike logs", + "type": "link", + "url": "/d/aerospike-logs" + }, + { + "asDropdown": true, "includeVars": true, "keepTime": true, "tags": [ - "aerospike-mixin" + "aerospike" ], - "targetBlank": false, - "title": "Other Aerospike Dashboards", - "type": "dashboards", - "url": "" + "title": "All dashboards", + "type": "dashboards" } ], "panels": [ + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 0, + "x": 0, + "y": 0 + }, + "id": 1, + "panels": [ ], + "title": "Instance", + "type": "row" + }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of unavailable data partitions in an Aerospike node.", + "description": "Number of unavailable partitions in this Aerospike instance", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] + "fixedColor": "green", + "mode": "fixed" }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, - "w": 7, + "w": 6, "x": 0, - "y": 0 + "y": 1 }, "id": 2, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster, instance) (aerospike_namespace_unavailable_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"})", + "expr": "sum by(instance,ns) (aerospike_namespace_unavailable_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}}", + "refId": "Unavailable partitions" } ], "title": "Unavailable partitions", @@ -96,93 +98,52 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Memory utilization in an Aerospike node.", "fieldConfig": { "defaults": { - "color": { - "mode": "continuous-BlYlRd" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "scheme", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 75, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, "unit": "percent" - }, - "overrides": [ ] + } }, "gridPos": { "h": 8, - "w": 17, - "x": 7, - "y": 0 + "w": 18, + "x": 6, + "y": 1 }, "id": 3, "options": { "legend": { "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + "displayMode": "list" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "100 - aerospike_node_stats_system_free_mem_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}", + "expr": "100 - aerospike_node_stats_system_free_mem_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}}", + "refId": "Node memory usage" } ], "title": "Memory usage", @@ -190,67 +151,47 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of dead data partitions in an Aerospike node.", + "description": "Number of dead partitions in this Aerospike instance", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" + "fixedColor": "green", + "mode": "fixed" }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, - "w": 7, + "w": 6, "x": 0, - "y": 8 + "y": 9 }, "id": 4, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster, instance) (aerospike_namespace_dead_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"})", + "expr": "sum by(instance,ns) (aerospike_namespace_dead_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}}", + "refId": "Dead partitions" } ], "title": "Dead partitions", @@ -258,191 +199,107 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Disk utilization in an Aerospike node.", + "description": "Disk utilization per namespace on an Aerospike node. Compatible with Aerospike versions < 7.0 using legacy metrics.", "fieldConfig": { "defaults": { - "color": { - "mode": "continuous-BlYlRd" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "scheme", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, "unit": "percent" - }, - "overrides": [ ] + } }, "gridPos": { "h": 8, - "w": 17, - "x": 7, - "y": 8 + "w": 18, + "x": 6, + "y": 9 }, "id": 5, "options": { "legend": { + "asTable": true, "calcs": [ ], "displayMode": "list", - "placement": "bottom", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "100 - sum by(job, aerospike_cluster, instance) (aerospike_namespace_device_free_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"})", + "expr": "100 - sum by (job,aerospike_cluster,cluster,instance,ns) (aerospike_namespace_device_free_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})\nor\nsum by (job,aerospike_cluster,cluster,instance,ns) (aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\", storage_engine=\"device\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}}", + "refId": "Disk usage" } ], - "title": "Disk usage", + "title": "Disk usage (%)", "type": "timeseries" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Fragmentation rate for the jemalloc heap in an Aerospike node.", "fieldConfig": { "defaults": { - "color": { - "mode": "thresholds" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "scheme", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 75, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "red", - "value": null - }, - { - "color": "#EAB839", - "value": 33 - }, - { - "color": "blue", - "value": 66 - } - ] + "spanNulls": false }, "unit": "percent" - }, - "overrides": [ ] + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 16 + "y": 17 }, "id": 6, "options": { "legend": { "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + "displayMode": "list" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_node_stats_heap_efficiency_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}", + "expr": "aerospike_node_stats_heap_efficiency_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}}", + "refId": "Heap memory efficiency" } ], "title": "Heap memory efficiency", @@ -450,109 +307,83 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of active connections to an Aerospike node.", + "description": "Number of active connections to this Aerospike instance.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 19, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 75, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 16 + "y": 17 }, "id": 7, "options": { "legend": { - "calcs": [ ], - "displayMode": "list", - "placement": "right", - "showLegend": true + "asTable": true, + "calcs": [ + "min", + "mean", + "max" + ], + "displayMode": "table", + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_node_stats_client_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}", + "expr": "aerospike_node_stats_client_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - client" + "instant": false, + "interval": "1m", + "legendFormat": "{{instance}} {{ns}}", + "refId": "Client connections" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_node_stats_fabric_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}", + "expr": "aerospike_node_stats_fabric_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - fabric" + "instant": false, + "interval": "1m", + "legendFormat": "{{instance}} {{ns}}", + "refId": "Fabric connections" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_node_stats_heartbeat_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}", + "expr": "aerospike_node_stats_heartbeat_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - heartbeat" + "instant": false, + "interval": "1m", + "legendFormat": "{{instance}} {{ns}}", + "refId": "Heartbeat connections" } ], "title": "Connections", @@ -560,130 +391,107 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client read transactions in an Aerospike node organized by result.", + "description": "Rate of client read transactions in this Aerospike instance organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "rps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 24 + "y": 25 }, "id": 8, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_read_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - success", + "refId": "Client read success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_read_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - error", + "refId": "Client read error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_read_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - timeout", + "refId": "Client read timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_read_not_found{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - not found", + "refId": "Client read not found rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_read_not_found{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_read_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - not found" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - filtered", + "refId": "Client read filtered rate" } ], "title": "Client reads", @@ -691,121 +499,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client write transactions in an Aerospike node organized by result.", + "description": "Rate of client write transactions in this Aerospike instance organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "wps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 24 + "y": 25 }, "id": 9, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_write_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - success", + "refId": "Client write success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_write_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - error", + "refId": "Client write error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_write_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - timeout", + "refId": "Client write timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_write_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_write_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - filtered", + "refId": "Client write filtered rate" } ], "title": "Client writes", @@ -813,121 +595,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client UDF transactions in an Aerospike node organized by result.", + "description": "Rate of client UDF transactions in this Aerospike instance organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } + "spanNulls": false }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "ops" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 32 + "y": 33 }, "id": 10, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_complete{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_udf_complete{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - complete" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - complete", + "refId": "Client UDF complete rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_udf_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - error", + "refId": "Client UDF error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_udf_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - timeout", + "refId": "Client UDF timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, instance) (rate(aerospike_namespace_client_udf_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"}[$__rate_interval]))", + "expr": "sum by(instance,ns) (rate(aerospike_namespace_client_udf_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ instance }} - filtered", + "refId": "Client UDF filtered rate" } ], "title": "Client UDF transactions", @@ -935,205 +691,154 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Percentage of read transactions that are resolved by a cache hit in an Aerospike node.", + "description": "Percentage of read transactions that are resolved by a cache hit.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, "unit": "percent" - }, - "overrides": [ ] + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 32 + "y": 33 }, "id": 11, "options": { "legend": { "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + "displayMode": "list" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "avg by(job, aerospike_cluster, instance) (aerospike_namespace_cache_read_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", instance=~\"$instance\"})", + "expr": "aerospike_namespace_cache_read_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "instant": false, + "legendFormat": "{{ aerospike_cluster }} - {{ ns }}", + "refId": "Cache read utilization" } ], "title": "Cache read utilization", "type": "timeseries" } ], - "refresh": "1m", - "rows": [ ], - "schemaVersion": 14, - "style": "dark", + "refresh": "30s", + "schemaVersion": 39, "tags": [ - "aerospike-mixin" + "aerospike" ], "templating": { "list": [ { - "current": { }, - "hide": 0, - "label": "Data source", + "label": "Prometheus data source", "name": "prometheus_datasource", - "options": [ ], "query": "prometheus", - "refresh": 1, - "regex": "", + "regex": "(?!grafanacloud-usage|grafanacloud-ml-metrics).+", "type": "datasource" }, { "allValue": ".+", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, "label": "Job", "multi": true, "name": "job", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size,job)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\"}, job)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { - "allValue": ".*", - "current": { }, + "allValue": ".+", "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 2, "includeAll": true, - "label": "Cluster", + "label": "Aerospike cluster", "multi": true, - "name": "cluster", - "options": [ ], - "query": "label_values(aerospike_node_stats_heap_efficiency_pct{job=~\"$job\"}, cluster)", + "name": "aerospike_cluster", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\"}, aerospike_cluster)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { - "allValue": "", - "current": { }, + "allValue": ".*", "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, - "label": "Aerospike cluster", + "label": "Cluster", "multi": true, - "name": "aerospike_cluster", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size{job=~\"$job\"}, aerospike_cluster)", + "name": "cluster", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\"}, cluster)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { "allValue": ".+", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, "label": "Instance", "multi": true, "name": "instance", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}, instance)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\"}, instance)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" + }, + { + "allValue": ".*", + "datasource": { + "type": "prometheus", + "uid": "${prometheus_datasource}" + }, + "includeAll": true, + "label": "Namespace", + "multi": true, + "name": "ns", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\"}, ns)", + "refresh": 2, + "sort": 1, + "type": "query" + }, + { + "hide": 2, + "label": "Loki data source", + "name": "loki_datasource", + "query": "loki", + "regex": "(?!grafanacloud.+usage-insights|grafanacloud.+alert-state-history).+", + "type": "datasource" } ] }, @@ -1141,33 +846,7 @@ "from": "now-30m", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, "timezone": "default", "title": "Aerospike instance overview", - "uid": "aerospike-instance-overview", - "version": 0 + "uid": "aerospike_instance_overview" } \ No newline at end of file diff --git a/aerospike-mixin/dashboards_out/aerospike-logs.json b/aerospike-mixin/dashboards_out/aerospike-logs-overview.json similarity index 79% rename from aerospike-mixin/dashboards_out/aerospike-logs.json rename to aerospike-mixin/dashboards_out/aerospike-logs-overview.json index 9b4444a57..c6e88780b 100644 --- a/aerospike-mixin/dashboards_out/aerospike-logs.json +++ b/aerospike-mixin/dashboards_out/aerospike-logs-overview.json @@ -1,17 +1,37 @@ { + "annotations": { + "list": [ ] + }, + "editable": false, + "id": null, "links": [ { - "asDropdown": false, - "icon": "external link", - "includeVars": false, + "keepTime": true, + "title": "Aerospike instance overview", + "type": "link", + "url": "/d/aerospike_instance_overview" + }, + { + "keepTime": true, + "title": "Aerospike namespace overview", + "type": "link", + "url": "/d/aerospike_namespace_overview" + }, + { + "keepTime": true, + "title": "Aerospike overview", + "type": "link", + "url": "/d/aerospike_overview" + }, + { + "asDropdown": true, + "includeVars": true, "keepTime": true, "tags": [ - "aerospike-mixin" + "aerospike" ], - "targetBlank": false, - "title": "Other Aerospike Dashboards", - "type": "dashboards", - "url": "" + "title": "All dashboards", + "type": "dashboards" } ], "panels": [ @@ -161,7 +181,7 @@ "type": "loki", "uid": "${loki_datasource}" }, - "expr": "sum by (level) (count_over_time({job=~\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",instance=~\"$instance\",context=~\"$context\",level=~\"$level\"}\n|~ \"$regex_search\"\n\n[$__auto]))\n", + "expr": "sum by (level) (count_over_time({job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",level=~\"$level\"}\n|~ \"$regex_search\"\n\n[$__auto]))\n", "legendFormat": "{{ level }}" } ], @@ -194,7 +214,7 @@ "enableLogDetails": true, "prettifyLogMessage": true, "showTime": false, - "wrapLogMessage": true + "wrapLogMessage": false }, "pluginVersion": "v11.0.0", "targets": [ @@ -203,17 +223,17 @@ "type": "loki", "uid": "${loki_datasource}" }, - "expr": "{job=~\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",instance=~\"$instance\",context=~\"$context\",level=~\"$level\"} \n|~ \"$regex_search\"\n\n\n" + "expr": "{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",level=~\"$level\"} \n|~ \"$regex_search\"\n\n\n" } ], "title": "Logs", "type": "logs" } ], - "refresh": "1m", + "refresh": "30s", "schemaVersion": 39, "tags": [ - "aerospike-mixin" + "aerospike" ], "templating": { "list": [ @@ -221,7 +241,7 @@ "label": "Loki data source", "name": "loki_datasource", "query": "loki", - "regex": "", + "regex": "(?!grafanacloud.+usage-insights|grafanacloud.+alert-state-history).+", "type": "datasource" }, { @@ -234,7 +254,7 @@ "label": "Job", "multi": true, "name": "job", - "query": "label_values({job=~\"integrations/aerospike\"}, job)", + "query": "label_values({job=\"integrations/aerospike\"}, job)", "refresh": 2, "sort": 1, "type": "query" @@ -246,10 +266,10 @@ "uid": "${loki_datasource}" }, "includeAll": true, - "label": "Aerospike_cluster", + "label": "Aerospike cluster", "multi": true, "name": "aerospike_cluster", - "query": "label_values({job=~\"integrations/aerospike\",job=~\"$job\"}, aerospike_cluster)", + "query": "label_values({job=\"integrations/aerospike\",job=~\"$job\"}, aerospike_cluster)", "refresh": 2, "sort": 1, "type": "query" @@ -261,25 +281,10 @@ "uid": "${loki_datasource}" }, "includeAll": true, - "label": "Instance", + "label": "Cluster", "multi": true, - "name": "instance", - "query": "label_values({job=~\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\"}, instance)", - "refresh": 2, - "sort": 1, - "type": "query" - }, - { - "allValue": ".*", - "datasource": { - "type": "loki", - "uid": "${loki_datasource}" - }, - "includeAll": true, - "label": "Context", - "multi": true, - "name": "context", - "query": "label_values({job=~\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",instance=~\"$instance\"}, context)", + "name": "cluster", + "query": "label_values({job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\"}, cluster)", "refresh": 2, "sort": 1, "type": "query" @@ -294,7 +299,7 @@ "label": "Level", "multi": true, "name": "level", - "query": "label_values({job=~\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",instance=~\"$instance\",context=~\"$context\"}, level)", + "query": "label_values({job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\"}, level)", "refresh": 2, "sort": 1, "type": "query" @@ -316,14 +321,22 @@ ], "query": "", "type": "textbox" + }, + { + "hide": 2, + "label": "Prometheus data source", + "name": "prometheus_datasource", + "query": "prometheus", + "regex": "(?!grafanacloud-usage|grafanacloud-ml-metrics).+", + "type": "datasource" } ] }, "time": { - "from": "now-6h", + "from": "now-30m", "to": "now" }, - "timezone": "utc", + "timezone": "default", "title": "Aerospike logs", "uid": "aerospike-logs" } \ No newline at end of file diff --git a/aerospike-mixin/dashboards_out/aerospike-namespace-overview.json b/aerospike-mixin/dashboards_out/aerospike-namespace-overview.json index 19899990e..61cf7ff6d 100644 --- a/aerospike-mixin/dashboards_out/aerospike-namespace-overview.json +++ b/aerospike-mixin/dashboards_out/aerospike-namespace-overview.json @@ -1,94 +1,96 @@ { - "__inputs": [ ], - "__requires": [ ], "annotations": { "list": [ ] }, - "description": "", "editable": false, - "gnetId": null, - "graphTooltip": 0, - "hideControls": false, "id": null, "links": [ { - "asDropdown": false, - "icon": "external link", + "keepTime": true, + "title": "Aerospike instance overview", + "type": "link", + "url": "/d/aerospike_instance_overview" + }, + { + "keepTime": true, + "title": "Aerospike overview", + "type": "link", + "url": "/d/aerospike_overview" + }, + { + "keepTime": true, + "title": "Aerospike logs", + "type": "link", + "url": "/d/aerospike-logs" + }, + { + "asDropdown": true, "includeVars": true, "keepTime": true, "tags": [ - "aerospike-mixin" + "aerospike" ], - "targetBlank": false, - "title": "Other Aerospike Dashboards", - "type": "dashboards", - "url": "" + "title": "All dashboards", + "type": "dashboards" } ], "panels": [ + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 0, + "x": 0, + "y": 0 + }, + "id": 1, + "panels": [ ], + "title": "Namespace", + "type": "row" + }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of unavailable data partitions in an Aerospike namespace.", + "description": "Number of unavailable partitions in this Aerospike namespace", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] + "fixedColor": "green", + "mode": "fixed" }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, - "w": 8, + "w": 6, "x": 0, - "y": 0 + "y": 1 }, "id": 2, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "vertical", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_namespace_unavailable_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}", + "expr": "aerospike_namespace_unavailable_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}} - {{ns}}", + "refId": "Unavailable partitions" } ], "title": "Unavailable partitions", @@ -96,93 +98,51 @@ }, { "datasource": { - "uid": "${prometheus_datasource}" + "type": "datasource", + "uid": "-- Mixed --" }, - "description": "Disk utilization in an Aerospike namespace.", "fieldConfig": { "defaults": { - "color": { - "mode": "continuous-BlYlRd" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "scheme", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, - "lineInterpolation": "smooth", - "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } + "fillOpacity": 0, + "spanNulls": false }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, + "unit": "percent" + }, + "overrides": [ + { + "matcher": { + "id": "byFrameRefID", + "options": "Namespace disk usage" + }, + "properties": [ { - "color": "red", - "value": 80 + "id": "unit", + "value": "percent" } ] - }, - "unit": "percent" - }, - "overrides": [ ] + } + ] }, "gridPos": { "h": 8, - "w": 16, - "x": 8, - "y": 0 + "w": 18, + "x": 6, + "y": 1 }, "id": 3, - "options": { - "legend": { - "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "desc" - } - }, + "pluginVersion": "v11.4.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "100 - aerospike_namespace_device_free_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}", + "expr": "100 - aerospike_namespace_device_free_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}\nor\naerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\", storage_engine=\"device\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}} - {{ns}}", + "refId": "Namespace disk usage" } ], "title": "Disk usage", @@ -190,67 +150,47 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of dead data partitions in an Aerospike namespace.", + "description": "Number of dead partitions in this Aerospike namespace", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] + "fixedColor": "green", + "mode": "fixed" }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, - "w": 8, + "w": 6, "x": 0, - "y": 8 + "y": 9 }, "id": 4, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_namespace_dead_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}", + "expr": "aerospike_namespace_dead_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}} - {{ns}}", + "refId": "Dead partitions" } ], "title": "Dead partitions", @@ -258,93 +198,52 @@ }, { "datasource": { - "uid": "${prometheus_datasource}" + "type": "datasource", + "uid": "-- Mixed --" }, - "description": "Memory utilization in an Aerospike namespace.", + "description": "Memory utilization in an Aerospike namespace", "fieldConfig": { "defaults": { - "color": { - "mode": "continuous-BlYlRd" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "scheme", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, - "lineInterpolation": "smooth", - "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } + "fillOpacity": 0, + "spanNulls": false }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, + "unit": "percent" + }, + "overrides": [ + { + "matcher": { + "id": "byFrameRefID", + "options": "Namespace memory usage" + }, + "properties": [ { - "color": "red", - "value": 80 + "id": "unit", + "value": "percent" } ] - }, - "unit": "percent" - }, - "overrides": [ ] + } + ] }, "gridPos": { "h": 8, - "w": 16, - "x": 8, - "y": 8 + "w": 18, + "x": 6, + "y": 9 }, "id": 5, - "options": { - "legend": { - "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true - }, - "tooltip": { - "mode": "multi", - "sort": "desc" - } - }, + "pluginVersion": "v11.4.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "100 - aerospike_namespace_memory_free_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}", + "expr": "100 - aerospike_namespace_memory_free_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}\nor\naerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\", storage_engine=\"memory\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}}" + "instant": false, + "legendFormat": "{{instance}} {{ns}} - {{ns}}", + "refId": "Namespace memory usage" } ], "title": "Memory usage", @@ -352,131 +251,107 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client read transactions in an Aerospike namespace organized by result.", + "description": "Rate of client read transactions in this Aerospike namespace organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "rps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 16 + "y": 17 }, "id": 6, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "bottom", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_read_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - success", + "refId": "Read transaction success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_read_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - error", + "refId": "Read transaction error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_read_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - timeout", + "refId": "Read transaction timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_read_not_found{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - not found", + "refId": "Read transaction not found rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_read_not_found{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_read_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - not found" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - filtered", + "refId": "Read transaction filtered rate" } ], "title": "Client reads", @@ -484,122 +359,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client write transactions in an Aerospike namespace organized by result.", + "description": "Rate of client write transactions in this Aerospike namespace organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "wps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 16 + "y": 17 }, "id": 7, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "bottom", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_write_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - success", + "refId": "Write transaction success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_write_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - error", + "refId": "Write transaction error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_write_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - timeout", + "refId": "Write transaction timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_write_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_write_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - filtered", + "refId": "Write transaction filtered rate" } ], "title": "Client writes", @@ -607,121 +455,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Rate of client UDF transactions in an Aerospike namespace organized by result.", + "description": "Rate of client UDF transactions in this Aerospike namespace organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } + "spanNulls": false }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "ops" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 24 + "y": 25 }, "id": 8, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "bottom", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_complete{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_udf_complete{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - complete" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - complete", + "refId": "UDF transaction complete rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_udf_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - error", + "refId": "UDF transaction error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_udf_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - timeout", + "refId": "UDF transaction timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job, ns) (rate(aerospike_namespace_client_udf_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}[$__rate_interval]))", + "expr": "rate(aerospike_namespace_client_udf_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval])", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{ aerospike_cluster }} - {{ ns }} - filtered", + "refId": "UDF transaction filtered rate" } ], "title": "Client UDF transactions", @@ -729,205 +551,154 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Percentage of read transactions that are resolved by a cache hit in an Aerospike namespace.", + "description": "Percentage of read transactions that are resolved by a cache hit.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, "unit": "percent" - }, - "overrides": [ ] + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 24 + "y": 25 }, "id": 9, "options": { "legend": { "calcs": [ ], - "displayMode": "list", - "placement": "bottom", - "showLegend": true + "displayMode": "list" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "aerospike_namespace_cache_read_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\", ns=~\"$ns\"}", + "expr": "aerospike_namespace_cache_read_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - {{ns}}" + "instant": false, + "legendFormat": "{{ aerospike_cluster }} - {{ ns }}", + "refId": "Cache read utilization" } ], "title": "Cache read utilization", "type": "timeseries" } ], - "refresh": "1m", - "rows": [ ], - "schemaVersion": 14, - "style": "dark", + "refresh": "30s", + "schemaVersion": 39, "tags": [ - "aerospike-mixin" + "aerospike" ], "templating": { "list": [ { - "current": { }, - "hide": 0, - "label": "Data source", + "label": "Prometheus data source", "name": "prometheus_datasource", - "options": [ ], "query": "prometheus", - "refresh": 1, - "regex": "", + "regex": "(?!grafanacloud-usage|grafanacloud-ml-metrics).+", "type": "datasource" }, { "allValue": ".+", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, "label": "Job", "multi": true, "name": "job", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size,job)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\"}, job)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" + }, + { + "allValue": ".+", + "datasource": { + "type": "prometheus", + "uid": "${prometheus_datasource}" + }, + "includeAll": true, + "label": "Aerospike cluster", + "multi": true, + "name": "aerospike_cluster", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\"}, aerospike_cluster)", + "refresh": 2, + "sort": 1, + "type": "query" }, { "allValue": ".*", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 2, "includeAll": true, "label": "Cluster", "multi": true, "name": "cluster", - "options": [ ], - "query": "label_values(aerospike_namespace_dead_partitions{job=~\"$job\"}, cluster)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\"}, cluster)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { - "allValue": "", - "current": { }, + "allValue": ".+", "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, - "label": "Aerospike cluster", + "label": "Instance", "multi": true, - "name": "aerospike_cluster", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size{job=~\"$job\"}, aerospike_cluster)", + "name": "instance", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\"}, instance)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { - "allValue": "", - "current": { }, + "allValue": ".*", "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, "label": "Namespace", "multi": true, "name": "ns", - "options": [ ], - "query": "label_values(aerospike_namespace_xmem_id{job=~\"$job\"}, ns)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\"}, ns)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" + }, + { + "hide": 2, + "label": "Loki data source", + "name": "loki_datasource", + "query": "loki", + "regex": "(?!grafanacloud.+usage-insights|grafanacloud.+alert-state-history).+", + "type": "datasource" } ] }, @@ -935,33 +706,7 @@ "from": "now-30m", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, "timezone": "default", "title": "Aerospike namespace overview", - "uid": "aerospike-namespace-overview", - "version": 0 + "uid": "aerospike_namespace_overview" } \ No newline at end of file diff --git a/aerospike-mixin/dashboards_out/aerospike-overview.json b/aerospike-mixin/dashboards_out/aerospike-overview.json index 632ec2eac..b1273ab6c 100644 --- a/aerospike-mixin/dashboards_out/aerospike-overview.json +++ b/aerospike-mixin/dashboards_out/aerospike-overview.json @@ -1,66 +1,60 @@ { - "__inputs": [ ], - "__requires": [ ], "annotations": { "list": [ ] }, - "description": "", "editable": false, - "gnetId": null, - "graphTooltip": 0, - "hideControls": false, "id": null, "links": [ { - "asDropdown": false, - "icon": "external link", - "includeVars": false, + "keepTime": true, + "title": "Aerospike instance overview", + "type": "link", + "url": "/d/aerospike_instance_overview" + }, + { + "keepTime": true, + "title": "Aerospike namespace overview", + "type": "link", + "url": "/d/aerospike_namespace_overview" + }, + { + "keepTime": true, + "title": "Aerospike logs", + "type": "link", + "url": "/d/aerospike-logs" + }, + { + "asDropdown": true, + "includeVars": true, "keepTime": true, "tags": [ - "aerospike-mixin" + "aerospike" ], - "targetBlank": false, - "title": "Other Aerospike Dashboards", - "type": "dashboards", - "url": "" + "title": "All dashboards", + "type": "dashboards" } ], "panels": [ + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 0, + "x": 0, + "y": 0 + }, + "id": 1, + "panels": [ ], + "title": "Overview", + "type": "row" + }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Number of nodes in an Aerospike cluster.", "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "green", - "mode": "fixed" - }, - "custom": { - "align": "left", - "cellOptions": { - "type": "auto" - }, - "filterable": false, - "inspect": false, - "minWidth": 50 - }, - "links": [ ], - "mappings": [ ], - "max": 256, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, "overrides": [ { "matcher": { @@ -92,6 +86,10 @@ "options": "instance" }, "properties": [ + { + "id": "displayName", + "value": "Instance" + }, { "id": "custom.filterable", "value": true @@ -101,7 +99,7 @@ "value": [ { "title": "Instance overview", - "url": "/d/aerospike-instance-overview" + "url": "/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}" } ] } @@ -134,43 +132,36 @@ ] }, "gridPos": { - "h": 7, - "w": 7, + "h": 8, + "w": 6, "x": 0, - "y": 0 + "y": 1 }, "id": 2, - "links": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ], "options": { "cellHeight": "md", "footer": { "countRows": false, - "enablePagination": false, "fields": [ ], "reducer": [ "sum" ], "show": false }, - "frameIndex": 0, "showHeader": true }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster, instance) (aerospike_namespace_ns_cluster_size{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster, instance,ns) (aerospike_namespace_ns_cluster_size{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "table", "instant": true, - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "legendFormat": "", + "refId": "Nodes cluster size" } ], "title": "Nodes", @@ -192,37 +183,11 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Number of namespaces in an Aerospike cluster.", "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "green", - "mode": "fixed" - }, - "custom": { - "align": "left", - "cellOptions": { - "type": "auto" - }, - "inspect": false - }, - "links": [ ], - "mappings": [ ], - "max": 32, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, "overrides": [ { "matcher": { @@ -251,33 +216,33 @@ { "matcher": { "id": "byName", - "options": "instance" + "options": "aerospike_cluster" }, "properties": [ { - "id": "custom.filterable", - "value": true - }, - { - "id": "links", - "value": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ] + "id": "displayName", + "value": "Aerospike cluster" } ] }, { "matcher": { "id": "byName", - "options": "aerospike_cluster" + "options": "instance" }, "properties": [ { "id": "displayName", - "value": "Aerospike cluster" + "value": "Instance" + }, + { + "id": "links", + "value": [ + { + "title": "Instance overview", + "url": "/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}" + } + ] } ] }, @@ -289,7 +254,16 @@ "properties": [ { "id": "displayName", - "value": "namespace" + "value": "Namespace" + }, + { + "id": "links", + "value": [ + { + "title": "Namespace overview", + "url": "/d/aerospike_namespace_overview?var-ns=${__data.fields.ns}&${__url_time_range}&var-datasource=${datasource}" + } + ] } ] }, @@ -308,289 +282,158 @@ ] }, "gridPos": { - "h": 7, - "w": 7, - "x": 7, - "y": 0 + "h": 8, + "w": 6, + "x": 6, + "y": 1 }, "id": 3, - "links": [ - { - "title": "Namespace overview", - "url": "/d/aerospike-namespace-overview" - } - ], - "options": { - "cellHeight": "md", - "footer": { - "countRows": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true, - "sortBy": [ ] - }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster, instance, ns) (aerospike_namespace_ns_cluster_size{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster, instance,ns) (aerospike_namespace_ns_cluster_size{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "table", "instant": true, - "intervalFactor": 2, - "legendFormat": "{{ns}}" + "legendFormat": "", + "refId": "Namespaces cluster size" } ], "title": "Namespaces", - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": { }, - "sort": [ - { - "desc": true, - "field": "Time" - } - ] - } - } - ], "type": "table" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of unavailable data partitions in an Aerospike cluster.", + "description": "Number of unavailable partitions in Aerospike namespaces", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" - }, - "decimals": 0, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] + "fixedColor": "green", + "mode": "fixed" }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { - "h": 7, - "w": 5, - "x": 14, - "y": 0 + "h": 8, + "w": 6, + "x": 12, + "y": 1 }, "id": 4, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster) (aerospike_namespace_unavailable_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster) (aerospike_namespace_unavailable_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}}" + "instant": false, + "legendFormat": "{{aerospike_cluster}}", + "refId": "Unavailable partitions" } ], "title": "Unavailable partitions", - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": { }, - "sort": [ - { - "desc": true, - "field": "Time" - } - ] - } - } - ], "type": "bargauge" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Number of dead data partitions in an Aerospike cluster.", + "description": "Number of dead partitions in Aerospike namespaces", "fieldConfig": { "defaults": { "color": { - "mode": "thresholds" - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 1 - } - ] + "fixedColor": "green", + "mode": "fixed" }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { - "h": 7, - "w": 5, - "x": 19, - "y": 0 + "h": 8, + "w": 6, + "x": 18, + "y": 1 }, "id": 5, "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", + "colorMode": "fixed", + "graphMode": "none", "reduceOptions": { "calcs": [ "lastNotNull" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": { - "valueSize": 100 - }, - "valueMode": "color" + ] + } }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(job, aerospike_cluster) (aerospike_namespace_dead_partitions{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster) (aerospike_namespace_dead_partitions{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}}" + "instant": false, + "legendFormat": "{{aerospike_cluster}}", + "refId": "Dead partitions" } ], "title": "Dead partitions", - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": { }, - "sort": [ - { - "desc": true, - "field": "Time" - } - ] - } - } - ], "type": "bargauge" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Memory utilization for the top k nodes in an Aerospike cluster.", "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "green", - "mode": "fixed" - }, - "custom": { - "align": "left", - "cellOptions": { - "type": "auto" - }, - "inspect": false - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "percent" - }, "overrides": [ { "matcher": { "id": "byName", - "options": "Time" + "options": "Value" }, "properties": [ { - "id": "custom.hidden", - "value": true + "id": "displayName", + "value": "Usage" + }, + { + "id": "unit", + "value": "percent" } ] }, { "matcher": { "id": "byName", - "options": "instance" + "options": "Time" }, "properties": [ { - "id": "custom.filterable", + "id": "custom.hidden", "value": true - }, - { - "id": "links", - "value": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ] } ] }, @@ -609,12 +452,21 @@ { "matcher": { "id": "byName", - "options": "Value" + "options": "instance" }, "properties": [ { "id": "displayName", - "value": "usage" + "value": "Instance" + }, + { + "id": "links", + "value": [ + { + "title": "Instance overview", + "url": "/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}" + } + ] } ] }, @@ -636,121 +488,60 @@ "h": 8, "w": 12, "x": 0, - "y": 7 + "y": 9 }, "id": 6, - "links": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ], - "options": { - "cellHeight": "md", - "footer": { - "countRows": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "topk($k, 100 - sum by(job, aerospike_cluster, instance) (avg_over_time(aerospike_node_stats_system_free_mem_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__interval])))", + "expr": "topk($k, 100 - sum by(job,aerospike_cluster,cluster, instance,ns) (avg_over_time(aerospike_node_stats_system_free_mem_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__interval])))", "format": "table", "instant": true, - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "interval": "1m", + "legendFormat": "", + "refId": "Top nodes by memory usage" } ], "title": "Top nodes by memory usage", - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": { }, - "sort": [ - { - "desc": true, - "field": "Time" - } - ] - } - } - ], "type": "table" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "description": "Disk utilization for the top k nodes in an Aerospike cluster.", + "description": "Disk utilization for the top k nodes in an Aerospike cluster. Compatible with Aerospike versions < 7.0 using legacy metrics.", "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "green", - "mode": "fixed" - }, - "custom": { - "align": "left", - "cellOptions": { - "type": "auto" - }, - "filterable": false, - "inspect": false - }, - "mappings": [ ], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "percent" - }, "overrides": [ { "matcher": { "id": "byName", - "options": "Time" + "options": "Value" }, "properties": [ { - "id": "custom.hidden", - "value": true + "id": "displayName", + "value": "Usage" + }, + { + "id": "unit", + "value": "percent" } ] }, { "matcher": { "id": "byName", - "options": "instance" + "options": "Time" }, "properties": [ { - "id": "custom.filterable", + "id": "custom.hidden", "value": true - }, - { - "id": "links", - "value": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ] } ] }, @@ -769,12 +560,21 @@ { "matcher": { "id": "byName", - "options": "Value" + "options": "instance" }, "properties": [ { "id": "displayName", - "value": "usage" + "value": "Instance" + }, + { + "id": "links", + "value": [ + { + "title": "Instance overview", + "url": "/d/aerospike_instance_overview?var-instance=${__data.fields.instance}&${__url_time_range}&var-datasource=${datasource}" + } + ] } ] }, @@ -796,184 +596,130 @@ "h": 8, "w": 12, "x": 12, - "y": 7 + "y": 9 }, "id": 7, - "links": [ - { - "title": "Instance overview", - "url": "/d/aerospike-instance-overview" - } - ], - "options": { - "cellHeight": "md", - "footer": { - "countRows": false, - "fields": "", - "reducer": [ - "sum" - ], - "show": false - }, - "showHeader": true - }, - "pluginVersion": "10.2.0-59542pre", + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "topk($k, 100 - sum by(job, aerospike_cluster, instance) (avg_over_time(aerospike_namespace_device_free_pct{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__interval])))", + "expr": "topk($k, 100 - sum by(job,aerospike_cluster,cluster, instance,ns) (avg_over_time(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__interval])))\nor\ntopk($k, 100 - sum by(job,aerospike_cluster,cluster, instance,ns) (avg_over_time(aerospike_namespace_device_free_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__interval])))", "format": "table", "instant": true, - "intervalFactor": 2, - "legendFormat": "{{instance}}" + "interval": "1m", + "legendFormat": "", + "refId": "Top nodes by disk usage" } ], "title": "Top nodes by disk usage", - "transformations": [ - { - "id": "sortBy", - "options": { - "fields": { }, - "sort": [ - { - "desc": true, - "field": "Time" - } - ] - } - } - ], "type": "table" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Rate of client read transactions in an Aerospike cluster organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "rps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 15 + "y": 17 }, "id": 8, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_read_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - success", + "refId": "Client read success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_read_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - error", + "refId": "Client read error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_read_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - timeout", + "refId": "Client read timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_read_not_found{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - not found", + "refId": "Client read not found rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_read_not_found{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_read_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - not found" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - filtered", + "refId": "Client read filtered rate" } ], "title": "Client reads", @@ -981,122 +727,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Rate of client write transactions in an Aerospike cluster organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } + "spanNulls": false }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "wps" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 15 + "y": 17 }, "id": 9, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_success{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_write_success{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - success" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - success", + "refId": "Client write success rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_write_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - error", + "refId": "Client write error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_write_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - timeout", + "refId": "Client write timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_write_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_write_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - filtered", + "refId": "Client write filtered rate" } ], "title": "Client writes", @@ -1104,122 +823,95 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Rate of client UDF transactions in an Aerospike cluster organized by result.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] + "spanNulls": false }, - "unit": "ops" - }, - "overrides": [ ] + "unit": "reqps" + } }, "gridPos": { "h": 8, "w": 12, "x": 0, - "y": 23 + "y": 25 }, "id": 10, "options": { "legend": { + "asTable": true, "calcs": [ "min", "mean", "max" ], "displayMode": "table", - "placement": "right", - "showLegend": true + "placement": "right" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_complete{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_udf_complete{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - complete" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - complete", + "refId": "Client UDF complete rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_error{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_udf_error{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - error" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - error", + "refId": "Client UDF error rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_filtered_out{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_udf_timeout{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - filtered" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - timeout", + "refId": "Client UDF timeout rate" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (rate(aerospike_namespace_client_udf_timeout{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"}[$__rate_interval]))", + "expr": "sum by(job,aerospike_cluster,cluster) (rate(aerospike_namespace_client_udf_filtered_out{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"}[$__rate_interval]))", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - timeout" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - filtered", + "refId": "Client UDF filtered rate" } ], "title": "Client UDF transactions", @@ -1227,232 +919,218 @@ }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, "description": "Number of active connections to an Aerospike cluster.", "fieldConfig": { "defaults": { - "color": { - "mode": "palette-classic" - }, "custom": { - "axisCenteredZero": false, - "axisColorMode": "text", - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 20, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "insertNulls": false, + "fillOpacity": 0, + "gradientMode": "opacity", "lineInterpolation": "smooth", "lineWidth": 2, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } + "spanNulls": false }, - "mappings": [ ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [ ] + "unit": "short" + } }, "gridPos": { "h": 8, "w": 12, "x": 12, - "y": 23 + "y": 25 }, "id": 11, "options": { "legend": { "calcs": [ ], - "displayMode": "list", - "placement": "right", - "showLegend": true + "displayMode": "list" }, "tooltip": { "mode": "multi", "sort": "desc" } }, + "pluginVersion": "v11.0.0", "targets": [ { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (aerospike_node_stats_client_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster) (aerospike_node_stats_client_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - client" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - client", + "refId": "Client connections" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (aerospike_node_stats_fabric_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster) (aerospike_node_stats_fabric_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - fabric" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - fabric", + "refId": "Fabric connections" }, { "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "expr": "sum by(aerospike_cluster, job) (aerospike_node_stats_heartbeat_connections{job=~\"$job\", aerospike_cluster=~\"$aerospike_cluster\"})", + "expr": "sum by(job,aerospike_cluster,cluster) (aerospike_node_stats_heartbeat_connections{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\",ns=~\"$ns\"})", "format": "time_series", - "intervalFactor": 2, - "legendFormat": "{{aerospike_cluster}} - heartbeat" + "instant": false, + "interval": "1m", + "legendFormat": "{{aerospike_cluster}} - heartbeat", + "refId": "Heartbeat connections" } ], "title": "Connections", "type": "timeseries" } ], - "refresh": "1m", - "rows": [ ], - "schemaVersion": 14, - "style": "dark", + "refresh": "30s", + "schemaVersion": 39, "tags": [ - "aerospike-mixin" + "aerospike" ], "templating": { "list": [ { - "current": { }, - "hide": 0, - "label": "Data source", + "label": "Prometheus data source", "name": "prometheus_datasource", - "options": [ ], "query": "prometheus", - "refresh": 1, - "regex": "", + "regex": "(?!grafanacloud-usage|grafanacloud-ml-metrics).+", "type": "datasource" }, { "allValue": ".+", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, "label": "Job", "multi": true, "name": "job", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size,job)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\"}, job)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" + }, + { + "allValue": ".+", + "datasource": { + "type": "prometheus", + "uid": "${prometheus_datasource}" + }, + "includeAll": true, + "label": "Aerospike cluster", + "multi": true, + "name": "aerospike_cluster", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\"}, aerospike_cluster)", + "refresh": 2, + "sort": 1, + "type": "query" }, { "allValue": ".*", - "current": { }, "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 2, "includeAll": true, "label": "Cluster", "multi": true, "name": "cluster", - "options": [ ], - "query": "label_values(aerospike_node_up{job=~\"$job\"}, cluster)", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\"}, cluster)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" }, { - "allValue": "", - "current": { }, + "allValue": ".+", "datasource": { + "type": "prometheus", "uid": "${prometheus_datasource}" }, - "hide": 0, "includeAll": true, - "label": "Aerospike cluster", + "label": "Instance", "multi": true, - "name": "aerospike_cluster", - "options": [ ], - "query": "label_values(aerospike_namespace_ns_cluster_size{job=~\"$job\"},aerospike_cluster)", + "name": "instance", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\"}, instance)", + "refresh": 2, + "sort": 1, + "type": "query" + }, + { + "allValue": ".*", + "datasource": { + "type": "prometheus", + "uid": "${prometheus_datasource}" + }, + "includeAll": true, + "label": "Namespace", + "multi": true, + "name": "ns", + "query": "label_values(aerospike_namespace_data_used_pct{job=\"integrations/aerospike\",job=~\"$job\",aerospike_cluster=~\"$aerospike_cluster\",cluster=~\"$cluster\",instance=~\"$instance\"}, ns)", "refresh": 2, - "regex": "", - "sort": 0, - "tagValuesQuery": "", - "tags": [ ], - "tagsQuery": "", - "type": "query", - "useTags": false + "sort": 1, + "type": "query" + }, + { + "hide": 2, + "label": "Loki data source", + "name": "loki_datasource", + "query": "loki", + "regex": "(?!grafanacloud.+usage-insights|grafanacloud.+alert-state-history).+", + "type": "datasource" }, { - "allValue": "", "current": { - "text": "5", - "value": "5" + "selected": false, + "text": "2", + "value": "2" }, - "hide": 0, "includeAll": false, "label": "Top node count", "multi": false, "name": "k", "options": [ { - "text": "5", - "value": "5" + "selected": true, + "text": "2", + "value": "2" }, { - "text": "10", - "value": "10" + "selected": false, + "text": "4", + "value": "4" }, { - "text": "20", - "value": "20" + "selected": false, + "text": "6", + "value": "6" }, { - "text": "50", - "value": "50" + "selected": false, + "text": "8", + "value": "8" + }, + { + "selected": false, + "text": "10", + "value": "10" } ], - "query": "5,10,20,50", - "refresh": 0, + "query": "2 : 2,4 : 4,6 : 6,8 : 8,10 : 10", "type": "custom" } ] @@ -1461,33 +1139,7 @@ "from": "now-30m", "to": "now" }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, "timezone": "default", "title": "Aerospike overview", - "uid": "aerospike-overview", - "version": 0 + "uid": "aerospike_overview" } \ No newline at end of file diff --git a/aerospike-mixin/g.libsonnet b/aerospike-mixin/g.libsonnet new file mode 100644 index 000000000..e6a2060ee --- /dev/null +++ b/aerospike-mixin/g.libsonnet @@ -0,0 +1 @@ +import 'github.com/grafana/grafonnet/gen/grafonnet-v11.4.0/main.libsonnet' diff --git a/aerospike-mixin/jsonnetfile.json b/aerospike-mixin/jsonnetfile.json index 83a4fe35b..c93b0edca 100644 --- a/aerospike-mixin/jsonnetfile.json +++ b/aerospike-mixin/jsonnetfile.json @@ -10,15 +10,33 @@ }, "version": "master" }, + { + "source": { + "git": { + "remote": "https://github.com/grafana/jsonnet-libs.git", + "subdir": "common-lib" + } + }, + "version": "master" + }, { "source": { "git": { "remote": "https://github.com/grafana/grafonnet.git", - "subdir": "gen/grafonnet-latest" + "subdir": "gen/grafonnet-v11.4.0" } }, "version": "main" }, + { + "source": { + "git": { + "remote": "https://github.com/grafana/jsonnet-libs.git", + "subdir": "grafana-cloud-integration-utils" + } + }, + "version": "master" + }, { "source": { "git": { diff --git a/aerospike-mixin/links.libsonnet b/aerospike-mixin/links.libsonnet new file mode 100644 index 000000000..b17f8ee22 --- /dev/null +++ b/aerospike-mixin/links.libsonnet @@ -0,0 +1,32 @@ +local g = import './g.libsonnet'; +{ + local link = g.dashboard.link, + new(this): + { + aerospikeOverview: + link.link.new(this.config.dashboardNamePrefix + ' overview', '/d/' + this.grafana.dashboards['aerospike-overview.json'].uid) + + link.link.options.withKeepTime(true), + + aerospikeInstanceOverview: + link.link.new(this.config.dashboardNamePrefix + ' instance overview', '/d/' + this.grafana.dashboards['aerospike-instance-overview.json'].uid) + + link.link.options.withKeepTime(true), + + aerospikeNamespaceOverview: + link.link.new(this.config.dashboardNamePrefix + ' namespace overview', '/d/' + this.grafana.dashboards['aerospike-namespace-overview.json'].uid) + + link.link.options.withKeepTime(true), + + otherDashboards: + link.dashboards.new('All dashboards', this.config.dashboardTags) + + link.dashboards.options.withIncludeVars(true) + + link.dashboards.options.withKeepTime(true) + + link.dashboards.options.withAsDropdown(true), + } + + + if this.config.enableLokiLogs then + { + logs: + link.link.new(this.config.dashboardNamePrefix + ' logs', '/d/' + this.grafana.dashboards['aerospike-logs-overview.json'].uid) + + link.link.options.withKeepTime(true), + } + else {}, +} diff --git a/aerospike-mixin/main.libsonnet b/aerospike-mixin/main.libsonnet new file mode 100644 index 000000000..80200f614 --- /dev/null +++ b/aerospike-mixin/main.libsonnet @@ -0,0 +1,47 @@ +local alerts = import './alerts.libsonnet'; +local config = import './config.libsonnet'; +local dashboards = import './dashboards.libsonnet'; +local links = import './links.libsonnet'; +local panels = import './panels.libsonnet'; +local rows = import './rows.libsonnet'; +local commonlib = import 'common-lib/common/main.libsonnet'; + +{ + withConfigMixin(config): { + config+: config, + }, + + new(): { + local this = self, + config: config, + signals: + { + [sig]: commonlib.signals.unmarshallJsonMulti( + this.config.signals[sig], + type=this.config.metricsSource + ) + for sig in std.objectFields(this.config.signals) + }, + + grafana: { + variables: commonlib.variables.new( + filteringSelector=this.config.filteringSelector, + groupLabels=this.config.groupLabels, + instanceLabels=this.config.instanceLabels, + varMetric='aerospike_namespace_data_used_pct', + customAllValue='.+', + enableLokiLogs=this.config.enableLokiLogs, + ), + annotations: {}, + links: links.new(this), + panels: panels.new(this), + dashboards: dashboards.new(this), + rows: rows.new(this), + }, + + prometheus: { + alerts: alerts.new(this), + recordingRules: {}, + }, + }, +} diff --git a/aerospike-mixin/mixin.libsonnet b/aerospike-mixin/mixin.libsonnet index 4d987cf31..270fa3835 100644 --- a/aerospike-mixin/mixin.libsonnet +++ b/aerospike-mixin/mixin.libsonnet @@ -1,3 +1,39 @@ -(import 'dashboards/dashboards.libsonnet') + -(import 'alerts/alerts.libsonnet') + -(import 'config.libsonnet') +local mixinlib = import './main.libsonnet'; +local config = (import './config.libsonnet'); +local util = import 'grafana-cloud-integration-utils/util.libsonnet'; + +local mixin = + mixinlib.new() + + mixinlib.withConfigMixin( + { + filteringSelector: config.filteringSelector, + uid: 'aerospike', + enableLokiLogs: true, + } + ); + +local k8s_patch = { + aerospike_cluster+: { + label: 'Aerospike cluster', + }, + cluster+: { + allValue: '.*', + }, + ns+: { + allValue: '.*', + label: 'Namespace', + }, +}; + +{ + grafanaDashboards+:: { + local tags = config.dashboardTags, + [fname]: + local dashboard = util.decorate_dashboard(mixin.grafana.dashboards[fname], tags=tags); + dashboard + util.patch_variables(dashboard, k8s_patch) + + for fname in std.objectFields(mixin.grafana.dashboards) + }, + prometheusAlerts+:: mixin.prometheus.alerts, + prometheusRules+:: mixin.prometheus.recordingRules, +} diff --git a/aerospike-mixin/panels.libsonnet b/aerospike-mixin/panels.libsonnet new file mode 100644 index 000000000..b0bd59ad4 --- /dev/null +++ b/aerospike-mixin/panels.libsonnet @@ -0,0 +1,527 @@ +local g = import './g.libsonnet'; +local commonlib = import 'common-lib/common/main.libsonnet'; + +{ + new(this):: + { + local signals = this.signals, + + // ========================== + // Overview Dashboard + // ========================== + + nodesPanel: + commonlib.panels.generic.table.base.new( + 'Nodes', + targets=[ + signals.overview.nodesClusterSize.asTableTarget() + + g.query.prometheus.withLegendFormat(''), // Clear legend format for table + ], + description='Number of nodes in an Aerospike cluster.' + ) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Value') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Time') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('instance') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Instance') + + g.panel.table.fieldOverride.byName.withProperty('custom.filterable', true) + + g.panel.table.fieldOverride.byName.withProperty('links', [ + { + title: 'Instance overview', + url: '/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}', + }, + ]), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('aerospike_cluster') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Aerospike cluster'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('job') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.options.withCellHeight('md') + + g.panel.table.options.footer.withCountRows(false) + + g.panel.table.options.footer.withFields([]) + + g.panel.table.options.footer.withReducer(['sum']) + + g.panel.table.options.footer.withShow(false) + + g.panel.table.options.withShowHeader(true) + + g.panel.table.queryOptions.withTransformations([ + { + id: 'sortBy', + options: { + fields: {}, + sort: [ + { + desc: true, + field: 'Time', + }, + ], + }, + }, + ]), + + namespacesPanel: + commonlib.panels.generic.table.base.new( + 'Namespaces', + targets=[ + signals.overview.namespacesClusterSize.asTableTarget() + + g.query.prometheus.withLegendFormat(''), // Clear legend format for table + ], + description='Number of namespaces in an Aerospike cluster.' + ) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Value') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Time') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('aerospike_cluster') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Aerospike cluster'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('instance') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Instance') + + g.panel.table.fieldOverride.byName.withProperty('links', [ + { + title: 'Instance overview', + url: '/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}', + }, + ]), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('ns') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Namespace') + + g.panel.table.fieldOverride.byName.withProperty('links', [ + { + title: 'Namespace overview', + url: '/d/aerospike_namespace_overview?var-ns=${__data.fields.ns}&${__url_time_range}&var-datasource=${datasource}', + }, + ]), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('job') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]), + + unavailablePartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Unavailable partitions', + targets=[signals.overview.unavailablePartitions.asTarget()], + description='Number of unavailable partitions in Aerospike namespaces' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + deadPartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Dead partitions', + targets=[signals.overview.deadPartitions.asTarget()], + description='Number of dead partitions in Aerospike namespaces' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + topNodesByMemoryUsagePanel: + commonlib.panels.generic.table.base.new( + 'Top nodes by memory usage', + targets=[ + signals.overview.topNodesByMemoryUsage.asTableTarget() { interval: '1m' } + + g.query.prometheus.withLegendFormat(''), // Clear legend format for table + ], + description='Memory utilization for the top k nodes in an Aerospike cluster.' + ) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Value') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Usage') + + g.panel.table.fieldOverride.byName.withProperty('unit', 'percent'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Time') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('aerospike_cluster') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Aerospike cluster'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('instance') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Instance') + + g.panel.table.fieldOverride.byName.withProperty('links', [ + { + title: 'Instance overview', + url: '/d/aerospike_instance_overview?var-instance=${__data.fields.Instance}&${__url_time_range}&var-datasource=${datasource}', + }, + ]), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('job') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]), + + topNodesByDiskUsagePanel: + commonlib.panels.generic.table.base.new( + 'Top nodes by disk usage', + targets=[ + signals.overview.topNodesByDiskUsage.asTableTarget() { interval: '1m' } + + g.query.prometheus.withLegendFormat(''), // Clear legend format for table + ], + description='Disk utilization for the top k nodes in an Aerospike cluster. Compatible with Aerospike versions < 7.0 using legacy metrics.' + ) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Value') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Usage') + + g.panel.table.fieldOverride.byName.withProperty('unit', 'percent'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('Time') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('aerospike_cluster') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Aerospike cluster'), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('instance') + + g.panel.table.fieldOverride.byName.withProperty('displayName', 'Instance') + + g.panel.table.fieldOverride.byName.withProperty('links', [ + { + title: 'Instance overview', + url: '/d/aerospike_instance_overview?var-instance=${__data.fields.instance}&${__url_time_range}&var-datasource=${datasource}', + }, + ]), + ]) + + g.panel.table.standardOptions.withOverridesMixin([ + g.panel.table.fieldOverride.byName.new('job') + + g.panel.table.fieldOverride.byName.withProperty('custom.hidden', true), + ]), + + readTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client reads', + targets=[ + signals.overview.clientReadSuccess.asTarget() { interval: '1m' }, + signals.overview.clientReadError.asTarget() { interval: '1m' }, + signals.overview.clientReadTimeout.asTarget() { interval: '1m' }, + signals.overview.clientReadNotFound.asTarget() { interval: '1m' }, + signals.overview.clientReadFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client read transactions in an Aerospike cluster organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + writeTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client writes', + targets=[ + signals.overview.clientWriteSuccess.asTarget() { interval: '1m' }, + signals.overview.clientWriteError.asTarget() { interval: '1m' }, + signals.overview.clientWriteTimeout.asTarget() { interval: '1m' }, + signals.overview.clientWriteFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client write transactions in an Aerospike cluster organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + udfTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client UDF transactions', + targets=[ + signals.overview.clientUdfComplete.asTarget() { interval: '1m' }, + signals.overview.clientUdfError.asTarget() { interval: '1m' }, + signals.overview.clientUdfTimeout.asTarget() { interval: '1m' }, + signals.overview.clientUdfFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client UDF transactions in an Aerospike cluster organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + clientConnectionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Connections', + targets=[ + signals.overview.clientConnections.asTarget() { interval: '1m' }, + signals.overview.fabricConnections.asTarget() { interval: '1m' }, + signals.overview.heartbeatConnections.asTarget() { interval: '1m' }, + ], + description='Number of active connections to an Aerospike cluster.' + ) + + g.panel.timeSeries.standardOptions.withUnit('short') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + // ========================== + // Instance Dashboard + // ========================== + + instanceUnavailablePartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Unavailable partitions', + targets=[signals.instance.unavailablePartitions.asTarget()], + description='Number of unavailable partitions in this Aerospike instance' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + nodeMemoryUsagePanel: + commonlib.panels.generic.timeSeries.base.new( + 'Memory usage', + targets=[signals.instance.nodeMemoryUsage.asTarget()], + description='Memory utilization in an Aerospike node.' + ) + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(75) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + instanceDeadPartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Dead partitions', + targets=[signals.instance.deadPartitions.asTarget()], + description='Number of dead partitions in this Aerospike instance' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + instanceDiskUsagePanel: + commonlib.panels.generic.timeSeries.base.new( + 'Disk usage (%)', + targets=[signals.instance.diskUsage.asTarget()], + description='Disk utilization per namespace on an Aerospike node. Compatible with Aerospike versions < 7.0 using legacy metrics.' + ) + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + heapMemoryEfficiencyPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Heap memory efficiency', + targets=[signals.instance.heapMemoryEfficiency.asTarget()], + description='Fragmentation rate for the jemalloc heap in an Aerospike node.' + ) + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(75) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + instanceClientConnectionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Connections', + targets=[ + signals.instance.clientConnections.asTarget() { interval: '1m' }, + signals.instance.fabricConnections.asTarget() { interval: '1m' }, + signals.instance.heartbeatConnections.asTarget() { interval: '1m' }, + ], + description='Number of active connections to this Aerospike instance.' + ) + + g.panel.timeSeries.standardOptions.withUnit('short') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(75) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + instanceReadTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client reads', + targets=[ + signals.instance.clientReadSuccess.asTarget() { interval: '1m' }, + signals.instance.clientReadError.asTarget() { interval: '1m' }, + signals.instance.clientReadTimeout.asTarget() { interval: '1m' }, + signals.instance.clientReadNotFound.asTarget() { interval: '1m' }, + signals.instance.clientReadFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client read transactions in this Aerospike instance organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + instanceWriteTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client writes', + targets=[ + signals.instance.clientWriteSuccess.asTarget() { interval: '1m' }, + signals.instance.clientWriteError.asTarget() { interval: '1m' }, + signals.instance.clientWriteTimeout.asTarget() { interval: '1m' }, + signals.instance.clientWriteFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client write transactions in this Aerospike instance organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + instanceUdfTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client UDF transactions', + targets=[ + signals.instance.clientUdfComplete.asTarget() { interval: '1m' }, + signals.instance.clientUdfError.asTarget() { interval: '1m' }, + signals.instance.clientUdfTimeout.asTarget() { interval: '1m' }, + signals.instance.clientUdfFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client UDF transactions in this Aerospike instance organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + cacheReadUtilizationPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Cache read utilization', + targets=[signals.namespace.cacheReadUtilization.asTarget()], + description='Percentage of read transactions that are resolved by a cache hit.' + ) + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + // ========================== + // Namespace Dashboard + // ========================== + + namespaceUnavailablePartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Unavailable partitions', + targets=[signals.namespace.unavailablePartitions.asTarget()], + description='Number of unavailable partitions in this Aerospike namespace' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + namespaceDiskUsagePanel: + g.panel.timeSeries.new('Disk usage') + + signals.namespace.namespaceDiskUsage.asPanelMixin() + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + namespaceDeadPartitionsPanel: + commonlib.panels.generic.stat.info.new( + 'Dead partitions', + targets=[signals.namespace.deadPartitions.asTarget()], + description='Number of dead partitions in this Aerospike namespace' + ) + + g.panel.stat.standardOptions.withUnit('short') + + { type: 'bargauge' } + + g.panel.barGauge.standardOptions.color.withMode('fixed') + + g.panel.barGauge.standardOptions.color.withFixedColor('green'), + + namespaceMemoryUsagePanel: + g.panel.timeSeries.new('Memory usage') + + g.panel.timeSeries.panelOptions.withDescription('Memory utilization in an Aerospike namespace') + + signals.namespace.namespaceMemoryUsage.asPanelMixin() + + g.panel.timeSeries.standardOptions.withUnit('percent') + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + namespaceReadTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client reads', + targets=[ + signals.namespace.readTransactionSuccess.asTarget() { interval: '1m' }, + signals.namespace.readTransactionError.asTarget() { interval: '1m' }, + signals.namespace.readTransactionTimeout.asTarget() { interval: '1m' }, + signals.namespace.readTransactionNotFound.asTarget() { interval: '1m' }, + signals.namespace.readTransactionFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client read transactions in this Aerospike namespace organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + namespaceWriteTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client writes', + targets=[ + signals.namespace.writeTransactionSuccess.asTarget() { interval: '1m' }, + signals.namespace.writeTransactionError.asTarget() { interval: '1m' }, + signals.namespace.writeTransactionTimeout.asTarget() { interval: '1m' }, + signals.namespace.writeTransactionFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client write transactions in this Aerospike namespace organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + + namespaceUdfTransactionsPanel: + commonlib.panels.generic.timeSeries.base.new( + 'Client UDF transactions', + targets=[ + signals.namespace.udfTransactionComplete.asTarget() { interval: '1m' }, + signals.namespace.udfTransactionError.asTarget() { interval: '1m' }, + signals.namespace.udfTransactionTimeout.asTarget() { interval: '1m' }, + signals.namespace.udfTransactionFiltered.asTarget() { interval: '1m' }, + ], + description='Rate of client UDF transactions in this Aerospike namespace organized by result.' + ) + + g.panel.timeSeries.standardOptions.withUnit('reqps') + + g.panel.timeSeries.options.legend.withAsTable(true) + + g.panel.timeSeries.options.legend.withDisplayMode('table') + + g.panel.timeSeries.options.legend.withPlacement('right') + + g.panel.timeSeries.options.legend.withCalcs(['min', 'mean', 'max']) + + g.panel.timeSeries.fieldConfig.defaults.custom.withFillOpacity(0) + + g.panel.timeSeries.fieldConfig.defaults.custom.withSpanNulls(false), + }, +} diff --git a/aerospike-mixin/prometheus_rules_out/prometheus_alerts.yaml b/aerospike-mixin/prometheus_rules_out/prometheus_alerts.yaml index 54573f5c0..cb95179f6 100644 --- a/aerospike-mixin/prometheus_rules_out/prometheus_alerts.yaml +++ b/aerospike-mixin/prometheus_rules_out/prometheus_alerts.yaml @@ -1,5 +1,5 @@ groups: - - name: aerospike + - name: aerospike.rules rules: - alert: AerospikeNodeHighMemoryUsage annotations: @@ -51,7 +51,7 @@ groups: description: '{{ printf "%.0f" $value }} percent of client read transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, which is above the threshold of 25.' summary: There is a high rate of errors for client read transactions. expr: | - sum without(service) (rate(aerospike_namespace_client_read_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_read_error[5m])) + sum without(service) (rate(aerospike_namespace_client_read_success[5m])), 1)) > 25 + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_read_success[5m])), 1)) > 25 for: 5m labels: severity: warning @@ -60,7 +60,7 @@ groups: description: '{{ printf "%.0f" $value }} percent of client write transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, which is above the threshold of 25.' summary: There is a high rate of errors for client write transactions. expr: | - sum without(service) (rate(aerospike_namespace_client_write_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_write_error[5m])) + sum without(service) (rate(aerospike_namespace_client_write_success[5m])), 1)) > 25 + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_write_success[5m])), 1)) > 25 for: 5m labels: severity: warning @@ -69,7 +69,7 @@ groups: description: '{{ printf "%.0f" $value }} percent of client UDF transactions are resulting in errors for namespace {{$labels.ns}}, on node {{$labels.instance}}, on cluster {{$labels.aerospike_cluster}}, which is above the threshold of 25.' summary: There is a high rate of errors for client UDF transactions. expr: | - sum without(service) (rate(aerospike_namespace_client_udf_error[5m])) / (clamp_min(sum without(service) (rate(aerospike_namespace_client_udf_error[5m])) + sum without(service) (rate(aerospike_namespace_client_udf_complete[5m])), 1)) > 25 + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_error[5m])) / (clamp_min(sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_error[5m])) + sum by(instance, aerospike_cluster, ns) (rate(aerospike_namespace_client_udf_complete[5m])), 1)) > 25 for: 5m labels: severity: warning diff --git a/aerospike-mixin/rows.libsonnet b/aerospike-mixin/rows.libsonnet new file mode 100644 index 000000000..ff34446b0 --- /dev/null +++ b/aerospike-mixin/rows.libsonnet @@ -0,0 +1,57 @@ +local g = import './g.libsonnet'; + +{ + new(this): + { + local panels = this.grafana.panels, + + // Overview + clusterOverview: + g.panel.row.new('Overview') + + g.panel.row.withCollapsed(false) + + g.panel.row.withPanels([ + panels.nodesPanel + g.panel.table.gridPos.withW(6), + panels.namespacesPanel + g.panel.table.gridPos.withW(6), + panels.unavailablePartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.deadPartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.topNodesByMemoryUsagePanel + g.panel.table.gridPos.withW(12), + panels.topNodesByDiskUsagePanel + g.panel.table.gridPos.withW(12), + panels.readTransactionsPanel + g.panel.stat.gridPos.withW(12), + panels.writeTransactionsPanel + g.panel.stat.gridPos.withW(12), + panels.udfTransactionsPanel + g.panel.stat.gridPos.withW(12), + panels.clientConnectionsPanel + g.panel.stat.gridPos.withW(12), + ]), + + // Instance overview + instanceOverview: + g.panel.row.new('Instance') + + g.panel.row.withCollapsed(false) + + g.panel.row.withPanels([ + panels.instanceUnavailablePartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.nodeMemoryUsagePanel + g.panel.timeSeries.gridPos.withW(18), + panels.instanceDeadPartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.instanceDiskUsagePanel + g.panel.timeSeries.gridPos.withW(18), + panels.heapMemoryEfficiencyPanel + g.panel.timeSeries.gridPos.withW(12), + panels.instanceClientConnectionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.instanceReadTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.instanceWriteTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.instanceUdfTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.cacheReadUtilizationPanel + g.panel.timeSeries.gridPos.withW(12), + ]), + + // Namespace overview + namespaceOverview: + g.panel.row.new('Namespace') + + g.panel.row.withCollapsed(false) + + g.panel.row.withPanels([ + panels.namespaceUnavailablePartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.namespaceDiskUsagePanel + g.panel.timeSeries.gridPos.withW(18), + panels.namespaceDeadPartitionsPanel + g.panel.stat.gridPos.withW(6), + panels.namespaceMemoryUsagePanel + g.panel.timeSeries.gridPos.withW(18), + panels.namespaceReadTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.namespaceWriteTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.namespaceUdfTransactionsPanel + g.panel.timeSeries.gridPos.withW(12), + panels.cacheReadUtilizationPanel + g.panel.timeSeries.gridPos.withW(12), + ]), + }, +} diff --git a/aerospike-mixin/signals/instance.libsonnet b/aerospike-mixin/signals/instance.libsonnet new file mode 100644 index 000000000..c227cc201 --- /dev/null +++ b/aerospike-mixin/signals/instance.libsonnet @@ -0,0 +1,307 @@ +local commonlib = import 'common-lib/common/main.libsonnet'; + +function(this) + local groupAggListWithInstance = std.join(',', this.groupLabels) + (if std.length(this.instanceLabels) > 0 then ',' + std.join(',', this.instanceLabels) else ''); + { + filteringSelector: this.filteringSelector, + groupLabels: this.groupLabels, + instanceLabels: this.instanceLabels, + enableLokiLogs: this.enableLokiLogs, + legendCustomTemplate: std.join(' ', std.map(function(label) '{{' + label + '}}', this.instanceLabels)), + aggLevel: 'none', + aggFunction: 'avg', + alertsInterval: '2m', + discoveryMetric: { + prometheus: 'aerospike_node_up', + }, + signals: { + nodeMemoryUsage: { + name: 'Node memory usage', + nameShort: 'Memory', + type: 'gauge', + description: 'Memory usage percentage on Aerospike nodes.', + unit: 'percent', + sources: { + prometheus: { + expr: '100 - aerospike_node_stats_system_free_mem_pct{%(queriesSelector)s}', + }, + }, + }, + + clientConnections: { + name: 'Client connections', + nameShort: 'Client conn', + type: 'gauge', + description: 'Number of client connections to Aerospike nodes.', + unit: 'short', + sources: { + prometheus: { + expr: 'aerospike_node_stats_client_connections{%(queriesSelector)s}', + }, + }, + }, + + fabricConnections: { + name: 'Fabric connections', + nameShort: 'Fabric conn', + type: 'gauge', + description: 'Number of fabric connections between Aerospike nodes.', + unit: 'short', + sources: { + prometheus: { + expr: 'aerospike_node_stats_fabric_connections{%(queriesSelector)s}', + }, + }, + }, + + heartbeatConnections: { + name: 'Heartbeat connections', + nameShort: 'Heartbeat conn', + type: 'gauge', + description: 'Number of heartbeat connections between Aerospike nodes.', + unit: 'short', + sources: { + prometheus: { + expr: 'aerospike_node_stats_heartbeat_connections{%(queriesSelector)s}', + }, + }, + }, + + heapMemoryEfficiency: { + name: 'Heap memory efficiency', + nameShort: 'Heap efficiency', + type: 'gauge', + description: 'Fragmentation rate for the jemalloc heap in Aerospike nodes.', + unit: 'percent', + sources: { + prometheus: { + expr: 'aerospike_node_stats_heap_efficiency_pct{%(queriesSelector)s}', + }, + }, + }, + + unavailablePartitions: { + name: 'Unavailable partitions', + nameShort: 'Unavailable', + type: 'gauge', + description: 'Number of unavailable partitions in Aerospike instance.', + unit: 'short', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (aerospike_namespace_unavailable_partitions{%(queriesSelector)s})', + }, + }, + }, + + deadPartitions: { + name: 'Dead partitions', + nameShort: 'Dead', + type: 'gauge', + description: 'Number of dead partitions in Aerospike instance.', + unit: 'short', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (aerospike_namespace_dead_partitions{%(queriesSelector)s})', + }, + }, + }, + + clientReadSuccess: { + name: 'Client read success rate', + nameShort: 'Read success', + type: 'raw', + description: 'Rate of successful client read transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_read_success{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - success', + }, + }, + }, + + clientReadError: { + name: 'Client read error rate', + nameShort: 'Read error', + type: 'raw', + description: 'Rate of client read transaction errors.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_read_error{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - error', + }, + }, + }, + + clientReadTimeout: { + name: 'Client read timeout rate', + nameShort: 'Read timeout', + type: 'raw', + description: 'Rate of client read transaction timeouts.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_read_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - timeout', + }, + }, + }, + + clientReadNotFound: { + name: 'Client read not found rate', + nameShort: 'Read not found', + type: 'raw', + description: 'Rate of client read transactions returning not found.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_read_not_found{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - not found', + }, + }, + }, + + clientReadFiltered: { + name: 'Client read filtered rate', + nameShort: 'Read filtered', + type: 'raw', + description: 'Rate of filtered client read transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_read_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - filtered', + }, + }, + }, + + clientWriteSuccess: { + name: 'Client write success rate', + nameShort: 'Write success', + type: 'raw', + description: 'Rate of successful client write transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_write_success{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - success', + }, + }, + }, + + clientWriteError: { + name: 'Client write error rate', + nameShort: 'Write error', + type: 'raw', + description: 'Rate of client write transaction errors.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_write_error{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - error', + }, + }, + }, + + clientWriteTimeout: { + name: 'Client write timeout rate', + nameShort: 'Write timeout', + type: 'raw', + description: 'Rate of client write transaction timeouts.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_write_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - timeout', + }, + }, + }, + + clientWriteFiltered: { + name: 'Client write filtered rate', + nameShort: 'Write filtered', + type: 'raw', + description: 'Rate of filtered client write transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_write_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - filtered', + }, + }, + }, + + clientUdfComplete: { + name: 'Client UDF complete rate', + nameShort: 'UDF complete', + type: 'raw', + description: 'Rate of completed client UDF transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_udf_complete{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - complete', + }, + }, + }, + + clientUdfError: { + name: 'Client UDF error rate', + nameShort: 'UDF error', + type: 'raw', + description: 'Rate of client UDF transaction errors.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_udf_error{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - error', + }, + }, + }, + + clientUdfTimeout: { + name: 'Client UDF timeout rate', + nameShort: 'UDF timeout', + type: 'raw', + description: 'Rate of client UDF transaction timeouts.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_udf_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - timeout', + }, + }, + }, + + clientUdfFiltered: { + name: 'Client UDF filtered rate', + nameShort: 'UDF filtered', + type: 'raw', + description: 'Rate of filtered client UDF transactions.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'sum by(' + std.join(',', this.instanceLabels) + ') (rate(aerospike_namespace_client_udf_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{ instance }} - filtered', + }, + }, + }, + + diskUsage: { + name: 'Disk usage', + nameShort: 'Disk usage', + type: 'raw', + description: 'Disk utilization in an Aerospike node.', + unit: 'percent', + sources: { + prometheus: { + expr: '100 - sum by (' + groupAggListWithInstance + ') (aerospike_namespace_device_free_pct{%(queriesSelector)s})', + }, + prometheusAerospike7: { + expr: 'sum by (' + groupAggListWithInstance + ') (aerospike_namespace_data_used_pct{%(queriesSelector)s, storage_engine="device"})', + }, + }, + }, + }, + } diff --git a/aerospike-mixin/signals/namespace.libsonnet b/aerospike-mixin/signals/namespace.libsonnet new file mode 100644 index 000000000..54be00302 --- /dev/null +++ b/aerospike-mixin/signals/namespace.libsonnet @@ -0,0 +1,285 @@ +local commonlib = import 'common-lib/common/main.libsonnet'; + +function(this) + { + filteringSelector: this.filteringSelector, + groupLabels: this.groupLabels, + instanceLabels: this.instanceLabels, + enableLokiLogs: this.enableLokiLogs, + legendCustomTemplate: std.join(' ', std.map(function(label) '{{' + label + '}}', this.instanceLabels)) + ' - {{ns}}', + aggLevel: 'none', + aggFunction: 'avg', + alertsInterval: '2m', + discoveryMetric: { + prometheus: 'aerospike_namespace_ns_cluster_size', + }, + signals: { + namespaceDiskUsage: { + name: 'Namespace disk usage', + nameShort: 'Disk usage', + type: 'gauge', + description: 'Disk usage percentage for Aerospike namespaces. Supports both legacy (device_free_pct) and modern (data_used_pct) metrics.', + unit: 'percent', + sources: { + prometheus: { + expr: '100 - aerospike_namespace_device_free_pct{%(queriesSelector)s}', + }, + prometheusAerospike7: { + expr: 'aerospike_namespace_data_used_pct{%(queriesSelector)s, storage_engine="device"}', + }, + }, + }, + + namespaceMemoryUsage: { + name: 'Namespace memory usage', + nameShort: 'Memory usage', + type: 'gauge', + description: 'Memory usage percentage for Aerospike namespaces.', + unit: 'percent', + sources: { + prometheus: { + expr: '100 - aerospike_namespace_memory_free_pct{%(queriesSelector)s}', + }, + prometheusAerospike7: { + expr: 'aerospike_namespace_data_used_pct{%(queriesSelector)s, storage_engine="memory"}', + }, + }, + }, + + + unavailablePartitions: { + name: 'Unavailable partitions', + nameShort: 'Unavailable', + type: 'gauge', + description: 'Number of unavailable partitions in Aerospike namespaces.', + unit: 'short', + sources: { + prometheus: { + expr: 'aerospike_namespace_unavailable_partitions{%(queriesSelector)s}', + }, + }, + }, + + deadPartitions: { + name: 'Dead partitions', + nameShort: 'Dead', + type: 'gauge', + description: 'Number of dead partitions in Aerospike namespaces.', + unit: 'short', + sources: { + prometheus: { + expr: 'aerospike_namespace_dead_partitions{%(queriesSelector)s}', + }, + }, + }, + + cacheReadUtilization: { + name: 'Cache read utilization', + nameShort: 'Cache hits', + type: 'gauge', + description: 'Percentage of read transactions that are resolved by a cache hit.', + unit: 'percent', + sources: { + prometheus: { + expr: 'aerospike_namespace_cache_read_pct{%(queriesSelector)s}', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }}', + }, + }, + }, + + readTransactionSuccess: { + name: 'Read transaction success rate', + nameShort: 'Read success', + type: 'counter', + description: 'Rate of successful read transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_read_success{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - success', + }, + }, + }, + + readTransactionError: { + name: 'Read transaction error rate', + nameShort: 'Read errors', + type: 'counter', + description: 'Rate of failed read transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_read_error{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - error', + }, + }, + }, + + readTransactionTimeout: { + name: 'Read transaction timeout rate', + nameShort: 'Read timeouts', + type: 'counter', + description: 'Rate of read transaction timeouts per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_read_timeout{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - timeout', + }, + }, + }, + + readTransactionNotFound: { + name: 'Read transaction not found rate', + nameShort: 'Read not found', + type: 'counter', + description: 'Rate of read transactions returning not found per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_read_not_found{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - not found', + }, + }, + }, + + readTransactionFiltered: { + name: 'Read transaction filtered rate', + nameShort: 'Read filtered', + type: 'counter', + description: 'Rate of filtered read transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_read_filtered_out{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - filtered', + }, + }, + }, + + writeTransactionSuccess: { + name: 'Write transaction success rate', + nameShort: 'Write success', + type: 'counter', + description: 'Rate of successful write transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_write_success{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - success', + }, + }, + }, + + writeTransactionError: { + name: 'Write transaction error rate', + nameShort: 'Write errors', + type: 'counter', + description: 'Rate of failed write transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_write_error{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - error', + }, + }, + }, + + writeTransactionTimeout: { + name: 'Write transaction timeout rate', + nameShort: 'Write timeouts', + type: 'counter', + description: 'Rate of write transaction timeouts per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_write_timeout{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - timeout', + }, + }, + }, + + writeTransactionFiltered: { + name: 'Write transaction filtered rate', + nameShort: 'Write filtered', + type: 'counter', + description: 'Rate of filtered write transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_write_filtered_out{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - filtered', + }, + }, + }, + + udfTransactionComplete: { + name: 'UDF transaction complete rate', + nameShort: 'UDF complete', + type: 'counter', + description: 'Rate of completed UDF transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_udf_complete{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - complete', + }, + }, + }, + + udfTransactionError: { + name: 'UDF transaction error rate', + nameShort: 'UDF errors', + type: 'counter', + description: 'Rate of failed UDF transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_udf_error{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - error', + }, + }, + }, + + udfTransactionTimeout: { + name: 'UDF transaction timeout rate', + nameShort: 'UDF timeouts', + type: 'counter', + description: 'Rate of UDF transaction timeouts per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_udf_timeout{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - timeout', + }, + }, + }, + + udfTransactionFiltered: { + name: 'UDF transaction filtered rate', + nameShort: 'UDF filtered', + type: 'counter', + description: 'Rate of filtered UDF transactions per namespace.', + unit: 'reqps', + sources: { + prometheus: { + expr: 'aerospike_namespace_client_udf_filtered_out{%(queriesSelector)s}', + rangeFunction: 'rate', + legendCustomTemplate: '{{ aerospike_cluster }} - {{ ns }} - filtered', + }, + }, + }, + }, + } diff --git a/aerospike-mixin/signals/overview.libsonnet b/aerospike-mixin/signals/overview.libsonnet new file mode 100644 index 000000000..dc729a785 --- /dev/null +++ b/aerospike-mixin/signals/overview.libsonnet @@ -0,0 +1,332 @@ +local commonlib = import 'common-lib/common/main.libsonnet'; + +function(this) + local groupAggListWithoutInstance = std.join(',', this.groupLabels); + local groupAggListWithInstance = groupAggListWithoutInstance + ', ' + std.join(',', this.instanceLabels); + { + filteringSelector: this.filteringSelector, + groupLabels: this.groupLabels, + instanceLabels: this.instanceLabels, + enableLokiLogs: this.enableLokiLogs, + legendCustomTemplate: std.join(' ', std.map(function(label) '{{' + label + '}}', this.instanceLabels)) + ' - {{aerospike_cluster}}', + aggLevel: 'none', + aggFunction: 'avg', + alertsInterval: '2m', + discoveryMetric: { + prometheus: 'aerospike_namespace_ns_cluster_size', + }, + signals: { + nodesClusterSize: { + name: 'Nodes cluster size', + nameShort: 'Nodes', + type: 'raw', + description: 'Number of nodes in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithInstance + ') (aerospike_namespace_ns_cluster_size{%(queriesSelector)s})', + legendCustomTemplate: '{{instance}}', + }, + }, + }, + + namespacesClusterSize: { + name: 'Namespaces cluster size', + nameShort: 'Namespaces', + type: 'raw', + description: 'Number of namespaces in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithInstance + ') (aerospike_namespace_ns_cluster_size{%(queriesSelector)s})', + legendCustomTemplate: '{{ns}}', + }, + }, + }, + + unavailablePartitions: { + name: 'Unavailable partitions', + nameShort: 'Unavailable', + type: 'gauge', + description: 'Number of unavailable data partitions in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (aerospike_namespace_unavailable_partitions{%(queriesSelector)s})', + legendCustomTemplate: '{{aerospike_cluster}}', + }, + }, + }, + + deadPartitions: { + name: 'Dead partitions', + nameShort: 'Dead', + type: 'gauge', + description: 'Number of dead data partitions in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (aerospike_namespace_dead_partitions{%(queriesSelector)s})', + legendCustomTemplate: '{{aerospike_cluster}}', + }, + }, + }, + + topNodesByMemoryUsage: { + name: 'Top nodes by memory usage', + nameShort: 'Top memory', + type: 'gauge', + description: 'Memory utilization for the top k nodes in an Aerospike cluster.', + unit: 'percent', + sources: { + prometheus: { + expr: 'topk($k, 100 - sum by(' + groupAggListWithInstance + ') (avg_over_time(aerospike_node_stats_system_free_mem_pct{%(queriesSelector)s}[$__interval])))', + legendCustomTemplate: '{{instance}}', + }, + }, + }, + + topNodesByDiskUsage: { + name: 'Top nodes by disk usage', + nameShort: 'Top disk', + type: 'gauge', + description: 'Disk utilization for the top k nodes in an Aerospike cluster. Note: This uses legacy device_free_pct metric which may not be available in Aerospike 7.0+.', + unit: 'percent', + sources: { + prometheus: { + expr: 'topk($k, 100 - sum by(' + groupAggListWithInstance + ') (avg_over_time(aerospike_namespace_device_free_pct{%(queriesSelector)s}[$__interval])))', + legendCustomTemplate: '{{instance}}', + }, + prometheusAerospike7: { + expr: 'topk($k, 100 - sum by(' + groupAggListWithInstance + ') (avg_over_time(aerospike_namespace_data_used_pct{%(queriesSelector)s}[$__interval])))', + legendCustomTemplate: '{{instance}}', + }, + }, + }, + + clientReadSuccess: { + name: 'Client read success rate', + nameShort: 'Read success', + type: 'raw', + description: 'Rate of successful client read transactions.', + unit: 'rps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_read_success{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - success', + }, + }, + }, + + clientReadError: { + name: 'Client read error rate', + nameShort: 'Read error', + type: 'raw', + description: 'Rate of failed client read transactions.', + unit: 'rps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_read_error{%(queriesSelector)s}[$__rate_interval]))', + rangeFunction: 'rate', + legendCustomTemplate: '{{aerospike_cluster}} - error', + }, + }, + }, + + clientReadFiltered: { + name: 'Client read filtered rate', + nameShort: 'Read filtered', + type: 'raw', + description: 'Rate of filtered client read transactions.', + unit: 'rps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_read_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - filtered', + }, + }, + }, + + clientReadTimeout: { + name: 'Client read timeout rate', + nameShort: 'Read timeout', + type: 'raw', + description: 'Rate of client read transaction timeouts.', + unit: 'rps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_read_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - timeout', + }, + }, + }, + + clientReadNotFound: { + name: 'Client read not found rate', + nameShort: 'Read not found', + type: 'raw', + description: 'Rate of client read transactions returning not found.', + unit: 'rps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_read_not_found{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - not found', + }, + }, + }, + + clientWriteSuccess: { + name: 'Client write success rate', + nameShort: 'Write success', + type: 'raw', + description: 'Rate of successful client write transactions.', + unit: 'wps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_write_success{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - success', + }, + }, + }, + + clientWriteError: { + name: 'Client write error rate', + nameShort: 'Write error', + type: 'raw', + description: 'Rate of failed client write transactions.', + unit: 'wps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_write_error{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - error', + }, + }, + }, + + clientWriteFiltered: { + name: 'Client write filtered rate', + nameShort: 'Write filtered', + type: 'raw', + description: 'Rate of filtered client write transactions.', + unit: 'wps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_write_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - filtered', + }, + }, + }, + + clientWriteTimeout: { + name: 'Client write timeout rate', + nameShort: 'Write timeout', + type: 'raw', + description: 'Rate of client write transaction timeouts.', + unit: 'wps', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_write_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - timeout', + }, + }, + }, + + clientUdfComplete: { + name: 'Client UDF complete rate', + nameShort: 'UDF complete', + type: 'raw', + description: 'Rate of completed client UDF transactions.', + unit: 'ops', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_udf_complete{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - complete', + }, + }, + }, + + clientUdfError: { + name: 'Client UDF error rate', + nameShort: 'UDF error', + type: 'raw', + description: 'Rate of failed client UDF transactions.', + unit: 'ops', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_udf_error{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - error', + }, + }, + }, + + clientUdfFiltered: { + name: 'Client UDF filtered rate', + nameShort: 'UDF filtered', + type: 'raw', + description: 'Rate of filtered client UDF transactions.', + unit: 'ops', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_udf_filtered_out{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - filtered', + }, + }, + }, + + clientUdfTimeout: { + name: 'Client UDF timeout rate', + nameShort: 'UDF timeout', + type: 'raw', + description: 'Rate of client UDF transaction timeouts.', + unit: 'ops', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (rate(aerospike_namespace_client_udf_timeout{%(queriesSelector)s}[$__rate_interval]))', + legendCustomTemplate: '{{aerospike_cluster}} - timeout', + }, + }, + }, + + clientConnections: { + name: 'Client connections', + nameShort: 'Client conn', + type: 'raw', + description: 'Number of client connections to an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (aerospike_node_stats_client_connections{%(queriesSelector)s})', + legendCustomTemplate: '{{aerospike_cluster}} - client', + }, + }, + }, + + fabricConnections: { + name: 'Fabric connections', + nameShort: 'Fabric conn', + type: 'raw', + description: 'Number of fabric connections in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (aerospike_node_stats_fabric_connections{%(queriesSelector)s})', + legendCustomTemplate: '{{aerospike_cluster}} - fabric', + }, + }, + }, + + heartbeatConnections: { + name: 'Heartbeat connections', + nameShort: 'Heartbeat conn', + type: 'raw', + description: 'Number of heartbeat connections in an Aerospike cluster.', + unit: 'none', + sources: { + prometheus: { + expr: 'sum by(' + groupAggListWithoutInstance + ') (aerospike_node_stats_heartbeat_connections{%(queriesSelector)s})', + legendCustomTemplate: '{{aerospike_cluster}} - heartbeat', + }, + }, + }, + }, + }