Skip to content

[Prometheus] Enable tsdb by default for collector and query datastreams #7261

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

tetianakravchenko
Copy link
Contributor

What does this PR do?

Enable tsdb by default for collector and query datastreams

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.

Author's Checklist

  • [ ]

How to test this PR locally

Run TSDB-migration-test-kit on query datastream:

Index being used for the settings and mappings is .ds-metrics-prometheus.query-default-2023.08.04-000001.

The time series fields for the TSDB index are: 
        - dimension (10 fields):
                - agent.id
                - cloud.account.id
                - cloud.availability_zone
                - cloud.instance.id
                - cloud.provider
                - cloud.region
                - container.id
                - host.name
                - prometheus.labels_id
                - service.address
        - gauge (1 fields):
                - prometheus.query.prometheus_http_requests_total_sum
        - routing_path (10 fields):
                - agent.id
                - cloud.account.id
                - cloud.availability_zone
                - cloud.instance.id
                - cloud.provider
                - cloud.region
                - container.id
                - host.name
                - prometheus.labels_id
                - service.address

Index tsdb-index-enabled successfully created.

Copying documents from .ds-metrics-prometheus.query-default-2023.08.04-000001 to tsdb-index-enabled...
All 624 documents taken from index .ds-metrics-prometheus.query-default-2023.08.04-000001 were successfully placed to index tsdb-index-enabled.

Run TSDB-migration-test-kit on collector datastream:

Testing data stream metrics-prometheus.collector-default.
Index being used for the documents is .ds-metrics-prometheus.collector-default-2023.08.04-000001.
Index being used for the settings and mappings is .ds-metrics-prometheus.collector-default-2023.08.04-000001.

The time series fields for the TSDB index are: 
        - dimension (10 fields):
                - agent.id
                - cloud.account.id
                - cloud.availability_zone
                - cloud.instance.id
                - cloud.provider
                - cloud.region
                - container.id
                - host.name
                - prometheus.labels_id
                - service.address
        - counter (13 fields):
                - prometheus.go_gc_duration_seconds_sum.counter
                - prometheus.go_memstats_alloc_bytes_total.counter
                - prometheus.go_memstats_frees_total.counter
                - prometheus.go_memstats_mallocs_total.counter
                - prometheus.process_cpu_seconds_total.counter
                - prometheus.prometheus_engine_query_duration_seconds_sum.counter
                - prometheus.prometheus_remote_storage_samples_in_total.counter
                - prometheus.prometheus_sd_kubernetes_http_request_duration_seconds_sum.counter
                - prometheus.prometheus_sd_kubernetes_workqueue_latency_seconds_sum.counter
                - prometheus.prometheus_sd_kubernetes_workqueue_work_duration_seconds_sum.counter
                - prometheus.prometheus_target_interval_length_seconds_sum.counter
                - prometheus.prometheus_target_sync_length_seconds_sum.counter
                - prometheus.prometheus_tsdb_head_samples_appended_total.counter
        - gauge (36 fields):
                - prometheus.go_gc_duration_seconds.value
                - prometheus.go_memstats_alloc_bytes.value
                - prometheus.go_memstats_buck_hash_sys_bytes.value
                - prometheus.go_memstats_gc_sys_bytes.value
                - prometheus.go_memstats_heap_alloc_bytes.value
                - prometheus.go_memstats_heap_idle_bytes.value
                - prometheus.go_memstats_heap_inuse_bytes.value
                - prometheus.go_memstats_heap_released_bytes.value
                - prometheus.go_memstats_heap_sys_bytes.value
                - prometheus.go_memstats_last_gc_time_seconds.value
                - prometheus.go_memstats_mspan_inuse_bytes.value
                - prometheus.go_memstats_mspan_sys_bytes.value
                - prometheus.go_memstats_next_gc_bytes.value
                - prometheus.go_memstats_other_sys_bytes.value
                - prometheus.go_memstats_stack_inuse_bytes.value
                - prometheus.go_memstats_stack_sys_bytes.value
                - prometheus.go_memstats_sys_bytes.value
                - prometheus.process_max_fds.value
                - prometheus.process_resident_memory_bytes.value
                - prometheus.process_start_time_seconds.value
                - prometheus.process_virtual_memory_bytes.value
                - prometheus.process_virtual_memory_max_bytes.value
                - prometheus.prometheus_config_last_reload_success_timestamp_seconds.value
                - prometheus.prometheus_engine_query_duration_seconds.value
                - prometheus.prometheus_remote_storage_highest_timestamp_in_seconds.value
                - prometheus.prometheus_target_interval_length_seconds.value
                - prometheus.prometheus_target_sync_length_seconds.value
                - prometheus.prometheus_tsdb_data_replay_duration_seconds.value
                - prometheus.prometheus_tsdb_head_chunks_storage_size_bytes.value
                - prometheus.prometheus_tsdb_head_max_time.value
                - prometheus.prometheus_tsdb_head_max_time_seconds.value
                - prometheus.prometheus_tsdb_head_min_time.value
                - prometheus.prometheus_tsdb_head_min_time_seconds.value
                - prometheus.prometheus_tsdb_lowest_timestamp.value
                - prometheus.prometheus_tsdb_lowest_timestamp_seconds.value
                - prometheus.prometheus_tsdb_wal_storage_size_bytes.value
        - routing_path (10 fields):
                - agent.id
                - cloud.account.id
                - cloud.availability_zone
                - cloud.instance.id
                - cloud.provider
                - cloud.region
                - container.id
                - host.name
                - prometheus.labels_id
                - service.address

Index tsdb-index-enabled successfully created.

Copying documents from .ds-metrics-prometheus.collector-default-2023.08.04-000001 to tsdb-index-enabled...
All 23690 documents taken from index .ds-metrics-prometheus.collector-default-2023.08.04-000001 were successfully placed to index tsdb-index-enabled.

Related issues

-Relates

Screenshots

Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co>
@tetianakravchenko tetianakravchenko requested a review from a team as a code owner August 4, 2023 13:31
@elasticmachine
Copy link

elasticmachine commented Aug 4, 2023

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2023-08-09T13:51:09.024+0000

  • Duration: 16 min 54 sec

Test stats 🧪

Test Results
Failed 0
Passed 9
Skipped 0
Total 9

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@elasticmachine
Copy link

elasticmachine commented Aug 4, 2023

🌐 Coverage report

Name Metrics % (covered/total) Diff
Packages 100.0% (0/0) 💚
Files 100.0% (0/0) 💚
Classes 100.0% (0/0) 💚
Methods 72.727% (8/11)
Lines 100.0% (0/0) 💚
Conditionals 100.0% (0/0) 💚

tetianakravchenko and others added 2 commits August 7, 2023 15:48
Co-authored-by: Andrew Gizas <andreas.gkizas@elastic.co>
Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co>
@tetianakravchenko tetianakravchenko merged commit 1708f8c into elastic:main Aug 9, 2023
@tetianakravchenko tetianakravchenko deleted the prometheus-enable-tsdb branch August 9, 2023 15:20
@elasticmachine
Copy link

Package prometheus - 1.8.0 containing this change is available at https://epr.elastic.co/search?package=prometheus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants