-
Notifications
You must be signed in to change notification settings - Fork 459
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[vSphere] Add new resourcepool datatastream (#10996)
* add resourcepool datastream * Update changelog * address review comments * add triggered_alarm * address review comments * update changelog * address review comment * address review comment --------- Co-authored-by: Niraj Rathod <[email protected]>
- Loading branch information
1 parent
bde6b51
commit 40459dc
Showing
14 changed files
with
733 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
70 changes: 70 additions & 0 deletions
70
packages/vsphere/data_stream/resourcepool/_dev/test/pipeline/test-resourcepool-metrics.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
{ | ||
"events": [ | ||
{ | ||
"vsphere": { | ||
"resourcepool": { | ||
"status": "green", | ||
"vm": { | ||
"names": [ | ||
"VM_1", | ||
"VM_2" | ||
], | ||
"count": 2 | ||
}, | ||
"cpu": { | ||
"usage": { | ||
"mhz": 3344 | ||
}, | ||
"demand": { | ||
"mhz": 3428 | ||
}, | ||
"entitlement": { | ||
"static": { | ||
"mhz": 21294 | ||
}, | ||
"mhz": 3239 | ||
} | ||
}, | ||
"memory": { | ||
"entitlement": { | ||
"bytes": 38854983680, | ||
"static": { | ||
"bytes": 13631488 | ||
} | ||
}, | ||
"private": { | ||
"bytes": 121667321856 | ||
}, | ||
"shared": { | ||
"bytes": 42991616 | ||
}, | ||
"swapped": { | ||
"bytes": 0 | ||
}, | ||
"ballooned": { | ||
"bytes": 0 | ||
}, | ||
"overhead": { | ||
"consumed": { | ||
"bytes": 1001390080 | ||
}, | ||
"bytes": 1695547392 | ||
}, | ||
"compressed": { | ||
"bytes": 0 | ||
}, | ||
"usage": { | ||
"guest": { | ||
"bytes": 7976517632 | ||
}, | ||
"host": { | ||
"bytes": 122667663360 | ||
} | ||
} | ||
}, | ||
"name": "Resources" | ||
} | ||
} | ||
} | ||
] | ||
} |
73 changes: 73 additions & 0 deletions
73
.../data_stream/resourcepool/_dev/test/pipeline/test-resourcepool-metrics.json-expected.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
{ | ||
"expected": [ | ||
{ | ||
"ecs": { | ||
"version": "8.11.0" | ||
}, | ||
"vsphere": { | ||
"resourcepool": { | ||
"cpu": { | ||
"demand": { | ||
"mhz": 3428 | ||
}, | ||
"entitlement": { | ||
"mhz": 3239, | ||
"static": { | ||
"mhz": 21294 | ||
} | ||
}, | ||
"usage": { | ||
"mhz": 3344 | ||
} | ||
}, | ||
"memory": { | ||
"ballooned": { | ||
"bytes": 0 | ||
}, | ||
"compressed": { | ||
"bytes": 0 | ||
}, | ||
"entitlement": { | ||
"bytes": 38854983680, | ||
"static": { | ||
"bytes": 13631488 | ||
} | ||
}, | ||
"overhead": { | ||
"bytes": 1695547392, | ||
"consumed": { | ||
"bytes": 1001390080 | ||
} | ||
}, | ||
"private": { | ||
"bytes": 121667321856 | ||
}, | ||
"shared": { | ||
"bytes": 42991616 | ||
}, | ||
"swapped": { | ||
"bytes": 0 | ||
}, | ||
"usage": { | ||
"guest": { | ||
"bytes": 7976517632 | ||
}, | ||
"host": { | ||
"bytes": 122667663360 | ||
} | ||
} | ||
}, | ||
"name": "Resources", | ||
"status": "green", | ||
"vm": { | ||
"count": 2, | ||
"names": [ | ||
"VM_1", | ||
"VM_2" | ||
] | ||
} | ||
} | ||
} | ||
} | ||
] | ||
} |
9 changes: 9 additions & 0 deletions
9
packages/vsphere/data_stream/resourcepool/_dev/test/system/test-default-config.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
service: vsphere-metrics | ||
vars: | ||
hosts: | ||
- "https://{{Hostname}}:8989/sdk" | ||
period: 10s | ||
username: "user" | ||
password: "password" | ||
# If insecure is true, don't verify the server's certificate chain | ||
insecure: true |
18 changes: 18 additions & 0 deletions
18
packages/vsphere/data_stream/resourcepool/agent/stream/stream.yml.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
metricsets: ["resourcepool"] | ||
hosts: | ||
{{#each hosts}} | ||
- {{this}} | ||
{{/each}} | ||
period: {{period}} | ||
username: {{username}} | ||
password: {{password}} | ||
# If insecure is true, don't verify the server's certificate chain | ||
insecure: {{insecure}} | ||
tags: | ||
{{#each tags as |tag|}} | ||
- {{tag}} | ||
{{/each}} | ||
{{#if processors}} | ||
processors: | ||
{{processors}} | ||
{{/if}} |
10 changes: 10 additions & 0 deletions
10
packages/vsphere/data_stream/resourcepool/elasticsearch/ingest_pipeline/default.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
description: Pipeline for resourcepool | ||
processors: | ||
- set: | ||
field: ecs.version | ||
value: '8.11.0' | ||
on_failure: | ||
- set: | ||
field: error.message | ||
value: '{{ _ingest.on_failure_message }}' |
20 changes: 20 additions & 0 deletions
20
packages/vsphere/data_stream/resourcepool/fields/agent.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
- name: host | ||
title: Host | ||
group: 2 | ||
description: A host is defined as a general computing instance. ECS host.* fields should be populated with details about the host on which the event happened, or from which the measurement was taken. Host types include hardware, virtual machines, Docker containers, and Kubernetes nodes. | ||
type: group | ||
fields: | ||
- name: name | ||
level: core | ||
type: keyword | ||
dimension: true | ||
ignore_above: 1024 | ||
description: Name of the host. It can contain what `hostname` returns on Unix systems, the fully qualified domain name, or a name specified by the user. The sender decides which value to use. | ||
- name: agent | ||
title: Agent | ||
type: group | ||
fields: | ||
- name: id | ||
type: keyword | ||
ignore_above: 1024 | ||
dimension: true |
12 changes: 12 additions & 0 deletions
12
packages/vsphere/data_stream/resourcepool/fields/base-fields.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
- name: data_stream.type | ||
type: constant_keyword | ||
description: Data stream type. | ||
- name: data_stream.dataset | ||
type: constant_keyword | ||
description: Data stream dataset. | ||
- name: data_stream.namespace | ||
type: constant_keyword | ||
description: Data stream namespace. | ||
- name: '@timestamp' | ||
type: date | ||
description: Event timestamp. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
- name: service.address | ||
external: ecs | ||
dimension: true | ||
- external: ecs | ||
name: cloud.instance.id | ||
dimension: true | ||
- external: ecs | ||
name: cloud.provider | ||
dimension: true | ||
- external: ecs | ||
name: container.id | ||
dimension: true | ||
- external: ecs | ||
name: cloud.account.id | ||
dimension: true | ||
- external: ecs | ||
name: cloud.region | ||
dimension: true | ||
- external: ecs | ||
name: cloud.availability_zone | ||
dimension: true |
Oops, something went wrong.