Skip to content

Commit 94e744e

Browse files
authored
Add Macos observability lib (#28)
* Add gitignore to node-observ-lib * Fix typo in node default filteringSelector * Prep alert group names for macos * Add macos-observ-lib * Change overview dashboard: show networkErrorsAndDroppedPerSec instead of networkErrorPerSec for Linux/MacOS * Add more alerts * Move alerts to sep file * Breaking: Update layout To allow to locally import linux from macos * Bring back NodeFilesystemAlmostOutOfFiles alert * Show only errors when they occur * Only show network interfaces that had traffic change at least once during selected dashboard interval
1 parent 4a48f6b commit 94e744e

File tree

473 files changed

+420
-81560
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

473 files changed

+420
-81560
lines changed
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
.jekyll-cache
21
jsonnetfile.lock.json
32
vendor

docs/node-observ-lib/jsonnetfile.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,20 @@
44
{
55
"source": {
66
"git": {
7-
"remote": "https://github.com/grafana/jsonnet-libs.git",
8-
"subdir": "common-lib"
7+
"remote": "https://github.com/grafana/grafonnet.git",
8+
"subdir": "gen/grafonnet-v10.0.0"
99
}
1010
},
11-
"version": "master"
11+
"version": "main"
1212
},
1313
{
1414
"source": {
1515
"git": {
16-
"remote": "https://github.com/grafana/grafonnet.git",
17-
"subdir": "gen/grafonnet-v10.0.0"
16+
"remote": "https://github.com/grafana/jsonnet-libs.git",
17+
"subdir": "common-lib"
1818
}
1919
},
20-
"version": "main"
20+
"version": "master"
2121
},
2222
{
2323
"source": {

docs/node-observ-lib/jsonnetfile.lock.json

Lines changed: 0 additions & 56 deletions
This file was deleted.

docs/node-observ-lib/README.md renamed to docs/node-observ-lib/linux/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ You can use observ-lib to fill in monitoring-mixin structure:
1717

1818
```jsonnet
1919
// mixin.libsonnet file
20-
local nodelib = import 'node-observ-lib/main.libsonnet';
20+
local nodelib = import 'node-observ-lib/linux/main.libsonnet';
2121
2222
local linux =
2323
nodelib.new()
@@ -45,7 +45,7 @@ local linux =
4545

4646
```jsonnet
4747
// mixin.libsonnet file
48-
local nodelib = import 'node-observ-lib/main.libsonnet';
48+
local nodelib = import 'node-observ-lib/linux/main.libsonnet';
4949
5050
local linux =
5151
nodelib.new()
@@ -82,7 +82,7 @@ local linux =
8282
8383
// mixin.libsonnet file
8484
local configOverride = import './overrides.libsonnet';
85-
local nodelib = import 'node-observ-lib/main.libsonnet';
85+
local nodelib = import 'node-observ-lib/linux/main.libsonnet';
8686
8787
local linux =
8888
nodelib.new()
@@ -101,7 +101,7 @@ local linux =
101101
```jsonnet
102102
local g = import './g.libsonnet';
103103
// mixin.libsonnet file
104-
local nodelib = import 'node-observ-lib/main.libsonnet';
104+
local nodelib = import 'node-observ-lib/linux/main.libsonnet';
105105
106106
local linux =
107107
nodelib.new()

docs/node-observ-lib/alerts.libsonnet renamed to docs/node-observ-lib/linux/alerts.libsonnet

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
new(this): {
33
groups: [
44
{
5-
name: if this.config.uid == 'node' then 'node-exporter-filesystem' else this.config.uid + '-linux-filesystem-alerts',
5+
name: if this.config.uid == 'node' then 'node-exporter-filesystem' else this.config.uid + '-filesystem-alerts',
66
rules: [
77
{
88
alert: 'NodeFilesystemSpaceFillingUp',
@@ -160,7 +160,7 @@
160160
},
161161
{
162162
// defaults to 'node-exporter for backward compatibility with old node-mixin
163-
name: if this.config.uid == 'node' then 'node-exporter' else this.config.uid + '-linux-alerts',
163+
name: if this.config.uid == 'node' then 'node-exporter' else this.config.uid + '-alerts',
164164
rules: [
165165
{
166166
alert: 'NodeNetworkReceiveErrs',

docs/node-observ-lib/annotations.libsonnet renamed to docs/node-observ-lib/linux/annotations.libsonnet

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
local g = import './g.libsonnet';
1+
local g = import '../g.libsonnet';
22
local commonlib = import 'common-lib/common/main.libsonnet';
33
{
44
new(this):

docs/node-observ-lib/config.libsonnet renamed to docs/node-observ-lib/linux/config.libsonnet

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// 'instanceLabels' - one or more labels that can be used to identify single entity of instances. In simple cases, can be 'instance' or 'pod'.
88
// 'uid' - UID to prefix all dashboards original uids
99

10-
filteringSelector: std.get(self, 'nodeExporterSelector', default='"job="node"'),
10+
filteringSelector: std.get(self, 'nodeExporterSelector', default='job="node"'),
1111
groupLabels: ['job'],
1212
instanceLabels: ['instance'],
1313
dashboardNamePrefix: 'Node exporter / ',

docs/node-observ-lib/dashboards.libsonnet renamed to docs/node-observ-lib/linux/dashboards.libsonnet

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
local g = import './g.libsonnet';
1+
local g = import '../g.libsonnet';
22
local logslib = import 'github.com/grafana/jsonnet-libs/logs-lib/logs/main.libsonnet';
33
{
44
local root = self,
@@ -59,7 +59,7 @@ local logslib = import 'github.com/grafana/jsonnet-libs/logs-lib/logs/main.libso
5959
panels.diskUsage { gridPos+: { w: 12, h: 8 } },
6060
g.panel.row.new('Network'),
6161
panels.networkUsagePerSec { gridPos+: { w: 12, h: 8 } },
62-
panels.networkErrorsPerSec { gridPos+: { w: 12, h: 8 } },
62+
panels.networkErrorsAndDroppedPerSec { gridPos+: { w: 12, h: 8 } },
6363
], 6, 2
6464
)
6565
)

docs/node-observ-lib/links.libsonnet renamed to docs/node-observ-lib/linux/links.libsonnet

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
local g = import './g.libsonnet';
1+
local g = import '../g.libsonnet';
22
local commonlib = import 'common-lib/common/main.libsonnet';
33
{
44
new(this):
File renamed without changes.

0 commit comments

Comments
 (0)