Skip to content

Commit 236d1d1

Browse files
gpop63ritalwar
andauthored
[rubrik] Enable TSDB (#12917)
* dont set timestamp in node_statistics * enable tsdb for data streams * bump package version * fix pipeline * Update packages/rubrik/changelog.yml Co-authored-by: Richa Talwar <[email protected]> * Update packages/rubrik/changelog.yml Co-authored-by: Richa Talwar <[email protected]> * fix changelog * Revert "dont set timestamp in node_statistics" This reverts commit 95a8c2f. * Revert "fix pipeline" This reverts commit c1bcaaa. * change interval to 1h * add time range filter in query * improve docs --------- Co-authored-by: Richa Talwar <[email protected]>
1 parent 7439dfd commit 236d1d1

File tree

15 files changed

+42
-5
lines changed

15 files changed

+42
-5
lines changed

packages/rubrik/_dev/build/docs/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,8 @@ Please refer to the following [document](https://www.elastic.co/guide/en/ecs/cur
145145

146146
The `node_statistics` dataset provides metrics related to the performance of the Rubrik cluster nodes.
147147

148+
**IMPORTANT: Setting `interval` to more than `1h` may cause documents to be dropped if node statistics metrics fall outside the index time range.**
149+
148150
**ECS Field Reference**
149151

150152
Please refer to the following [document](https://www.elastic.co/guide/en/ecs/current/ecs-field-reference.html) for detailed information on ECS fields.

packages/rubrik/changelog.yml

+8
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
11
# newer versions go on top
2+
- version: "0.8.0"
3+
changes:
4+
- description: |
5+
Enable TSDB.
6+
Added support for specifying a time range in `ClusterNodeStatistics` query.
7+
Adjusted default interval from `24h` to `1h`.
8+
type: enhancement
9+
link: https://github.com/elastic/integrations/pull/12917
210
- version: "0.7.0"
311
changes:
412
- description: Add `sla_domains` data stream

packages/rubrik/data_stream/drives/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,5 @@ streams:
7070
required: false
7171
show_user: false
7272
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
73+
elasticsearch:
74+
index_mode: time_series

packages/rubrik/data_stream/filesets/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -63,3 +63,5 @@ streams:
6363
default: "# filter:\n# - field: \"location\"\n# texts: \n# - \"prod-lab.local\"\n"
6464
description: >-
6565
Specify filters for refining the data. Filters must be defined as an array of Filter objects. Refer to the [Rubrik API documentation](https://rubrikinc.github.io/rubrik-api-documentation/schema/reference/filter.doc.html) for valid fields.
66+
elasticsearch:
67+
index_mode: time_series

packages/rubrik/data_stream/global_cluster_performance/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -54,3 +54,5 @@ streams:
5454
required: false
5555
show_user: false
5656
description: The number of results per page in Rubrik GraphQL queries. Smaller pages mean more API requests but can be more efficient in some cases.
57+
elasticsearch:
58+
index_mode: time_series

packages/rubrik/data_stream/managed_volumes/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,5 @@ streams:
7070
required: false
7171
show_user: false
7272
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
73+
elasticsearch:
74+
index_mode: time_series

packages/rubrik/data_stream/monitoring_jobs/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -54,3 +54,5 @@ streams:
5454
required: false
5555
show_user: false
5656
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
57+
elasticsearch:
58+
index_mode: time_series

packages/rubrik/data_stream/mssql_databases/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,5 @@ streams:
7878
required: false
7979
show_user: false
8080
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
81+
elasticsearch:
82+
index_mode: time_series

packages/rubrik/data_stream/node_statistics/agent/stream/cel.yml.hbs

+8-3
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,18 @@ processors:
3535

3636
state:
3737
index: 0
38+
period: {{interval}}
3839
pageSize: {{pageSize}}
3940
queries:
4041
- |
41-
query ClusterNodeStatistics($first: Int, $after: String) {
42+
query ClusterNodeStatistics($first: Int, $after: String, $range: TimeRangeInput) {
4243
allClusterConnection(first: $first, after: $after) {
4344
count
4445
nodes {
4546
name
4647
type
4748
id
48-
clusterNodeStats {
49+
clusterNodeStats(timeRange: $range) {
4950
nodeId
5051
clusterPhysicalDataIngest
5152
networkBytesReceived
@@ -81,6 +82,10 @@ program: |-
8182
"variables": {
8283
"first": has(state.pageSize) ? state.pageSize : null,
8384
"after": has(state.cursor) ? state.cursor.after : null,
85+
"range": {
86+
"start": now - duration(state.period),
87+
"end": now.format(time_layout.RFC3339),
88+
}
8489
}
8590
}.encode_json()
8691
}
@@ -132,7 +137,7 @@ program: |-
132137
"index": body.data.allClusterConnection.pageInfo.hasNextPage ? int(state.index) : (int(state.index) + 1) % size(state.queries),
133138
"cursor": {
134139
"after": body.data.allClusterConnection.pageInfo.hasNextPage ? body.data.allClusterConnection.pageInfo.endCursor : null
135-
}
140+
},
136141
}
137142
)
138143
:

packages/rubrik/data_stream/node_statistics/manifest.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ streams:
2121
description: The interval at which the API is polled, supported in seconds, minutes, and hours.
2222
show_user: true
2323
required: true
24-
default: 24h
24+
default: 1h
2525
- name: processors
2626
type: yaml
2727
title: Processors
@@ -54,3 +54,5 @@ streams:
5454
required: false
5555
show_user: false
5656
description: The number of results per page in Rubrik GraphQL queries. Smaller pages mean more API requests but can be more efficient in some cases.
57+
elasticsearch:
58+
index_mode: time_series

packages/rubrik/data_stream/physical_hosts/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,5 @@ streams:
7878
required: false
7979
show_user: false
8080
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
81+
elasticsearch:
82+
index_mode: time_series

packages/rubrik/data_stream/tasks/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -47,3 +47,5 @@ streams:
4747
type: bool
4848
multi: false
4949
default: false
50+
elasticsearch:
51+
index_mode: time_series

packages/rubrik/data_stream/virtual_machines/manifest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,5 @@ streams:
7070
required: false
7171
show_user: false
7272
description: The request tracer logs requests and responses to the agent's local file-system for debugging configurations. Enabling this request tracing compromises security and should only be used for debugging. See [documentation](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-httpjson.html#_request_tracer_filename) for details.
73+
elasticsearch:
74+
index_mode: time_series

packages/rubrik/docs/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -1058,6 +1058,8 @@ An example event for `global_cluster_performance` looks as following:
10581058

10591059
The `node_statistics` dataset provides metrics related to the performance of the Rubrik cluster nodes.
10601060

1061+
**IMPORTANT: Setting `interval` to more than `1h` may cause documents to be dropped if node statistics metrics fall outside the index time range.**
1062+
10611063
**ECS Field Reference**
10621064

10631065
Please refer to the following [document](https://www.elastic.co/guide/en/ecs/current/ecs-field-reference.html) for detailed information on ECS fields.

packages/rubrik/manifest.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
format_version: 3.0.2
22
name: rubrik
33
title: "Rubrik RSC Metrics"
4-
version: 0.7.0
4+
version: 0.8.0
55
source:
66
license: "Elastic-2.0"
77
description: "Collect Metrics from Rubrik RSC with Elastic Agent."

0 commit comments

Comments
 (0)