This repository has been archived by the owner on Nov 21, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #117 from STCLab-Inc/107-create-a-variety-of-metri…
…c-usage-examples feat: Create a variety of metric usage examples
- Loading branch information
Showing
18 changed files
with
140 additions
and
106 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
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
2 changes: 1 addition & 1 deletion
2
core/wave-autoscale/tests/metrics_test.rs → core/wave-autoscale/tests/simulation.rs
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
15 changes: 0 additions & 15 deletions
15
core/wave-autoscale/tests/yaml/metric_cloudwatch_data.yaml
This file was deleted.
Oops, something went wrong.
22 changes: 0 additions & 22 deletions
22
core/wave-autoscale/tests/yaml/metric_cloudwatch_statistics.yaml
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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
File renamed without changes.
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
core/wave-metrics/tests/metrics-examples/telegraf-google-cloud-monitoring-metrics.yaml
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 @@ | ||
# References - Telegraf Stackdriver Google Cloud Monitoring Input Plugin | ||
# https://github.com/influxdata/telegraf/blob/release-1.27/plugins/inputs/stackdriver/README.md | ||
--- | ||
kind: Metric | ||
id: google_cloud_monitoring_mig_metrics | ||
collector: telegraf | ||
metric_kind: stackdriver | ||
metadata: | ||
project: wave-autoscale-test | ||
## Include timeseries that start with the given metric type. | ||
metric_type_prefix_include: ["compute.googleapis.com/instance/cpu/utilization"] | ||
interval: "1m" | ||
|
||
# Output in the database will be like this: | ||
# [ | ||
# { | ||
# "name": "google_cloud_monitoring_mig_metrics_utilization", | ||
# "tags": { | ||
# "host": "local", | ||
# "instance_id": "3137596874116707338", | ||
# "instance_name": "test-instance-group-1-lp73", | ||
# "project_id": "wave-autoscale-test", | ||
# "resource_type": "gce_instance", | ||
# "zone": "asia-northeast2-a" | ||
# }, | ||
# "value": 0.009973257744559306 | ||
# }, | ||
# { | ||
# "name": "google_cloud_monitoring_mig_metrics_utilization", | ||
# "tags": { | ||
# "host": "local", | ||
# "instance_id": "8022840066979737199", | ||
# "instance_name": "instance-group-2-r32v", | ||
# "project_id": "wave-autoscale-test", | ||
# "resource_type": "gce_instance", | ||
# "zone": "asia-northeast2-a" | ||
# }, | ||
# "value": 0.04300702278317961 | ||
# }, | ||
# { | ||
# "name": "google_cloud_monitoring_mig_metrics_utilization", | ||
# "tags": { | ||
# "host": "local", | ||
# "instance_id": "851205196260609218", | ||
# "instance_name": "instance-group-2-wpng", | ||
# "project_id": "wave-autoscale-test", | ||
# "resource_type": "gce_instance", | ||
# "zone": "asia-northeast2-a" | ||
# }, | ||
# "value": 0.0171343613359871 | ||
# } | ||
# ] | ||
|
||
|
||
# --- | ||
# kind: ScalingPlan | ||
# id: google_scaling_plan | ||
# title: "Scaling Plan for Google VM Instance" | ||
# plans: | ||
# - id: scale-up-plan-1 | ||
# description: "Scale up" | ||
# # JavaScript expression that returns a boolean value. | ||
# expression: > | ||
# get({ | ||
# name: 'google_cloud_monitoring_mig_metrics_utilization' | ||
# }) > 0.04 | ||
# # Higher priority values will be checked first. | ||
# priority: 1 | ||
# scaling_components: | ||
# ... |
7 changes: 7 additions & 0 deletions
7
core/wave-metrics/tests/metrics-examples/telegraf-mem-metrics.yaml
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,7 @@ | ||
# https://github.com/influxdata/telegraf/blob/master/plugins/inputs/mem/README.md | ||
--- | ||
kind: Metric | ||
id: telegraf_mem_metrics | ||
collector: telegraf | ||
metric_kind: mem | ||
metadata: |
9 changes: 9 additions & 0 deletions
9
core/wave-metrics/tests/metrics-examples/vector-host-metrics.yaml
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 @@ | ||
# https://vector.dev/docs/reference/configuration/sources/host_metrics/ | ||
--- | ||
kind: Metric | ||
id: vector_host_metrics | ||
collector: vector | ||
metric_kind: host_metrics | ||
metadata: | ||
namespace: host | ||
scrape_interval_secs: 5 |
14 changes: 14 additions & 0 deletions
14
core/wave-metrics/tests/metrics-examples/vector-prometheus-metrics.yaml
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,14 @@ | ||
# https://vector.dev/docs/reference/configuration/sources/prometheus_scrape/#query | ||
--- | ||
kind: Metric | ||
id: vector_host_metrics | ||
collector: vector | ||
metric_kind: prometheus_scrape | ||
metadata: | ||
endpoints: | ||
- http://localhost:9090/metrics | ||
query: | ||
"match[]": | ||
- '{job="somejob"}' | ||
- '{__name__=~"job:.*"}' | ||
scrape_interval_secs: 15 |
This file was deleted.
Oops, something went wrong.