Skip to content

Commit

Permalink
Enabling the Alloy integration should truly enable the integration (#941
Browse files Browse the repository at this point in the history
)

Signed-off-by: Pete Wall <pete.wall@grafana.com>
  • Loading branch information
petewall authored Nov 22, 2024
1 parent ab233c0 commit 1541c64
Show file tree
Hide file tree
Showing 19 changed files with 108 additions and 125 deletions.
105 changes: 0 additions & 105 deletions charts/feature-integrations/default-allow-lists/alloy-integration.yaml

This file was deleted.

104 changes: 103 additions & 1 deletion charts/feature-integrations/default-allow-lists/alloy.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,105 @@
---
# The minimal set of metrics from Grafana Alloy required for Kubernetes Monitoring
# The set of metrics from Grafana Alloy required for the Grafana Alloy integration
- alloy_build_info
- alloy_component_controller_running_components
- alloy_component_dependencies_wait_seconds
- alloy_component_dependencies_wait_seconds_bucket
- alloy_component_evaluation_seconds
- alloy_component_evaluation_seconds_bucket
- alloy_component_evaluation_seconds_count
- alloy_component_evaluation_seconds_sum
- alloy_component_evaluation_slow_seconds
- alloy_config_hash
- alloy_resources_machine_rx_bytes_total
- alloy_resources_machine_tx_bytes_total
- alloy_resources_process_cpu_seconds_total
- alloy_resources_process_resident_memory_bytes
- alloy_tcp_connections
- alloy_wal_samples_appended_total
- alloy_wal_storage_active_series
- cluster_node_gossip_health_score
- cluster_node_gossip_proto_version
- cluster_node_gossip_received_events_total
- cluster_node_info
- cluster_node_lamport_time
- cluster_node_peers
- cluster_node_update_observers
- cluster_transport_rx_bytes_total
- cluster_transport_rx_packet_queue_length
- cluster_transport_rx_packets_failed_total
- cluster_transport_rx_packets_total
- cluster_transport_stream_rx_bytes_total
- cluster_transport_stream_rx_packets_failed_total
- cluster_transport_stream_rx_packets_total
- cluster_transport_stream_tx_bytes_total
- cluster_transport_stream_tx_packets_failed_total
- cluster_transport_stream_tx_packets_total
- cluster_transport_streams
- cluster_transport_tx_bytes_total
- cluster_transport_tx_packet_queue_length
- cluster_transport_tx_packets_failed_total
- cluster_transport_tx_packets_total
- otelcol_exporter_send_failed_spans_total
- otelcol_exporter_sent_spans_total
- go_gc_duration_seconds_count
- go_goroutines
- go_memstats_heap_inuse_bytes
- loki_process_dropped_lines_total
- loki_write_batch_retries_total
- loki_write_dropped_bytes_total
- loki_write_dropped_entries_total
- loki_write_encoded_bytes_total
- loki_write_mutated_bytes_total
- loki_write_mutated_entries_total
- loki_write_request_duration_seconds_bucket
- loki_write_sent_bytes_total
- loki_write_sent_entries_total
- process_cpu_seconds_total
- process_start_time_seconds
- otelcol_processor_batch_batch_send_size_bucket
- otelcol_processor_batch_metadata_cardinality
- otelcol_processor_batch_timeout_trigger_send_total
- prometheus_remote_storage_bytes_total
- prometheus_remote_storage_enqueue_retries_total
- prometheus_remote_storage_highest_timestamp_in_seconds
- prometheus_remote_storage_metadata_bytes_total
- prometheus_remote_storage_queue_highest_sent_timestamp_seconds
- prometheus_remote_storage_samples_dropped_total
- prometheus_remote_storage_samples_failed_total
- prometheus_remote_storage_samples_pending
- prometheus_remote_storage_samples_retried_total
- prometheus_remote_storage_samples_total
- prometheus_remote_storage_sent_batch_duration_seconds_bucket
- prometheus_remote_storage_sent_batch_duration_seconds_count
- prometheus_remote_storage_sent_batch_duration_seconds_sum
- prometheus_remote_storage_shard_capacity
- prometheus_remote_storage_shards
- prometheus_remote_storage_shards_desired
- prometheus_remote_storage_shards_max
- prometheus_remote_storage_shards_min
- prometheus_remote_storage_succeeded_samples_total
- prometheus_remote_write_wal_samples_appended_total
- prometheus_remote_write_wal_storage_active_series
- prometheus_sd_discovered_targets
- prometheus_target_interval_length_seconds_count
- prometheus_target_interval_length_seconds_sum
- prometheus_target_scrapes_exceeded_sample_limit_total
- prometheus_target_scrapes_sample_duplicate_timestamp_total
- prometheus_target_scrapes_sample_out_of_bounds_total
- prometheus_target_scrapes_sample_out_of_order_total
- prometheus_target_sync_length_seconds_sum
- prometheus_wal_watcher_current_segment
- otelcol_receiver_accepted_spans_total
- otelcol_receiver_refused_spans_total
- rpc_server_duration_milliseconds_bucket
- scrape_duration_seconds
- traces_exporter_send_failed_spans
- traces_exporter_send_failed_spans_total
- traces_exporter_sent_spans
- traces_exporter_sent_spans_total
- traces_loadbalancer_backend_outcome
- traces_loadbalancer_num_backends
- traces_receiver_accepted_spans
- traces_receiver_accepted_spans_total
- traces_receiver_refused_spans
- traces_receiver_refused_spans_total
3 changes: 1 addition & 2 deletions charts/feature-integrations/docs/integrations/alloy.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
| maxCacheSize | string | `100000` | Sets the max_cache_size for prometheus.relabel component. This should be at least 2x-5x your largest scrape target or samples appended rate. ([docs](https://grafana.com/docs/alloy/latest/reference/components/prometheus.relabel/#arguments)) Overrides global.maxCacheSize |
| metricsTuning.excludeMetrics | list | `[]` | Metrics to drop. Can use regular expressions. |
| metricsTuning.includeMetrics | list | `[]` | Metrics to keep. Can use regular expressions. |
| metricsTuning.useDefaultAllowList | bool | `true` | Filter the list of metrics from Grafana Alloy to the minimal set required for Kubernetes Monitoring. See [Metrics Tuning and Allow Lists](#metrics-tuning-and-allow-lists) |
| metricsTuning.useIntegrationAllowList | bool | `false` | Filter the list of metrics from Grafana Alloy to the minimal set required for Kubernetes Monitoring as well as the Grafana Alloy integration. |
| metricsTuning.useDefaultAllowList | bool | `true` | Filter the list of metrics from Grafana Alloy to the minimal set required for the Grafana Alloy integration. |

### General Settings

Expand Down
6 changes: 1 addition & 5 deletions charts/feature-integrations/integrations/alloy-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,9 @@ scrapeInterval:

# Adjustments to the scraped metrics to filter the amount of data sent to storage.
metricsTuning:
# -- Filter the list of metrics from Grafana Alloy to the minimal set required for Kubernetes Monitoring.
# See [Metrics Tuning and Allow Lists](#metrics-tuning-and-allow-lists)
# -- Filter the list of metrics from Grafana Alloy to the minimal set required for the Grafana Alloy integration.
# @section -- Metric Processing Settings
useDefaultAllowList: true
# -- Filter the list of metrics from Grafana Alloy to the minimal set required for Kubernetes Monitoring as well as the Grafana Alloy integration.
# @section -- Metric Processing Settings
useIntegrationAllowList: false
# -- Metrics to keep. Can use regular expressions.
# @section -- Metric Processing Settings
includeMetrics: []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@
},
"useDefaultAllowList": {
"type": "boolean"
},
"useIntegrationAllowList": {
"type": "boolean"
}
}
},
Expand Down
3 changes: 0 additions & 3 deletions charts/feature-integrations/templates/_integration_alloy.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
{{- if .instance.metricsTuning.useDefaultAllowList -}}
{{- $allowList = concat $allowList (.Files.Get "default-allow-lists/alloy.yaml" | fromYamlArray) -}}
{{- end -}}
{{- if .instance.metricsTuning.useIntegrationAllowList -}}
{{- $allowList = concat $allowList (.Files.Get "default-allow-lists/alloy-integration.yaml" | fromYamlArray) -}}
{{- end -}}
{{- if .instance.metricsTuning.includeMetrics -}}
{{- $allowList = concat $allowList .instance.metricsTuning.includeMetrics -}}
{{- end -}}
Expand Down
2 changes: 1 addition & 1 deletion charts/feature-integrations/tests/alloy_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ tests:
alloy_integration_scrape "alloy_metrics" {
targets = alloy_integration_discovery.alloy_metrics.output
clustering = true
keep_metrics = "up|alloy_build_info"
keep_metrics = "up|alloy_build_info|alloy_component_controller_running_components|alloy_component_dependencies_wait_seconds|alloy_component_dependencies_wait_seconds_bucket|alloy_component_evaluation_seconds|alloy_component_evaluation_seconds_bucket|alloy_component_evaluation_seconds_count|alloy_component_evaluation_seconds_sum|alloy_component_evaluation_slow_seconds|alloy_config_hash|alloy_resources_machine_rx_bytes_total|alloy_resources_machine_tx_bytes_total|alloy_resources_process_cpu_seconds_total|alloy_resources_process_resident_memory_bytes|alloy_tcp_connections|alloy_wal_samples_appended_total|alloy_wal_storage_active_series|cluster_node_gossip_health_score|cluster_node_gossip_proto_version|cluster_node_gossip_received_events_total|cluster_node_info|cluster_node_lamport_time|cluster_node_peers|cluster_node_update_observers|cluster_transport_rx_bytes_total|cluster_transport_rx_packet_queue_length|cluster_transport_rx_packets_failed_total|cluster_transport_rx_packets_total|cluster_transport_stream_rx_bytes_total|cluster_transport_stream_rx_packets_failed_total|cluster_transport_stream_rx_packets_total|cluster_transport_stream_tx_bytes_total|cluster_transport_stream_tx_packets_failed_total|cluster_transport_stream_tx_packets_total|cluster_transport_streams|cluster_transport_tx_bytes_total|cluster_transport_tx_packet_queue_length|cluster_transport_tx_packets_failed_total|cluster_transport_tx_packets_total|otelcol_exporter_send_failed_spans_total|otelcol_exporter_sent_spans_total|go_gc_duration_seconds_count|go_goroutines|go_memstats_heap_inuse_bytes|loki_process_dropped_lines_total|loki_write_batch_retries_total|loki_write_dropped_bytes_total|loki_write_dropped_entries_total|loki_write_encoded_bytes_total|loki_write_mutated_bytes_total|loki_write_mutated_entries_total|loki_write_request_duration_seconds_bucket|loki_write_sent_bytes_total|loki_write_sent_entries_total|process_cpu_seconds_total|process_start_time_seconds|otelcol_processor_batch_batch_send_size_bucket|otelcol_processor_batch_metadata_cardinality|otelcol_processor_batch_timeout_trigger_send_total|prometheus_remote_storage_bytes_total|prometheus_remote_storage_enqueue_retries_total|prometheus_remote_storage_highest_timestamp_in_seconds|prometheus_remote_storage_metadata_bytes_total|prometheus_remote_storage_queue_highest_sent_timestamp_seconds|prometheus_remote_storage_samples_dropped_total|prometheus_remote_storage_samples_failed_total|prometheus_remote_storage_samples_pending|prometheus_remote_storage_samples_retried_total|prometheus_remote_storage_samples_total|prometheus_remote_storage_sent_batch_duration_seconds_bucket|prometheus_remote_storage_sent_batch_duration_seconds_count|prometheus_remote_storage_sent_batch_duration_seconds_sum|prometheus_remote_storage_shard_capacity|prometheus_remote_storage_shards|prometheus_remote_storage_shards_desired|prometheus_remote_storage_shards_max|prometheus_remote_storage_shards_min|prometheus_remote_storage_succeeded_samples_total|prometheus_remote_write_wal_samples_appended_total|prometheus_remote_write_wal_storage_active_series|prometheus_sd_discovered_targets|prometheus_target_interval_length_seconds_count|prometheus_target_interval_length_seconds_sum|prometheus_target_scrapes_exceeded_sample_limit_total|prometheus_target_scrapes_sample_duplicate_timestamp_total|prometheus_target_scrapes_sample_out_of_bounds_total|prometheus_target_scrapes_sample_out_of_order_total|prometheus_target_sync_length_seconds_sum|prometheus_wal_watcher_current_segment|otelcol_receiver_accepted_spans_total|otelcol_receiver_refused_spans_total|rpc_server_duration_milliseconds_bucket|scrape_duration_seconds|traces_exporter_send_failed_spans|traces_exporter_send_failed_spans_total|traces_exporter_sent_spans|traces_exporter_sent_spans_total|traces_loadbalancer_backend_outcome|traces_loadbalancer_num_backends|traces_receiver_accepted_spans|traces_receiver_accepted_spans_total|traces_receiver_refused_spans|traces_receiver_refused_spans_total"
scrape_interval = "60s"
max_cache_size = 100000
forward_to = argument.metrics_destinations.value
Expand Down
3 changes: 0 additions & 3 deletions charts/feature-integrations/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,6 @@
},
"useDefaultAllowList": {
"type": "boolean"
},
"useIntegrationAllowList": {
"type": "boolean"
}
}
},
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 1541c64

Please sign in to comment.