pax_global_header00006660000000000000000000000064151156276530014525gustar00rootroot0000000000000052 comment=eee51ae24a6c802046077c59aff82f6f65cc220e prometheus-elasticsearch-exporter-1.10.0/000077500000000000000000000000001511562765300204555ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/.github/000077500000000000000000000000001511562765300220155ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/.github/dependabot.yml000066400000000000000000000004311511562765300246430ustar00rootroot00000000000000version: 2 updates: - package-ecosystem: "gomod" directory: "/" schedule: interval: "monthly" groups: aws: patterns: - "github.com/aws/*" - package-ecosystem: "github-actions" directory: "/" schedule: interval: "monthly" prometheus-elasticsearch-exporter-1.10.0/.github/workflows/000077500000000000000000000000001511562765300240525ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/.github/workflows/ci.yml000066400000000000000000000102641511562765300251730ustar00rootroot00000000000000--- name: CI on: pull_request: push: jobs: test_go: name: Go tests runs-on: ubuntu-latest container: # Whenever the Go version is updated here, .promu.yml # should also be updated. image: quay.io/prometheus/golang-builder:1.25-base steps: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - uses: prometheus/promci@443c7fc2397e946bc9f5029e313a9c3441b9b86d # v0.4.7 - uses: ./.github/promci/actions/setup_environment - run: make GO_ONLY=1 SKIP_GOLANGCI_LINT=1 build: name: Build Prometheus for common architectures runs-on: ubuntu-latest if: | !(github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) && !(github.event_name == 'pull_request' && startsWith(github.event.pull_request.base.ref, 'release-')) && !(github.event_name == 'push' && github.event.ref == 'refs/heads/main') && !(github.event_name == 'push' && github.event.ref == 'refs/heads/master') strategy: matrix: thread: [ 0, 1, 2 ] steps: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - uses: prometheus/promci@443c7fc2397e946bc9f5029e313a9c3441b9b86d # v0.4.7 - uses: ./.github/promci/actions/build with: promu_opts: "-p linux/amd64 -p windows/amd64 -p linux/arm64 -p darwin/amd64 -p darwin/arm64 -p linux/386" parallelism: 3 thread: ${{ matrix.thread }} build_all: name: Build Prometheus for all architectures runs-on: ubuntu-latest if: | (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) || (github.event_name == 'pull_request' && startsWith(github.event.pull_request.base.ref, 'release-')) || (github.event_name == 'push' && github.event.ref == 'refs/heads/main') || (github.event_name == 'push' && github.event.ref == 'refs/heads/master') strategy: matrix: thread: [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 ] # Whenever the Go version is updated here, .promu.yml # should also be updated. steps: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - uses: prometheus/promci@443c7fc2397e946bc9f5029e313a9c3441b9b86d # v0.4.7 - uses: ./.github/promci/actions/build with: parallelism: 12 thread: ${{ matrix.thread }} publish_main: # https://github.com/prometheus/promci/blob/52c7012f5f0070d7281b8db4a119e21341d43c91/actions/publish_main/action.yml name: Publish main branch artifacts runs-on: ubuntu-latest needs: [test_go, build_all] if: | (github.event_name == 'push' && github.event.ref == 'refs/heads/main') || (github.event_name == 'push' && github.event.ref == 'refs/heads/master') steps: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - uses: prometheus/promci@443c7fc2397e946bc9f5029e313a9c3441b9b86d # v0.4.7 - uses: ./.github/promci/actions/publish_main with: docker_hub_organization: prometheuscommunity docker_hub_login: ${{ secrets.docker_hub_login }} docker_hub_password: ${{ secrets.docker_hub_password }} quay_io_organization: prometheuscommunity quay_io_login: ${{ secrets.quay_io_login }} quay_io_password: ${{ secrets.quay_io_password }} publish_release: name: Publish release artefacts runs-on: ubuntu-latest needs: [test_go, build_all] if: | (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')) steps: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - uses: prometheus/promci@443c7fc2397e946bc9f5029e313a9c3441b9b86d # v0.4.7 - uses: ./.github/promci/actions/publish_release with: docker_hub_organization: prometheuscommunity docker_hub_login: ${{ secrets.docker_hub_login }} docker_hub_password: ${{ secrets.docker_hub_password }} quay_io_organization: prometheuscommunity quay_io_login: ${{ secrets.quay_io_login }} quay_io_password: ${{ secrets.quay_io_password }} github_token: ${{ secrets.PROMBOT_GITHUB_TOKEN }} prometheus-elasticsearch-exporter-1.10.0/.github/workflows/container_description.yml000066400000000000000000000046351511562765300311720ustar00rootroot00000000000000--- name: Push README to Docker Hub on: push: paths: - "README.md" - "README-containers.md" - ".github/workflows/container_description.yml" branches: [ main, master ] permissions: contents: read jobs: PushDockerHubReadme: runs-on: ubuntu-latest name: Push README to Docker Hub if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks. steps: - name: git checkout uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: persist-credentials: false - name: Set docker hub repo name run: echo "DOCKER_REPO_NAME=$(make docker-repo-name)" >> $GITHUB_ENV - name: Push README to Dockerhub uses: christian-korneck/update-container-description-action@d36005551adeaba9698d8d67a296bd16fa91f8e8 # v1 env: DOCKER_USER: ${{ secrets.DOCKER_HUB_LOGIN }} DOCKER_PASS: ${{ secrets.DOCKER_HUB_PASSWORD }} with: destination_container_repo: ${{ env.DOCKER_REPO_NAME }} provider: dockerhub short_description: ${{ env.DOCKER_REPO_NAME }} # Empty string results in README-containers.md being pushed if it # exists. Otherwise, README.md is pushed. readme_file: '' PushQuayIoReadme: runs-on: ubuntu-latest name: Push README to quay.io if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks. steps: - name: git checkout uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: persist-credentials: false - name: Set quay.io org name run: echo "DOCKER_REPO=$(echo quay.io/${GITHUB_REPOSITORY_OWNER} | tr -d '-')" >> $GITHUB_ENV - name: Set quay.io repo name run: echo "DOCKER_REPO_NAME=$(make docker-repo-name)" >> $GITHUB_ENV - name: Push README to quay.io uses: christian-korneck/update-container-description-action@d36005551adeaba9698d8d67a296bd16fa91f8e8 # v1 env: DOCKER_APIKEY: ${{ secrets.QUAY_IO_API_TOKEN }} with: destination_container_repo: ${{ env.DOCKER_REPO_NAME }} provider: quay # Empty string results in README-containers.md being pushed if it # exists. Otherwise, README.md is pushed. readme_file: '' prometheus-elasticsearch-exporter-1.10.0/.github/workflows/golangci-lint.yml000066400000000000000000000027371511562765300273350ustar00rootroot00000000000000--- # This action is synced from https://github.com/prometheus/prometheus name: golangci-lint on: push: paths: - "go.sum" - "go.mod" - "**.go" - "scripts/errcheck_excludes.txt" - ".github/workflows/golangci-lint.yml" - ".golangci.yml" pull_request: permissions: # added using https://github.com/step-security/secure-repo contents: read jobs: golangci: permissions: contents: read # for actions/checkout to fetch code pull-requests: read # for golangci/golangci-lint-action to fetch pull requests name: lint runs-on: ubuntu-latest steps: - name: Checkout repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: persist-credentials: false - name: Install Go uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 with: go-version: 1.25.x - name: Install snmp_exporter/generator dependencies run: sudo apt-get update && sudo apt-get -y install libsnmp-dev if: github.repository == 'prometheus/snmp_exporter' - name: Get golangci-lint version id: golangci-lint-version run: echo "version=$(make print-golangci-lint-version)" >> $GITHUB_OUTPUT - name: Lint uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # v8.0.0 with: args: --verbose version: ${{ steps.golangci-lint-version.outputs.version }} prometheus-elasticsearch-exporter-1.10.0/.github/workflows/mixin.yml000066400000000000000000000025341511562765300257250ustar00rootroot00000000000000--- name: mixin on: pull_request: paths: - "elasticsearch-mixin/**" jobs: check-mixin: name: check runs-on: ubuntu-latest steps: - name: Checkout repository uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - name: Setup Go uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 with: go-version: 1.25.x - name: Install dependencies run: | go install github.com/google/go-jsonnet/cmd/jsonnet@v0.20.0 go install github.com/google/go-jsonnet/cmd/jsonnetfmt@v0.20.0 go install github.com/google/go-jsonnet/cmd/jsonnet-lint@v0.20.0 go install github.com/monitoring-mixins/mixtool/cmd/mixtool@16dc166166d91e93475b86b9355a4faed2400c18 go install github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb@v0.5.1 - name: Lint run: bash ./scripts/lint-jsonnet.sh - name: Compile mixin run: bash ./scripts/compile-mixin.sh - name: Verify compiled mixin matches repo run: | git diff --exit-code -- ./elasticsearch-mixin || (echo "Compiled mixin does not match repo" && exit 1) # Check if there are any new untracked files test -z "$(git status --porcelain)" || (echo "Untracked files found, please run ./scripts/compile-mixin.sh" && exit 1) prometheus-elasticsearch-exporter-1.10.0/.gitignore000066400000000000000000000001111511562765300224360ustar00rootroot00000000000000.build elasticsearch_exporter *.tar.gz *-stamp .tarballs /vendor vendor/ prometheus-elasticsearch-exporter-1.10.0/.golangci.yml000066400000000000000000000075431511562765300230520ustar00rootroot00000000000000--- version: "2" formatters: enable: - gci - gofumpt settings: gci: sections: - standard - prefix(github.com/prometheus-community/elasticsearch_exporter) - default linters: enable: - depguard # TODO(@sysadmind): Enable and fix the issues. # - errorlint - exptostd # TODO(@sysadmind): Enable and fix the issues. # - gocritic # - godot - loggercheck # TODO(@sysadmind): Enable and fix the issues. # - misspell - nilnesserr - nolintlint # TODO(@sysadmind): Enable and fix the issues. # - perfsprint - predeclared - revive - sloglint - testifylint - unconvert - unused - usestdlibvars - whitespace exclusions: rules: # Disable errcheck for test files. - linters: - errcheck path: _test.go # Disable errcheck rule for some specific functions. - linters: - errcheck # Taken from the default exclusions in v1. text: Error return value of .((os\.)?std(out|err)\..*|.*Close|.*Flush|os\.Remove(All)?|.*print(f|ln)?|os\.(Un)?Setenv). is not checked settings: revive: rules: # https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md - name: blank-imports - name: comment-spacings - name: context-as-argument arguments: # Allow functions with test or bench signatures. - allowTypesBefore: '*testing.T,testing.TB' - name: context-keys-type - name: dot-imports - name: early-return arguments: - "preserveScope" # A lot of false positives: incorrectly identifies channel draining as "empty code block". # See https://github.com/mgechev/revive/issues/386 - name: empty-block disabled: true - name: error-naming - name: error-return - name: error-strings - name: errorf # TODO(@sysadmind): Enable and fix the issues. # - name: exported - name: increment-decrement - name: indent-error-flow arguments: - "preserveScope" - name: package-comments # TODO(beorn7/sysadmind): Currently, we have a lot of missing package doc comments. Maybe we should have them. disabled: true - name: range - name: receiver-naming - name: redefines-builtin-id - name: superfluous-else arguments: - "preserveScope" - name: time-naming # TODO(@sysadmind): Enable and fix the issues. # - name: unexported-return - name: unreachable-code - name: unused-parameter severity: warning disabled: true - name: var-declaration - name: var-naming depguard: rules: main: deny: - pkg: "sync/atomic" desc: "Use go.uber.org/atomic instead of sync/atomic" - pkg: "github.com/stretchr/testify/assert" desc: "Use github.com/stretchr/testify/require instead of github.com/stretchr/testify/assert" - pkg: "github.com/go-kit/kit/log" desc: "Use github.com/go-kit/log instead of github.com/go-kit/kit/log" - pkg: "io/ioutil" desc: "Use corresponding 'os' or 'io' functions instead." - pkg: "regexp" desc: "Use github.com/grafana/regexp instead of regexp" - pkg: "github.com/pkg/errors" desc: "Use 'errors' or 'fmt' instead of github.com/pkg/errors" - pkg: "gzip" desc: "Use github.com/klauspost/compress instead of gzip" - pkg: "zlib" desc: "Use github.com/klauspost/compress instead of zlib" - pkg: "golang.org/x/exp/slices" desc: "Use 'slices' instead." issues: max-issues-per-linter: 0 max-same-issues: 0 prometheus-elasticsearch-exporter-1.10.0/.promu.yml000066400000000000000000000015441511562765300224240ustar00rootroot00000000000000go: # Whenever the Go version is updated here, # .github/workflows should also be updated. version: 1.25 repository: path: github.com/prometheus-community/elasticsearch_exporter build: binaries: - name: elasticsearch_exporter ldflags: | -s -X github.com/prometheus/common/version.Version={{.Version}} -X github.com/prometheus/common/version.Revision={{.Revision}} -X github.com/prometheus/common/version.Branch={{.Branch}} -X github.com/prometheus/common/version.BuildUser={{user}}@{{host}} -X github.com/prometheus/common/version.BuildDate={{date "20060102-15:04:05"}} tarball: files: - LICENSE - README.md - CHANGELOG.md - examples/grafana/dashboard.json - examples/kubernetes/deployment.yml - examples/prometheus/elasticsearch.rules prometheus-elasticsearch-exporter-1.10.0/.yamllint000066400000000000000000000007171511562765300223140ustar00rootroot00000000000000--- extends: default ignore: | **/node_modules rules: braces: max-spaces-inside: 1 level: error brackets: max-spaces-inside: 1 level: error commas: disable comments: disable comments-indentation: disable document-start: disable indentation: spaces: consistent indent-sequences: consistent key-duplicates: ignore: | config/testdata/section_key_dup.bad.yml line-length: disable truthy: check-keys: false prometheus-elasticsearch-exporter-1.10.0/CHANGELOG.md000066400000000000000000000210401511562765300222630ustar00rootroot00000000000000## master / unreleased ## 1.10.0 / 2025-12-02 ### BREAKING CHANGES * `--es.uri` now defaults to empty string #1063 * The flag `--es.data_stream` has been renamed to `--collector.data-stream`. * The flag `--es.ilm` has been renamed to `--collector.ilm`. ### Changelog * [SECURITY] Remove logging unsanitized URL when HTTP request fails #1051 * [CHANGE] Rename --es.data_stream to --collector.data-stream #983 * [CHANGE] Rename --es.ilm to --collector.ilm #999 * [FEATURE] Add multi-target scraping via /probe endpoint #1063 * [FEATURE] Add health-report collector #1002 * [FEATURE] Add pprof profiling #1033 * [ENHANCEMENT] Ensure time.Ticker is released #1049 * [BUGFIX] Fix disk watermark values json parsing #1055 * [BUGFIX] Change collector failure log level to warning #1050 ## 1.9.0 / 2025-02-27 BREAKING CHANGES: The flag `--es.slm` has been renamed to `--collector.slm`. The logging system has been replaced with log/slog from the stdlib. This change is being made across the prometheus ecosystem. The logging output has changed, but the messages and levels remain the same. The `ts` label for the timestamp has bewen replaced with `time`, the accuracy is less, and the timezone is not forced to UTC. The `caller` field has been replaced by the `source` field, which now includes the full path to the source file. The `level` field now exposes the log level in capital letters. * [CHANGE] Rename --es.slm to --collector.slm #932 * [CHANGE] Replace logging system #942 * [ENHANCEMENT] Add external refresh stats #933 ## 1.8.0 / 2024-09-14 * [FEATURE] Add tasks action collector. Enable using `--collector.tasks.actions`. #778 * [FEATURE] Add additional nodes metrics for indexing pressure monitoring. #904 ## 1.7.0 / 2023-12-02 BREAKING CHANGES: The flag `--es.snapshots` has been renamed to `--collector.snapshots`. * [CHANGE] Rename --es.snapshots to --collector.snapshots #789 * [CHANGE] Add cluster label to `elasticsearch_node_shards_total` metric #639 * [FEATURE] Add watermark metrics #611 * [FEATURE] Add `elasticsearch_indices_settings_creation_timestamp_seconds` metric #816 ## 1.6.0 / 2023-06-22 BREAKING CHANGES: The flag `--es.cluster_settings` has been renamed to `--collector.clustersettings`. * [CHANGE] Rename --es.cluster_settings to --collector.clustersettings * [FEATURE] Add ILM metrics #513 * [ENHANCEMENT] Add ElasticCloud node roles to role label #652 * [ENHANCEMENT] Add ability to use AWS IAM role for authentication #653 * [ENHANCEMENT] Add metric for index replica count #483 * [BUGFIX] Set elasticsearch_clusterinfo_version_info guage to 1 #728 * [BUGFIX] Fix index field counts with nested fields #675 ## 1.5.0 / 2022-07-28 * [FEATURE] Add metrics collection for data stream statistics #592 * [FEATURE] Support for AWS Elasticsearch using AWS SDK v2 #597 * [BUGFIX] Fix cluster settings collection when max_shards_per_node is manually set. #603 ## 1.4.0 / 2022-06-29 * [BREAKING] Remove ENV var support for most non-sensitive options. #518 * [BREAKING] Rename elasticsearch_process_cpu_time_seconds_sum to elasticsearch_process_cpu_seconds_total #520 * [FEATURE] Add metric for index aliases #563 * [FEATURE] Add metric for number of shards on a node #535 * [FEATURE] Add metrics for SLM (snapshot lifecycle management) #558 * [FEATURE] Add metric for JVM uptime #537 * [FEATURE] Add metrics for current searches and current indexing documents #485 * [BUGFIX] Remove the elasticsearch_process_cpu_time_seconds_sum metric as it was never used #498 ## 1.3.0 / 2021-10-21 * [FEATURE] Add support for passing elasticsearch credentials via the ES_USERNAME and ES_PASSWORD environment varialbes #461 * [FEATURE] Add support for API keys for elasticsearch authentication (Elastic cloud) #459 * [BUGFIX] Fix index stats when shards are unavailable #445 ## 1.2.1 / 2021-06-29 * [BUGFIX] Fixed elasticsearch 7.13 node stats metrics #439 * [BUGFIX] Fixed snapshot stats metrics for some snapshot repository types #442 ## 1.2.0 / 2021-06-10 This release marks the first release under the prometheus-community organization. * [FEATURE] Added elasticsearch_clustersettings_stats_max_shards_per_node metric. #277 * [FEATURE] Added elasticsearch_indices_shards_store_size_in_bytes metric. #292 * [FEATURE] Added --es.indices_mappings flag to scrape elasticsearch index mapping stats and elasticsearch_indices_mappings_stats collector. #411 * [FEATURE] Added elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds metric. #318 * [ENHANCEMENT] Added support for reloading the tls client certificate in case it changes on disk. #414 * [BUGFIX] Fixed the elasticsearch_indices_shards_docs metric name. #291 ## 1.1.0 repeating the breaking changes introduced in 1.1.0rc1: * [BREAKING] uses the registered exporter port 9114 instead of 9118. If you need to stick to the old port, you can specify the listen port with --web.listen-address * [BREAKING] commandline flags are now POSIX flags with double dashes -- new changes in 1.1.0: * [FEATURE] add checksum promu command to Makefile * [FEATURE] add healthz handler * [BUGFIX] json parse error if the snapshot json contains failures (#269) * [BUGFIX] Remove credentials from URL in clusterinfo metrics * [FEATURE] Add indices_segment_term_vectors_memory_bytes_{primary,total} metrics * [FEATURE] Add indices_segments_{points,term_vectors,version_map}_memory_in_bytes metrics * [BUGFIX] Kubernetes yml file fixes * [FEATURE] Add index_stats_query_cache_caches_total metric * [FEATURE] Rename query_cache_cache_count metric to query_cache_cache_total * [BUGFIX] Change type for indices_query_cache_cache_count metric to counter * [BUGFIX]/ [BREAKING] Add _total prefix to indices_warmer_time_seconds metric * [FEATURE] Add indices_warmer_{time_seconds,total} metrics * [BUGFIX] exporter doesn't exit 1 if port is already in use (#241) * [BUGFIX] parse clusterinfo.build_date as string, not time.Time * [BUGFIX] Various Documentation Fixes * [FEATURE] add node_roles metric (#207) * [FEATURE] Extend nodes metrics. added indices.merges.current_size build fix: remove unnecessary conversion * [FEATURE] Extend nodes metrics. added overhead of circuit breakers * [BUGFIX] fix nodes metrics name indices.query_cache_miss_count, indices.request_cache_miss_count * [FEATURE] Extend nodes search metrics. added scroll_total, scroll_time * [FEATURE] Extend indices.indexing nodes metrics. added is_throttled, throttle_time * [FEATURE]/ [BUGFIX] #212 remove misleading metric ## 1.1.0rc1 * [BREAKING] uses the registered exporter port 9114 instead of 9118. If you need to stick to the old port, you can specify the listen port with --web.listen-address * [BREAKING] commandline flags are now POSIX flags with double dashes -- * [FEATURE] new collector for snapshot metrics * [FEATURE] added os memory stats metrics * [FEATURE] enable querying ES via proxy * [FEATURE] new collector for cluster settings * [FEATURE] new collector for indices settings * [FEATURE] cluster info collector. The collector periodically queries the / endpoints and provides the other collectors with a semi up-to-date cluster label * * [FEATURE]/ [BUGFIX] grafana dashboard improvements and fixes * [BUGFIX] Fixed createTLSConfig function. Return full tls configuration when ca, crt, key and insecure flag are set * * [INTERNAL] added code linting to build pipeline ## 1.0.4rc1 * [DOCUMENTATION] documentation updates * [FEATURE] add more index metrics * [FEATURE] add filesystem metrics * [FEATURE] add jvm buffer pool metrics * [FEATURE] add support for using the exporter behind reverse proxy (URL-prefixing) * [ENHANCEMENT] add linting to build chain and make project lint clean ## 1.0.3rc1 * [BUGFIX] update prometheus alerting rule example to v2 format * [ENHANCEMENT] Add formatting option for logger * [ENHANCEMENT] Add shard-level document count (can be toggled out) * [ENHANCEMENT] Add OS CPU usage metric * [ENHANCEMENT] Add skip-ssl-verify option * [ENHANCEMENT] Add node-level current merge metrics ## 1.0.2 / 2018-01-09 * [ENHANCEMENT] Add index metrics [#85] [#116] [#118] * [ENHANCEMENT] Add cache metrics [#88] * [ENHANCEMENT] Add documentation for the example dashboard [#84] * [ENHANCEMNET] Expose load averages [#113] * [BUGFIX] Fix role detection [#105] [#110] * [BUGFIX] Fix indexing calls and time metrics [#83] ## 1.0.1 / 2017-07-24 * [ENHANCEMENT] Add exporter instrumentation [#78] * [BUGFIX] Exclude basic auth credentials from log [#71] * [BUGFIX] Fix missing node store size metric ## 1.0.0 / 2017-07-03 * [ENHANCEMENT] Rewrite the codebase to reduce redundancy and improve extensibility [#65] * [ENHANCEMENT] Add examples for Grafana and Prometheus [#66] * [BREAKING] Removed several duplicate or redundant metrics [#65] prometheus-elasticsearch-exporter-1.10.0/CODE_OF_CONDUCT.md000066400000000000000000000002301511562765300232470ustar00rootroot00000000000000# Prometheus Community Code of Conduct Prometheus follows the [CNCF Code of Conduct](https://github.com/cncf/foundation/blob/main/code-of-conduct.md). prometheus-elasticsearch-exporter-1.10.0/Dockerfile000066400000000000000000000005501511562765300224470ustar00rootroot00000000000000ARG ARCH="amd64" ARG OS="linux" FROM quay.io/prometheus/busybox-${OS}-${ARCH}:glibc LABEL maintainer="The Prometheus Authors " ARG ARCH="amd64" ARG OS="linux" COPY .build/${OS}-${ARCH}/elasticsearch_exporter /bin/elasticsearch_exporter EXPOSE 7979 USER nobody ENTRYPOINT [ "/bin/elasticsearch_exporter" ] prometheus-elasticsearch-exporter-1.10.0/LICENSE000066400000000000000000000261351511562765300214710ustar00rootroot00000000000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. prometheus-elasticsearch-exporter-1.10.0/MAINTAINERS.md000066400000000000000000000001241511562765300225460ustar00rootroot00000000000000* Ben Kochie @SuperQ * Joe Adams @sysadmind prometheus-elasticsearch-exporter-1.10.0/Makefile000066400000000000000000000005271511562765300221210ustar00rootroot00000000000000# Ensure that 'all' is the default target otherwise it will be the first target from Makefile.common. all:: # Needs to be defined before including Makefile.common to auto-generate targets DOCKER_ARCHS ?= amd64 armv7 arm64 ppc64le DOCKER_REPO ?= prometheuscommunity include Makefile.common DOCKER_IMAGE_NAME ?= elasticsearch-exporter prometheus-elasticsearch-exporter-1.10.0/Makefile.common000066400000000000000000000227341511562765300234140ustar00rootroot00000000000000# Copyright 2018 The Prometheus Authors # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # A common Makefile that includes rules to be reused in different prometheus projects. # !!! Open PRs only against the prometheus/prometheus/Makefile.common repository! # Example usage : # Create the main Makefile in the root project directory. # include Makefile.common # customTarget: # @echo ">> Running customTarget" # # Ensure GOBIN is not set during build so that promu is installed to the correct path unexport GOBIN GO ?= go GOFMT ?= $(GO)fmt FIRST_GOPATH := $(firstword $(subst :, ,$(shell $(GO) env GOPATH))) GOOPTS ?= GOHOSTOS ?= $(shell $(GO) env GOHOSTOS) GOHOSTARCH ?= $(shell $(GO) env GOHOSTARCH) GO_VERSION ?= $(shell $(GO) version) GO_VERSION_NUMBER ?= $(word 3, $(GO_VERSION)) PRE_GO_111 ?= $(shell echo $(GO_VERSION_NUMBER) | grep -E 'go1\.(10|[0-9])\.') PROMU := $(FIRST_GOPATH)/bin/promu pkgs = ./... ifeq (arm, $(GOHOSTARCH)) GOHOSTARM ?= $(shell GOARM= $(GO) env GOARM) GO_BUILD_PLATFORM ?= $(GOHOSTOS)-$(GOHOSTARCH)v$(GOHOSTARM) else GO_BUILD_PLATFORM ?= $(GOHOSTOS)-$(GOHOSTARCH) endif GOTEST := $(GO) test GOTEST_DIR := ifneq ($(CIRCLE_JOB),) ifneq ($(shell command -v gotestsum 2> /dev/null),) GOTEST_DIR := test-results GOTEST := gotestsum --junitfile $(GOTEST_DIR)/unit-tests.xml -- endif endif PROMU_VERSION ?= 0.17.0 PROMU_URL := https://github.com/prometheus/promu/releases/download/v$(PROMU_VERSION)/promu-$(PROMU_VERSION).$(GO_BUILD_PLATFORM).tar.gz SKIP_GOLANGCI_LINT := GOLANGCI_LINT := GOLANGCI_LINT_OPTS ?= GOLANGCI_LINT_VERSION ?= v2.6.2 GOLANGCI_FMT_OPTS ?= # golangci-lint only supports linux, darwin and windows platforms on i386/amd64/arm64. # windows isn't included here because of the path separator being different. ifeq ($(GOHOSTOS),$(filter $(GOHOSTOS),linux darwin)) ifeq ($(GOHOSTARCH),$(filter $(GOHOSTARCH),amd64 i386 arm64)) # If we're in CI and there is an Actions file, that means the linter # is being run in Actions, so we don't need to run it here. ifneq (,$(SKIP_GOLANGCI_LINT)) GOLANGCI_LINT := else ifeq (,$(CIRCLE_JOB)) GOLANGCI_LINT := $(FIRST_GOPATH)/bin/golangci-lint else ifeq (,$(wildcard .github/workflows/golangci-lint.yml)) GOLANGCI_LINT := $(FIRST_GOPATH)/bin/golangci-lint endif endif endif PREFIX ?= $(shell pwd) BIN_DIR ?= $(shell pwd) DOCKER_IMAGE_TAG ?= $(subst /,-,$(shell git rev-parse --abbrev-ref HEAD)) DOCKERFILE_PATH ?= ./Dockerfile DOCKERBUILD_CONTEXT ?= ./ DOCKER_REPO ?= prom DOCKER_ARCHS ?= amd64 BUILD_DOCKER_ARCHS = $(addprefix common-docker-,$(DOCKER_ARCHS)) PUBLISH_DOCKER_ARCHS = $(addprefix common-docker-publish-,$(DOCKER_ARCHS)) TAG_DOCKER_ARCHS = $(addprefix common-docker-tag-latest-,$(DOCKER_ARCHS)) SANITIZED_DOCKER_IMAGE_TAG := $(subst +,-,$(DOCKER_IMAGE_TAG)) ifeq ($(GOHOSTARCH),amd64) ifeq ($(GOHOSTOS),$(filter $(GOHOSTOS),linux freebsd darwin windows)) # Only supported on amd64 test-flags := -race endif endif # This rule is used to forward a target like "build" to "common-build". This # allows a new "build" target to be defined in a Makefile which includes this # one and override "common-build" without override warnings. %: common-% ; .PHONY: common-all common-all: precheck style check_license lint yamllint unused build test .PHONY: common-style common-style: @echo ">> checking code style" @fmtRes=$$($(GOFMT) -d $$(git ls-files '*.go' ':!:vendor/*' || find . -path ./vendor -prune -o -name '*.go' -print)); \ if [ -n "$${fmtRes}" ]; then \ echo "gofmt checking failed!"; echo "$${fmtRes}"; echo; \ echo "Please ensure you are using $$($(GO) version) for formatting code."; \ exit 1; \ fi .PHONY: common-check_license common-check_license: @echo ">> checking license header" @licRes=$$(for file in $$(git ls-files '*.go' ':!:vendor/*' || find . -path ./vendor -prune -o -type f -iname '*.go' -print) ; do \ awk 'NR<=3' $$file | grep -Eq "(Copyright|generated|GENERATED)" || echo $$file; \ done); \ if [ -n "$${licRes}" ]; then \ echo "license header checking failed:"; echo "$${licRes}"; \ exit 1; \ fi .PHONY: common-deps common-deps: @echo ">> getting dependencies" $(GO) mod download .PHONY: update-go-deps update-go-deps: @echo ">> updating Go dependencies" @for m in $$($(GO) list -mod=readonly -m -f '{{ if and (not .Indirect) (not .Main)}}{{.Path}}{{end}}' all); do \ $(GO) get $$m; \ done $(GO) mod tidy .PHONY: common-test-short common-test-short: $(GOTEST_DIR) @echo ">> running short tests" $(GOTEST) -short $(GOOPTS) $(pkgs) .PHONY: common-test common-test: $(GOTEST_DIR) @echo ">> running all tests" $(GOTEST) $(test-flags) $(GOOPTS) $(pkgs) $(GOTEST_DIR): @mkdir -p $@ .PHONY: common-format common-format: $(GOLANGCI_LINT) @echo ">> formatting code" $(GO) fmt $(pkgs) ifdef GOLANGCI_LINT @echo ">> formatting code with golangci-lint" $(GOLANGCI_LINT) fmt $(GOLANGCI_FMT_OPTS) endif .PHONY: common-vet common-vet: @echo ">> vetting code" $(GO) vet $(GOOPTS) $(pkgs) .PHONY: common-lint common-lint: $(GOLANGCI_LINT) ifdef GOLANGCI_LINT @echo ">> running golangci-lint" $(GOLANGCI_LINT) run $(GOLANGCI_LINT_OPTS) $(pkgs) endif .PHONY: common-lint-fix common-lint-fix: $(GOLANGCI_LINT) ifdef GOLANGCI_LINT @echo ">> running golangci-lint fix" $(GOLANGCI_LINT) run --fix $(GOLANGCI_LINT_OPTS) $(pkgs) endif .PHONY: common-yamllint common-yamllint: @echo ">> running yamllint on all YAML files in the repository" ifeq (, $(shell command -v yamllint 2> /dev/null)) @echo "yamllint not installed so skipping" else yamllint . endif # For backward-compatibility. .PHONY: common-staticcheck common-staticcheck: lint .PHONY: common-unused common-unused: @echo ">> running check for unused/missing packages in go.mod" $(GO) mod tidy @git diff --exit-code -- go.sum go.mod .PHONY: common-build common-build: promu @echo ">> building binaries" $(PROMU) build --prefix $(PREFIX) $(PROMU_BINARIES) .PHONY: common-tarball common-tarball: promu @echo ">> building release tarball" $(PROMU) tarball --prefix $(PREFIX) $(BIN_DIR) .PHONY: common-docker-repo-name common-docker-repo-name: @echo "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)" .PHONY: common-docker $(BUILD_DOCKER_ARCHS) common-docker: $(BUILD_DOCKER_ARCHS) $(BUILD_DOCKER_ARCHS): common-docker-%: docker build -t "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:$(SANITIZED_DOCKER_IMAGE_TAG)" \ -f $(DOCKERFILE_PATH) \ --build-arg ARCH="$*" \ --build-arg OS="linux" \ $(DOCKERBUILD_CONTEXT) .PHONY: common-docker-publish $(PUBLISH_DOCKER_ARCHS) common-docker-publish: $(PUBLISH_DOCKER_ARCHS) $(PUBLISH_DOCKER_ARCHS): common-docker-publish-%: docker push "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:$(SANITIZED_DOCKER_IMAGE_TAG)" DOCKER_MAJOR_VERSION_TAG = $(firstword $(subst ., ,$(shell cat VERSION))) .PHONY: common-docker-tag-latest $(TAG_DOCKER_ARCHS) common-docker-tag-latest: $(TAG_DOCKER_ARCHS) $(TAG_DOCKER_ARCHS): common-docker-tag-latest-%: docker tag "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:$(SANITIZED_DOCKER_IMAGE_TAG)" "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:latest" docker tag "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:$(SANITIZED_DOCKER_IMAGE_TAG)" "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$*:v$(DOCKER_MAJOR_VERSION_TAG)" .PHONY: common-docker-manifest common-docker-manifest: DOCKER_CLI_EXPERIMENTAL=enabled docker manifest create -a "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME):$(SANITIZED_DOCKER_IMAGE_TAG)" $(foreach ARCH,$(DOCKER_ARCHS),$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME)-linux-$(ARCH):$(SANITIZED_DOCKER_IMAGE_TAG)) DOCKER_CLI_EXPERIMENTAL=enabled docker manifest push "$(DOCKER_REPO)/$(DOCKER_IMAGE_NAME):$(SANITIZED_DOCKER_IMAGE_TAG)" .PHONY: promu promu: $(PROMU) $(PROMU): $(eval PROMU_TMP := $(shell mktemp -d)) curl -s -L $(PROMU_URL) | tar -xvzf - -C $(PROMU_TMP) mkdir -p $(FIRST_GOPATH)/bin cp $(PROMU_TMP)/promu-$(PROMU_VERSION).$(GO_BUILD_PLATFORM)/promu $(FIRST_GOPATH)/bin/promu rm -r $(PROMU_TMP) .PHONY: common-proto common-proto: @echo ">> generating code from proto files" @./scripts/genproto.sh ifdef GOLANGCI_LINT $(GOLANGCI_LINT): mkdir -p $(FIRST_GOPATH)/bin curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/$(GOLANGCI_LINT_VERSION)/install.sh \ | sed -e '/install -d/d' \ | sh -s -- -b $(FIRST_GOPATH)/bin $(GOLANGCI_LINT_VERSION) endif .PHONY: common-print-golangci-lint-version common-print-golangci-lint-version: @echo $(GOLANGCI_LINT_VERSION) .PHONY: precheck precheck:: define PRECHECK_COMMAND_template = precheck:: $(1)_precheck PRECHECK_COMMAND_$(1) ?= $(1) $$(strip $$(PRECHECK_OPTIONS_$(1))) .PHONY: $(1)_precheck $(1)_precheck: @if ! $$(PRECHECK_COMMAND_$(1)) 1>/dev/null 2>&1; then \ echo "Execution of '$$(PRECHECK_COMMAND_$(1))' command failed. Is $(1) installed?"; \ exit 1; \ fi endef govulncheck: install-govulncheck govulncheck ./... install-govulncheck: command -v govulncheck > /dev/null || go install golang.org/x/vuln/cmd/govulncheck@latest prometheus-elasticsearch-exporter-1.10.0/NOTICE000066400000000000000000000001361511562765300213610ustar00rootroot00000000000000Copyright 2015 Eric Richardson Copyright 2017 JustWatch Copyright 2021 The Prometheus Authors prometheus-elasticsearch-exporter-1.10.0/README.md000066400000000000000000000502501511562765300217360ustar00rootroot00000000000000# Elasticsearch Exporter [![CircleCI](https://circleci.com/gh/prometheus-community/elasticsearch_exporter.svg?style=svg)](https://circleci.com/gh/prometheus-community/elasticsearch_exporter) [![Go Report Card](https://goreportcard.com/badge/github.com/prometheus-community/elasticsearch_exporter)](https://goreportcard.com/report/github.com/prometheus-community/elasticsearch_exporter) Prometheus exporter for various metrics about Elasticsearch and OpenSearch, written in Go. ## Supported Versions We support all currently supported versions of Elasticsearch and OpenSearch. This project will make reasonable attempts to maintain compatibility with previous versions but considerations will be made for code maintainability and favoring supported versions. Where Elasticsearch and OpenSearch diverge, this project will make reasonable attempts to maintain compatibility with both. Some collectors may only be compatible with one or the other. ### Installation For pre-built binaries please take a look at the releases. #### Docker ```bash docker pull quay.io/prometheuscommunity/elasticsearch-exporter:latest docker run --rm -p 9114:9114 quay.io/prometheuscommunity/elasticsearch-exporter:latest ``` Example `docker-compose.yml`: ```yaml elasticsearch_exporter: image: quay.io/prometheuscommunity/elasticsearch-exporter:latest command: - '--es.uri=http://elasticsearch:9200' restart: always ports: - "127.0.0.1:9114:9114" ``` #### Kubernetes You can find a helm chart in the prometheus-community charts repository at ```bash helm repo add prometheus-community https://prometheus-community.github.io/helm-charts helm install [RELEASE_NAME] prometheus-community/prometheus-elasticsearch-exporter ``` ### Configuration **NOTE:** The exporter fetches information from an Elasticsearch cluster on every scrape, therefore having a too short scrape interval can impose load on ES master nodes, particularly if you run with `--es.all` and `--es.indices`. We suggest you measure how long fetching `/_nodes/stats` and `/_all/_stats` takes for your ES cluster to determine whether your scraping interval is too short. As a last resort, you can scrape this exporter using a dedicated job with its own scraping interval. Below is the command line options summary: ```bash elasticsearch_exporter --help ``` | Argument | Introduced in Version | Description | Default | | ----------------------- | --------------------- |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| ----------- | | collector.clustersettings| 1.6.0 | If true, query stats for cluster settings (As of v1.6.0, this flag has replaced "es.cluster_settings"). | false | | es.uri | 1.0.2 | Address (host and port) of the Elasticsearch node we should connect to **when running in single-target mode**. Leave empty (the default) when you want to run the exporter only as a multi-target `/probe` endpoint. When basic auth is needed, specify as: `://:@:`. E.G., `http://admin:pass@localhost:9200`. Special characters in the user credentials need to be URL-encoded. | "" | | es.all | 1.0.2 | If true, query stats for all nodes in the cluster, rather than just the node we connect to. | false | | es.indices | 1.0.2 | If true, query stats for all indices in the cluster. | false | | es.indices_settings | 1.0.4rc1 | If true, query settings stats for all indices in the cluster. | false | | es.indices_mappings | 1.2.0 | If true, query stats for mappings of all indices of the cluster. | false | | es.aliases | 1.0.4rc1 | If true, include informational aliases metrics. | true | | es.ilm | 1.6.0 | If true, query index lifecycle policies for indices in the cluster. | es.shards | 1.0.3rc1 | If true, query stats for all indices in the cluster, including shard-level stats (implies `es.indices=true`). | false | | collector.snapshots | 1.0.4rc1 | If true, query stats for the cluster snapshots. (As of v1.7.0, this flag has replaced "es.snapshots"). | false | | collector.health-report | 1.10.0 | If true, query the health report (requires elasticsearch 8.7.0 or later) | false | | es.slm | | If true, query stats for SLM. | false | | es.data_stream | | If true, query state for Data Steams. | false | | es.timeout | 1.0.2 | Timeout for trying to get stats from Elasticsearch. (ex: 20s) | 5s | | es.ca | 1.0.2 | Path to PEM file that contains trusted Certificate Authorities for the Elasticsearch connection. | | | es.client-private-key | 1.0.2 | Path to PEM file that contains the private key for client auth when connecting to Elasticsearch. | | | es.client-cert | 1.0.2 | Path to PEM file that contains the corresponding cert for the private key to connect to Elasticsearch. | | | es.clusterinfo.interval | 1.1.0rc1 | Cluster info update interval for the cluster label | 5m | | es.ssl-skip-verify | 1.0.4rc1 | Skip SSL verification when connecting to Elasticsearch. | false | | web.listen-address | 1.0.2 | Address to listen on for web interface and telemetry. | :9114 | | web.telemetry-path | 1.0.2 | Path under which to expose metrics. | /metrics | | aws.region | 1.5.0 | Region for AWS elasticsearch | | | aws.role-arn | 1.6.0 | Role ARN of an IAM role to assume. | | | config.file | 1.10.0 | Path to a YAML configuration file that defines `auth_modules:` used by the `/probe` multi-target endpoint. Leave unset when not using multi-target mode. | | | version | 1.0.2 | Show version info on stdout and exit. | | Commandline parameters start with a single `-` for versions less than `1.1.0rc1`. For versions greater than `1.1.0rc1`, commandline parameters are specified with `--`. The API key used to connect can be set with the `ES_API_KEY` environment variable. #### Logging Logging by the exporter is handled by the `log/slog` package. The output format can be customized with the `--log.format` flag which defaults to logfmt. The log level can be set with the `--log.level` flag which defaults to info. The output can be set to either stdout (default) or stderr with the `--log.output` flag. #### Elasticsearch 7.x security privileges Username and password can be passed either directly in the URI or through the `ES_USERNAME` and `ES_PASSWORD` environment variables. Specifying those two environment variables will override authentication passed in the URI (if any). ES 7.x supports RBACs. The following security privileges are required for the elasticsearch_exporter. Setting | Privilege Required | Description :---- | :---- | :---- collector.clustersettings| `cluster` `monitor` | exporter defaults | `cluster` `monitor` | All cluster read-only operations, like cluster health and state, hot threads, node info, node and cluster stats, and pending cluster tasks. | es.indices | `indices` `monitor` (per index or `*`) | All actions that are required for monitoring (recovery, segments info, index stats and status) es.indices_settings | `indices` `monitor` (per index or `*`) | es.indices_mappings | `indices` `view_index_metadata` (per index or `*`) | es.shards | not sure if `indices` or `cluster` `monitor` or both | collector.snapshots | `cluster:admin/snapshot/status` and `cluster:admin/repository/get` | [ES Forum Post](https://discuss.elastic.co/t/permissions-for-backup-user-with-x-pack/88057) es.slm | `manage_slm` es.data_stream | `monitor` or `manage` (per index or `*`) | Further Information - [Built in Users](https://www.elastic.co/guide/en/elastic-stack-overview/7.3/built-in-users.html) - [Defining Roles](https://www.elastic.co/guide/en/elastic-stack-overview/7.3/defining-roles.html) - [Privileges](https://www.elastic.co/guide/en/elastic-stack-overview/7.3/security-privileges.html) ### Multi-Target Scraping (beta) From v2.X the exporter exposes `/probe` allowing one running instance to scrape many clusters. Supported `auth_module` types: | type | YAML fields | Injected into request | | ---------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------- | | `userpass` | `userpass.username`, `userpass.password`, optional `options:` map | Sets HTTP basic-auth header, appends `options` as query parameters | | `apikey` | `apikey:` Base64 API-Key string, optional `options:` map | Adds `Authorization: ApiKey …` header, appends `options` | | `aws` | `aws.region`, optional `aws.role_arn`, optional `options:` map | Uses AWS SigV4 signing transport for HTTP(S) requests, appends `options` | | `tls` | `tls.ca_file`, `tls.cert_file`, `tls.key_file` | Uses client certificate authentication via TLS; cannot be mixed with other auth types | Example config: ```yaml # exporter-config.yml auth_modules: prod_basic: type: userpass userpass: username: metrics password: s3cr3t staging_key: type: apikey apikey: "bXk6YXBpa2V5Ig==" # base64 id:key options: sslmode: disable ``` Run exporter: ```bash ./elasticsearch_exporter --config.file=exporter-config.yml ``` Prometheus scrape_config: ```yaml - job_name: es metrics_path: /probe params: auth_module: [staging_key] static_configs: - targets: ["https://es-stage:9200"] relabel_configs: - source_labels: [__address__] target_label: __param_target - source_labels: [__param_target] target_label: instance - target_label: __address__ replacement: exporter:9114 ``` Notes: - `/metrics` serves a single, process-wide registry and is intended for single-target mode. - `/probe` creates a fresh registry per scrape for the given `target` allowing multi-target scraping. - Any `options:` under an auth module will be appended as URL query parameters to the target URL. - The `tls` auth module (client certificate authentication) is intended for self‑managed Elasticsearch/OpenSearch deployments. Amazon OpenSearch Service typically authenticates at the domain edge with IAM/SigV4 and does not support client certificate authentication; use the `aws` auth module instead when scraping Amazon OpenSearch Service domains. ### Metrics See the [metrics documentation](metrics.md) ### Alerts & Recording Rules We provide examples for [Prometheus](http://prometheus.io) [alerts and recording rules](examples/prometheus/elasticsearch.rules) as well as an [Grafana](http://www.grafana.org) [Dashboard](examples/grafana/dashboard.json) and a [Kubernetes](http://kubernetes.io) [Deployment](examples/kubernetes/deployment.yml). The example dashboard needs the [node_exporter](https://github.com/prometheus/node_exporter) installed. In order to select the nodes that belong to the Elasticsearch cluster, we rely on a label `cluster`. Depending on your setup, it can derived from the platform metadata: For example on [GCE](https://cloud.google.com) ``` - source_labels: [__meta_gce_metadata_Cluster] separator: ; regex: (.*) target_label: cluster replacement: ${1} action: replace ``` Please refer to the [Prometheus SD documentation](https://prometheus.io/docs/operating/configuration/) to see which metadata labels can be used to create the `cluster` label. ## Credit & License `elasticsearch_exporter` is maintained by the [Prometheus Community](https://www.prometheus.io/community/). `elasticsearch_exporter` was then maintained by the nice folks from [JustWatch](https://www.justwatch.com/). Then transferred this repository to the Prometheus Community in May 2021. This package was originally created and maintained by [Eric Richardson](https://github.com/ewr), who transferred this repository to us in January 2017. Please refer to the Git commit log for a complete list of contributors. ## Contributing We welcome any contributions. Please fork the project on GitHub and open Pull Requests for any proposed changes. Please note that we will not merge any changes that encourage insecure behaviour. If in doubt please open an Issue first to discuss your proposal. prometheus-elasticsearch-exporter-1.10.0/SECURITY.md000066400000000000000000000002541511562765300222470ustar00rootroot00000000000000# Reporting a security issue The Prometheus security policy, including how to report vulnerabilities, can be found here: prometheus-elasticsearch-exporter-1.10.0/VERSION000066400000000000000000000000071511562765300215220ustar00rootroot000000000000001.10.0 prometheus-elasticsearch-exporter-1.10.0/collector/000077500000000000000000000000001511562765300224435ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/collector/cluster_health.go000066400000000000000000000176761511562765300260210ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "path" "github.com/prometheus/client_golang/prometheus" ) var ( colors = []string{"green", "yellow", "red"} defaultClusterHealthLabels = []string{"cluster"} ) type clusterHealthMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(clusterHealth clusterHealthResponse) float64 } type clusterHealthStatusMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(clusterHealth clusterHealthResponse, color string) float64 Labels func(clusterName, color string) []string } // ClusterHealth type defines the collector struct type ClusterHealth struct { logger *slog.Logger client *http.Client url *url.URL metrics []*clusterHealthMetric statusMetric *clusterHealthStatusMetric } // NewClusterHealth returns a new Collector exposing ClusterHealth stats. func NewClusterHealth(logger *slog.Logger, client *http.Client, url *url.URL) *ClusterHealth { subsystem := "cluster_health" return &ClusterHealth{ logger: logger, client: client, url: url, metrics: []*clusterHealthMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "active_primary_shards"), "The number of primary shards in your cluster. This is an aggregate total across all indices.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.ActivePrimaryShards) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "active_shards"), "Aggregate total of all shards across all indices, which includes replica shards.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.ActiveShards) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "delayed_unassigned_shards"), "Shards delayed to reduce reallocation overhead", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.DelayedUnassignedShards) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "initializing_shards"), "Count of shards that are being freshly created.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.InitializingShards) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "number_of_data_nodes"), "Number of data nodes in the cluster.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.NumberOfDataNodes) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "number_of_in_flight_fetch"), "The number of ongoing shard info requests.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.NumberOfInFlightFetch) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "task_max_waiting_in_queue_millis"), "Tasks max time waiting in queue.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.TaskMaxWaitingInQueueMillis) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "number_of_nodes"), "Number of nodes in the cluster.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.NumberOfNodes) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "number_of_pending_tasks"), "Cluster level changes which have not yet been executed", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.NumberOfPendingTasks) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "relocating_shards"), "The number of shards that are currently moving from one node to another node.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.RelocatingShards) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "unassigned_shards"), "The number of shards that exist in the cluster state, but cannot be found in the cluster itself.", defaultClusterHealthLabels, nil, ), Value: func(clusterHealth clusterHealthResponse) float64 { return float64(clusterHealth.UnassignedShards) }, }, }, statusMetric: &clusterHealthStatusMetric{ Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "status"), "Whether all primary and replica shards are allocated.", []string{"cluster", "color"}, nil, ), Value: func(clusterHealth clusterHealthResponse, color string) float64 { if clusterHealth.Status == color { return 1 } return 0 }, }, } } // Describe set Prometheus metrics descriptions. func (c *ClusterHealth) Describe(ch chan<- *prometheus.Desc) { for _, metric := range c.metrics { ch <- metric.Desc } ch <- c.statusMetric.Desc } func (c *ClusterHealth) fetchAndDecodeClusterHealth() (clusterHealthResponse, error) { var chr clusterHealthResponse u := *c.url u.Path = path.Join(u.Path, "/_cluster/health") res, err := c.client.Get(u.String()) if err != nil { return chr, fmt.Errorf("failed to get cluster health from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } defer func() { err = res.Body.Close() if err != nil { c.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return chr, fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } bts, err := io.ReadAll(res.Body) if err != nil { return chr, err } if err := json.Unmarshal(bts, &chr); err != nil { return chr, err } return chr, nil } // Collect collects ClusterHealth metrics. func (c *ClusterHealth) Collect(ch chan<- prometheus.Metric) { clusterHealthResp, err := c.fetchAndDecodeClusterHealth() if err != nil { c.logger.Warn( "failed to fetch and decode cluster health", "err", err, ) return } for _, metric := range c.metrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(clusterHealthResp), clusterHealthResp.ClusterName, ) } for _, color := range colors { ch <- prometheus.MustNewConstMetric( c.statusMetric.Desc, c.statusMetric.Type, c.statusMetric.Value(clusterHealthResp, color), clusterHealthResp.ClusterName, color, ) } } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_health_response.go000066400000000000000000000031431511562765300277170ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector type clusterHealthResponse struct { ClusterName string `json:"cluster_name"` Status string `json:"status"` TimedOut bool `json:"timed_out"` NumberOfNodes int `json:"number_of_nodes"` NumberOfDataNodes int `json:"number_of_data_nodes"` ActivePrimaryShards int `json:"active_primary_shards"` ActiveShards int `json:"active_shards"` RelocatingShards int `json:"relocating_shards"` InitializingShards int `json:"initializing_shards"` UnassignedShards int `json:"unassigned_shards"` DelayedUnassignedShards int `json:"delayed_unassigned_shards"` NumberOfPendingTasks int `json:"number_of_pending_tasks"` NumberOfInFlightFetch int `json:"number_of_in_flight_fetch"` TaskMaxWaitingInQueueMillis int `json:"task_max_waiting_in_queue_millis"` ActiveShardsPercentAsNumber float64 `json:"active_shards_percent_as_number"` } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_health_test.go000066400000000000000000000274341511562765300270510ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestClusterHealth(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION-alpine // curl -XPUT http://localhost:9200/twitter // curl http://localhost:9200/_cluster/health tests := []struct { name string file string want string }{ { name: "1.7.6", file: "../fixtures/clusterhealth/1.7.6.json", want: ` # HELP elasticsearch_cluster_health_active_primary_shards The number of primary shards in your cluster. This is an aggregate total across all indices. # TYPE elasticsearch_cluster_health_active_primary_shards gauge elasticsearch_cluster_health_active_primary_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_active_shards Aggregate total of all shards across all indices, which includes replica shards. # TYPE elasticsearch_cluster_health_active_shards gauge elasticsearch_cluster_health_active_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_delayed_unassigned_shards Shards delayed to reduce reallocation overhead # TYPE elasticsearch_cluster_health_delayed_unassigned_shards gauge elasticsearch_cluster_health_delayed_unassigned_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_initializing_shards Count of shards that are being freshly created. # TYPE elasticsearch_cluster_health_initializing_shards gauge elasticsearch_cluster_health_initializing_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_data_nodes Number of data nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_data_nodes gauge elasticsearch_cluster_health_number_of_data_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_in_flight_fetch The number of ongoing shard info requests. # TYPE elasticsearch_cluster_health_number_of_in_flight_fetch gauge elasticsearch_cluster_health_number_of_in_flight_fetch{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_nodes Number of nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_nodes gauge elasticsearch_cluster_health_number_of_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_pending_tasks Cluster level changes which have not yet been executed # TYPE elasticsearch_cluster_health_number_of_pending_tasks gauge elasticsearch_cluster_health_number_of_pending_tasks{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_relocating_shards The number of shards that are currently moving from one node to another node. # TYPE elasticsearch_cluster_health_relocating_shards gauge elasticsearch_cluster_health_relocating_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_status Whether all primary and replica shards are allocated. # TYPE elasticsearch_cluster_health_status gauge elasticsearch_cluster_health_status{cluster="elasticsearch",color="green"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="red"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="yellow"} 1 # HELP elasticsearch_cluster_health_task_max_waiting_in_queue_millis Tasks max time waiting in queue. # TYPE elasticsearch_cluster_health_task_max_waiting_in_queue_millis gauge elasticsearch_cluster_health_task_max_waiting_in_queue_millis{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_unassigned_shards The number of shards that exist in the cluster state, but cannot be found in the cluster itself. # TYPE elasticsearch_cluster_health_unassigned_shards gauge elasticsearch_cluster_health_unassigned_shards{cluster="elasticsearch"} 5 `, }, { name: "2.4.5", file: "../fixtures/clusterhealth/2.4.5.json", want: ` # HELP elasticsearch_cluster_health_active_primary_shards The number of primary shards in your cluster. This is an aggregate total across all indices. # TYPE elasticsearch_cluster_health_active_primary_shards gauge elasticsearch_cluster_health_active_primary_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_active_shards Aggregate total of all shards across all indices, which includes replica shards. # TYPE elasticsearch_cluster_health_active_shards gauge elasticsearch_cluster_health_active_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_delayed_unassigned_shards Shards delayed to reduce reallocation overhead # TYPE elasticsearch_cluster_health_delayed_unassigned_shards gauge elasticsearch_cluster_health_delayed_unassigned_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_initializing_shards Count of shards that are being freshly created. # TYPE elasticsearch_cluster_health_initializing_shards gauge elasticsearch_cluster_health_initializing_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_data_nodes Number of data nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_data_nodes gauge elasticsearch_cluster_health_number_of_data_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_in_flight_fetch The number of ongoing shard info requests. # TYPE elasticsearch_cluster_health_number_of_in_flight_fetch gauge elasticsearch_cluster_health_number_of_in_flight_fetch{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_nodes Number of nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_nodes gauge elasticsearch_cluster_health_number_of_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_pending_tasks Cluster level changes which have not yet been executed # TYPE elasticsearch_cluster_health_number_of_pending_tasks gauge elasticsearch_cluster_health_number_of_pending_tasks{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_relocating_shards The number of shards that are currently moving from one node to another node. # TYPE elasticsearch_cluster_health_relocating_shards gauge elasticsearch_cluster_health_relocating_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_status Whether all primary and replica shards are allocated. # TYPE elasticsearch_cluster_health_status gauge elasticsearch_cluster_health_status{cluster="elasticsearch",color="green"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="red"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="yellow"} 1 # HELP elasticsearch_cluster_health_task_max_waiting_in_queue_millis Tasks max time waiting in queue. # TYPE elasticsearch_cluster_health_task_max_waiting_in_queue_millis gauge elasticsearch_cluster_health_task_max_waiting_in_queue_millis{cluster="elasticsearch"} 12 # HELP elasticsearch_cluster_health_unassigned_shards The number of shards that exist in the cluster state, but cannot be found in the cluster itself. # TYPE elasticsearch_cluster_health_unassigned_shards gauge elasticsearch_cluster_health_unassigned_shards{cluster="elasticsearch"} 5 `, }, { name: "5.4.2", file: "../fixtures/clusterhealth/5.4.2.json", want: ` # HELP elasticsearch_cluster_health_active_primary_shards The number of primary shards in your cluster. This is an aggregate total across all indices. # TYPE elasticsearch_cluster_health_active_primary_shards gauge elasticsearch_cluster_health_active_primary_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_active_shards Aggregate total of all shards across all indices, which includes replica shards. # TYPE elasticsearch_cluster_health_active_shards gauge elasticsearch_cluster_health_active_shards{cluster="elasticsearch"} 5 # HELP elasticsearch_cluster_health_delayed_unassigned_shards Shards delayed to reduce reallocation overhead # TYPE elasticsearch_cluster_health_delayed_unassigned_shards gauge elasticsearch_cluster_health_delayed_unassigned_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_initializing_shards Count of shards that are being freshly created. # TYPE elasticsearch_cluster_health_initializing_shards gauge elasticsearch_cluster_health_initializing_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_data_nodes Number of data nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_data_nodes gauge elasticsearch_cluster_health_number_of_data_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_in_flight_fetch The number of ongoing shard info requests. # TYPE elasticsearch_cluster_health_number_of_in_flight_fetch gauge elasticsearch_cluster_health_number_of_in_flight_fetch{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_number_of_nodes Number of nodes in the cluster. # TYPE elasticsearch_cluster_health_number_of_nodes gauge elasticsearch_cluster_health_number_of_nodes{cluster="elasticsearch"} 1 # HELP elasticsearch_cluster_health_number_of_pending_tasks Cluster level changes which have not yet been executed # TYPE elasticsearch_cluster_health_number_of_pending_tasks gauge elasticsearch_cluster_health_number_of_pending_tasks{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_relocating_shards The number of shards that are currently moving from one node to another node. # TYPE elasticsearch_cluster_health_relocating_shards gauge elasticsearch_cluster_health_relocating_shards{cluster="elasticsearch"} 0 # HELP elasticsearch_cluster_health_status Whether all primary and replica shards are allocated. # TYPE elasticsearch_cluster_health_status gauge elasticsearch_cluster_health_status{cluster="elasticsearch",color="green"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="red"} 0 elasticsearch_cluster_health_status{cluster="elasticsearch",color="yellow"} 1 # HELP elasticsearch_cluster_health_task_max_waiting_in_queue_millis Tasks max time waiting in queue. # TYPE elasticsearch_cluster_health_task_max_waiting_in_queue_millis gauge elasticsearch_cluster_health_task_max_waiting_in_queue_millis{cluster="elasticsearch"} 12 # HELP elasticsearch_cluster_health_unassigned_shards The number of shards that exist in the cluster state, but cannot be found in the cluster itself. # TYPE elasticsearch_cluster_health_unassigned_shards gauge elasticsearch_cluster_health_unassigned_shards{cluster="elasticsearch"} 5 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c := NewClusterHealth(promslog.NewNopLogger(), http.DefaultClient, u) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(c, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_info.go000066400000000000000000000053321511562765300254710ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "io" "log/slog" "net/http" "net/url" "github.com/blang/semver/v4" "github.com/prometheus/client_golang/prometheus" ) func init() { registerCollector("cluster-info", defaultEnabled, NewClusterInfo) } type ClusterInfoCollector struct { logger *slog.Logger u *url.URL hc *http.Client } func NewClusterInfo(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &ClusterInfoCollector{ logger: logger, u: u, hc: hc, }, nil } var clusterInfoDesc = map[string]*prometheus.Desc{ "version": prometheus.NewDesc( prometheus.BuildFQName(namespace, "", "version"), "Elasticsearch version information.", []string{ "cluster", "cluster_uuid", "build_date", "build_hash", "version", "lucene_version", }, nil, ), } // ClusterInfoResponse is the cluster info retrievable from the / endpoint type ClusterInfoResponse struct { Name string `json:"name"` ClusterName string `json:"cluster_name"` ClusterUUID string `json:"cluster_uuid"` Version VersionInfo `json:"version"` Tagline string `json:"tagline"` } // VersionInfo is the version info retrievable from the / endpoint, embedded in ClusterInfoResponse type VersionInfo struct { Number semver.Version `json:"number"` BuildHash string `json:"build_hash"` BuildDate string `json:"build_date"` BuildSnapshot bool `json:"build_snapshot"` LuceneVersion semver.Version `json:"lucene_version"` } func (c *ClusterInfoCollector) Update(_ context.Context, ch chan<- prometheus.Metric) error { resp, err := c.hc.Get(c.u.String()) if err != nil { return err } defer resp.Body.Close() b, err := io.ReadAll(resp.Body) if err != nil { return err } var info ClusterInfoResponse err = json.Unmarshal(b, &info) if err != nil { return err } ch <- prometheus.MustNewConstMetric( clusterInfoDesc["version"], prometheus.GaugeValue, 1, info.ClusterName, info.ClusterUUID, info.Version.BuildDate, info.Version.BuildHash, info.Version.Number.String(), info.Version.LuceneVersion.String(), ) return nil } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_info_test.go000066400000000000000000000056301511562765300265310ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestClusterInfo(t *testing.T) { // Testcases created using: // docker run -p 9200:9200 -e "discovery.type=single-node" elasticsearch:${VERSION} // curl http://localhost:9200/ > fixtures/cluster_info/${VERSION}.json tests := []struct { name string file string want string }{ { name: "2.4.5", file: "../fixtures/clusterinfo/2.4.5.json", want: `# HELP elasticsearch_version Elasticsearch version information. # TYPE elasticsearch_version gauge elasticsearch_version{build_date="",build_hash="c849dd13904f53e63e88efc33b2ceeda0b6a1276",cluster="elasticsearch",cluster_uuid="3qps7bcWTqyzV49ApmPVfw",lucene_version="5.5.4",version="2.4.5"} 1 `, }, { name: "5.4.2", file: "../fixtures/clusterinfo/5.4.2.json", want: `# HELP elasticsearch_version Elasticsearch version information. # TYPE elasticsearch_version gauge elasticsearch_version{build_date="2017-06-15T02:29:28.122Z",build_hash="929b078",cluster="elasticsearch",cluster_uuid="kbqi7yhQT-WlPdGL2m0xJg",lucene_version="6.5.1",version="5.4.2"} 1 `, }, { name: "7.13.1", file: "../fixtures/clusterinfo/7.13.1.json", want: `# HELP elasticsearch_version Elasticsearch version information. # TYPE elasticsearch_version gauge elasticsearch_version{build_date="2021-05-28T17:40:59.346932922Z",build_hash="9a7758028e4ea59bcab41c12004603c5a7dd84a9",cluster="docker-cluster",cluster_uuid="aCMrCY1VQpqJ6U4Sw_xdiw",lucene_version="8.8.2",version="7.13.1"} 1 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewClusterInfo(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_settings.go000066400000000000000000000244601511562765300264010ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "strconv" "strings" "github.com/imdario/mergo" "github.com/prometheus/client_golang/prometheus" ) func init() { registerCollector("clustersettings", defaultDisabled, NewClusterSettings) } type ClusterSettingsCollector struct { logger *slog.Logger u *url.URL hc *http.Client } func NewClusterSettings(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &ClusterSettingsCollector{ logger: logger, u: u, hc: hc, }, nil } var clusterSettingsDesc = map[string]*prometheus.Desc{ "shardAllocationEnabled": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_stats", "shard_allocation_enabled"), "Current mode of cluster wide shard routing allocation settings.", nil, nil, ), "maxShardsPerNode": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_stats", "max_shards_per_node"), "Current maximum number of shards per node setting.", nil, nil, ), "thresholdEnabled": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation", "threshold_enabled"), "Is disk allocation decider enabled.", nil, nil, ), "floodStageRatio": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "flood_stage_ratio"), "Flood stage watermark as a ratio.", nil, nil, ), "highRatio": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "high_ratio"), "High watermark for disk usage as a ratio.", nil, nil, ), "lowRatio": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "low_ratio"), "Low watermark for disk usage as a ratio.", nil, nil, ), "floodStageBytes": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "flood_stage_bytes"), "Flood stage watermark as in bytes.", nil, nil, ), "highBytes": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "high_bytes"), "High watermark for disk usage in bytes.", nil, nil, ), "lowBytes": prometheus.NewDesc( prometheus.BuildFQName(namespace, "clustersettings_allocation_watermark", "low_bytes"), "Low watermark for disk usage in bytes.", nil, nil, ), } // clusterSettingsResponse is a representation of a Elasticsearch Cluster Settings type clusterSettingsResponse struct { Defaults clusterSettingsSection `json:"defaults"` Persistent clusterSettingsSection `json:"persistent"` Transient clusterSettingsSection `json:"transient"` } // clusterSettingsSection is a representation of a Elasticsearch Cluster Settings type clusterSettingsSection struct { Cluster clusterSettingsCluster `json:"cluster"` } // clusterSettingsCluster is a representation of a Elasticsearch clusterSettingsCluster Settings type clusterSettingsCluster struct { Routing clusterSettingsRouting `json:"routing"` // This can be either a JSON object (which does not contain the value we are interested in) or a string MaxShardsPerNode interface{} `json:"max_shards_per_node"` } // clusterSettingsRouting is a representation of a Elasticsearch Cluster shard routing configuration type clusterSettingsRouting struct { Allocation clusterSettingsAllocation `json:"allocation"` } // clusterSettingsAllocation is a representation of a Elasticsearch Cluster shard routing allocation settings type clusterSettingsAllocation struct { Enabled string `json:"enable"` Disk clusterSettingsDisk `json:"disk"` } // clusterSettingsDisk is a representation of a Elasticsearch Cluster shard routing disk allocation settings type clusterSettingsDisk struct { ThresholdEnabled string `json:"threshold_enabled"` Watermark clusterSettingsWatermark `json:"watermark"` } // clusterSettingsWatermark is representation of Elasticsearch Cluster shard routing disk allocation watermark settings type clusterSettingsWatermark struct { FloodStage interface{} `json:"flood_stage"` High interface{} `json:"high"` Low interface{} `json:"low"` } func (c *ClusterSettingsCollector) Update(ctx context.Context, ch chan<- prometheus.Metric) error { u := c.u.ResolveReference(&url.URL{Path: "_cluster/settings"}) q := u.Query() q.Set("include_defaults", "true") u.RawQuery = q.Encode() req, err := http.NewRequestWithContext(ctx, http.MethodGet, u.String(), nil) if err != nil { return err } resp, err := c.hc.Do(req) if err != nil { return err } defer resp.Body.Close() b, err := io.ReadAll(resp.Body) if err != nil { return err } var data clusterSettingsResponse err = json.Unmarshal(b, &data) if err != nil { return err } // Merge all settings into one struct merged := data.Defaults err = mergo.Merge(&merged, data.Persistent, mergo.WithOverride) if err != nil { return err } err = mergo.Merge(&merged, data.Transient, mergo.WithOverride) if err != nil { return err } // Max shards per node if maxShardsPerNodeString, ok := merged.Cluster.MaxShardsPerNode.(string); ok { maxShardsPerNode, err := strconv.ParseInt(maxShardsPerNodeString, 10, 64) if err == nil { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["maxShardsPerNode"], prometheus.GaugeValue, float64(maxShardsPerNode), ) } } // Shard allocation enabled shardAllocationMap := map[string]int{ "all": 0, "primaries": 1, "new_primaries": 2, "none": 3, } ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["shardAllocationEnabled"], prometheus.GaugeValue, float64(shardAllocationMap[merged.Cluster.Routing.Allocation.Enabled]), ) // Threshold enabled thresholdMap := map[string]int{ "false": 0, "true": 1, } ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["thresholdEnabled"], prometheus.GaugeValue, float64(thresholdMap[merged.Cluster.Routing.Allocation.Disk.ThresholdEnabled]), ) // Watermark bytes or ratio metrics watermarkFlood, err := parseWatermarkValue(merged.Cluster.Routing.Allocation.Disk.Watermark.FloodStage) if err != nil { c.logger.Error("failed to parse flood stage watermark", "err", err) } else { if strings.HasSuffix(watermarkFlood, "b") { floodStageBytes, err := getValueInBytes(watermarkFlood) if err != nil { c.logger.Error("failed to parse flood_stage bytes", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["floodStageBytes"], prometheus.GaugeValue, floodStageBytes, ) } } else { floodStageRatio, err := getValueAsRatio(watermarkFlood) if err != nil { c.logger.Error("failed to parse flood_stage ratio", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["floodStageRatio"], prometheus.GaugeValue, floodStageRatio, ) } } } watermarkHigh, err := parseWatermarkValue(merged.Cluster.Routing.Allocation.Disk.Watermark.High) if err != nil { c.logger.Error("failed to parse high watermark", "err", err) } else { if strings.HasSuffix(watermarkHigh, "b") { highBytes, err := getValueInBytes(watermarkHigh) if err != nil { c.logger.Error("failed to parse high bytes", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["highBytes"], prometheus.GaugeValue, highBytes, ) } } else { highRatio, err := getValueAsRatio(watermarkHigh) if err != nil { c.logger.Error("failed to parse high ratio", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["highRatio"], prometheus.GaugeValue, highRatio, ) } } } watermarkLow, err := parseWatermarkValue(merged.Cluster.Routing.Allocation.Disk.Watermark.Low) if err != nil { c.logger.Error("failed to parse low watermark", "err", err) } else { if strings.HasSuffix(watermarkLow, "b") { lowBytes, err := getValueInBytes(watermarkLow) if err != nil { c.logger.Error("failed to parse low bytes", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["lowBytes"], prometheus.GaugeValue, lowBytes, ) } } else { lowRatio, err := getValueAsRatio(watermarkLow) if err != nil { c.logger.Error("failed to parse low ratio", "err", err) } else { ch <- prometheus.MustNewConstMetric( clusterSettingsDesc["lowRatio"], prometheus.GaugeValue, lowRatio, ) } } } return nil } func parseWatermarkValue(value interface{}) (string, error) { switch v := value.(type) { case string: return v, nil case map[string]interface{}: if val, ok := v["value"].(string); ok { return val, nil } return "", fmt.Errorf("unexpected structure in watermark value: %v", v) default: return "", fmt.Errorf("unsupported type for watermark value: %T", v) } } func getValueInBytes(value string) (float64, error) { type UnitValue struct { unit string val float64 } unitValues := []UnitValue{ {"pb", 1024 * 1024 * 1024 * 1024 * 1024}, {"tb", 1024 * 1024 * 1024 * 1024}, {"gb", 1024 * 1024 * 1024}, {"mb", 1024 * 1024}, {"kb", 1024}, {"b", 1}, } for _, uv := range unitValues { if strings.HasSuffix(value, uv.unit) { numberStr := strings.TrimSuffix(value, uv.unit) number, err := strconv.ParseFloat(numberStr, 64) if err != nil { return 0, err } return number * uv.val, nil } } return 0, fmt.Errorf("failed to convert unit %s to bytes", value) } func getValueAsRatio(value string) (float64, error) { if strings.HasSuffix(value, "%") { percentValue, err := strconv.Atoi(strings.TrimSpace(strings.TrimSuffix(value, "%"))) if err != nil { return 0, err } return float64(percentValue) / 100, nil } ratio, err := strconv.ParseFloat(value, 64) if err != nil { return 0, err } return ratio, nil } prometheus-elasticsearch-exporter-1.10.0/collector/cluster_settings_test.go000066400000000000000000000231371511562765300274400ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestClusterSettingsStats(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION-alpine // curl http://localhost:9200/_cluster/settings/?include_defaults=true tests := []struct { name string file string want string }{ // MaxShardsPerNode is empty in older versions { name: "5.4.2", file: "../fixtures/settings-5.4.2.json", want: ` # HELP elasticsearch_clustersettings_stats_shard_allocation_enabled Current mode of cluster wide shard routing allocation settings. # TYPE elasticsearch_clustersettings_stats_shard_allocation_enabled gauge elasticsearch_clustersettings_stats_shard_allocation_enabled 0 # HELP elasticsearch_clustersettings_allocation_threshold_enabled Is disk allocation decider enabled. # TYPE elasticsearch_clustersettings_allocation_threshold_enabled gauge elasticsearch_clustersettings_allocation_threshold_enabled 1 # HELP elasticsearch_clustersettings_allocation_watermark_high_ratio High watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_high_ratio gauge elasticsearch_clustersettings_allocation_watermark_high_ratio 0.9 # HELP elasticsearch_clustersettings_allocation_watermark_low_ratio Low watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_low_ratio gauge elasticsearch_clustersettings_allocation_watermark_low_ratio 0.85 `, }, { name: "5.4.2-merge", file: "../fixtures/settings-merge-5.4.2.json", want: ` # HELP elasticsearch_clustersettings_stats_shard_allocation_enabled Current mode of cluster wide shard routing allocation settings. # TYPE elasticsearch_clustersettings_stats_shard_allocation_enabled gauge elasticsearch_clustersettings_stats_shard_allocation_enabled 0 # HELP elasticsearch_clustersettings_allocation_threshold_enabled Is disk allocation decider enabled. # TYPE elasticsearch_clustersettings_allocation_threshold_enabled gauge elasticsearch_clustersettings_allocation_threshold_enabled 0 `, }, { name: "7.3.0", file: "../fixtures/settings-7.3.0.json", want: ` # HELP elasticsearch_clustersettings_stats_max_shards_per_node Current maximum number of shards per node setting. # TYPE elasticsearch_clustersettings_stats_max_shards_per_node gauge elasticsearch_clustersettings_stats_max_shards_per_node 1000 # HELP elasticsearch_clustersettings_stats_shard_allocation_enabled Current mode of cluster wide shard routing allocation settings. # TYPE elasticsearch_clustersettings_stats_shard_allocation_enabled gauge elasticsearch_clustersettings_stats_shard_allocation_enabled 0 # HELP elasticsearch_clustersettings_allocation_threshold_enabled Is disk allocation decider enabled. # TYPE elasticsearch_clustersettings_allocation_threshold_enabled gauge elasticsearch_clustersettings_allocation_threshold_enabled 0 # HELP elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio Flood stage watermark as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio gauge elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio 0.95 # HELP elasticsearch_clustersettings_allocation_watermark_high_ratio High watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_high_ratio gauge elasticsearch_clustersettings_allocation_watermark_high_ratio 0.9 # HELP elasticsearch_clustersettings_allocation_watermark_low_ratio Low watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_low_ratio gauge elasticsearch_clustersettings_allocation_watermark_low_ratio 0.85 `, }, { name: "7.17.5-persistent-clustermaxshardspernode", file: "../fixtures/settings-persistent-clustermaxshardspernode-7.17.5.json", want: ` # HELP elasticsearch_clustersettings_stats_max_shards_per_node Current maximum number of shards per node setting. # TYPE elasticsearch_clustersettings_stats_max_shards_per_node gauge elasticsearch_clustersettings_stats_max_shards_per_node 1000 # HELP elasticsearch_clustersettings_stats_shard_allocation_enabled Current mode of cluster wide shard routing allocation settings. # TYPE elasticsearch_clustersettings_stats_shard_allocation_enabled gauge elasticsearch_clustersettings_stats_shard_allocation_enabled 0 # HELP elasticsearch_clustersettings_allocation_threshold_enabled Is disk allocation decider enabled. # TYPE elasticsearch_clustersettings_allocation_threshold_enabled gauge elasticsearch_clustersettings_allocation_threshold_enabled 1 # HELP elasticsearch_clustersettings_allocation_watermark_flood_stage_bytes Flood stage watermark as in bytes. # TYPE elasticsearch_clustersettings_allocation_watermark_flood_stage_bytes gauge elasticsearch_clustersettings_allocation_watermark_flood_stage_bytes 100 # HELP elasticsearch_clustersettings_allocation_watermark_high_bytes High watermark for disk usage in bytes. # TYPE elasticsearch_clustersettings_allocation_watermark_high_bytes gauge elasticsearch_clustersettings_allocation_watermark_high_bytes 2.147483648e+11 # HELP elasticsearch_clustersettings_allocation_watermark_low_bytes Low watermark for disk usage in bytes. # TYPE elasticsearch_clustersettings_allocation_watermark_low_bytes gauge elasticsearch_clustersettings_allocation_watermark_low_bytes 5.24288e+07 `, }, { name: "8.9.1-persistent-watermark-percent", file: "../fixtures/settings-8.9.1-watermark.json", want: ` # HELP elasticsearch_clustersettings_stats_max_shards_per_node Current maximum number of shards per node setting. # TYPE elasticsearch_clustersettings_stats_max_shards_per_node gauge elasticsearch_clustersettings_stats_max_shards_per_node 1000 # HELP elasticsearch_clustersettings_stats_shard_allocation_enabled Current mode of cluster wide shard routing allocation settings. # TYPE elasticsearch_clustersettings_stats_shard_allocation_enabled gauge elasticsearch_clustersettings_stats_shard_allocation_enabled 0 # HELP elasticsearch_clustersettings_allocation_threshold_enabled Is disk allocation decider enabled. # TYPE elasticsearch_clustersettings_allocation_threshold_enabled gauge elasticsearch_clustersettings_allocation_threshold_enabled 1 # HELP elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio Flood stage watermark as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio gauge elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio 0.96 # HELP elasticsearch_clustersettings_allocation_watermark_high_ratio High watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_high_ratio gauge elasticsearch_clustersettings_allocation_watermark_high_ratio 0.92 # HELP elasticsearch_clustersettings_allocation_watermark_low_ratio Low watermark for disk usage as a ratio. # TYPE elasticsearch_clustersettings_allocation_watermark_low_ratio gauge elasticsearch_clustersettings_allocation_watermark_low_ratio 0.88 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewClusterSettings(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } func Test_getValueInBytes(t *testing.T) { tests := []struct { name string input string want float64 wantErr bool }{ {name: "Bytes", input: "100b", want: 100}, {name: "Kibibytes", input: "200kb", want: 204800}, {name: "Mebibytes", input: "300mb", want: 314572800}, {name: "Gibibytes", input: "400gb", want: 429496729600}, {name: "Tebibytes", input: "500tb", want: 549755813888000}, {name: "Pebibytes", input: "600pb", want: 675539944105574400}, {name: "Unknown", input: "9ab", wantErr: true}, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { got, err := getValueInBytes(tt.input) if (err != nil) != tt.wantErr { t.Fatalf("getValueInBytes() error = %v, wantErr %v", err, tt.wantErr) } if got != tt.want { t.Errorf("getValueInBytes() = %v, want %v", got, tt.want) } }) } } func Test_getValueAsRatio(t *testing.T) { tests := []struct { name string input string want float64 wantErr bool }{ {name: "Ratio", input: "0.5", want: 0.5}, {name: "Percentage", input: "50%", want: 0.5}, {name: "Invalid", input: "500b", wantErr: true}, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { got, err := getValueAsRatio(tt.input) if (err != nil) != tt.wantErr { t.Fatalf("getValueAsRatio() error = %v, wantErr %v", err, tt.wantErr) } if got != tt.want { t.Errorf("getValueAsRatio() = %v, want %v", got, tt.want) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/collector.go000066400000000000000000000146161511562765300247700ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // Package collector includes all individual collectors to gather and export elasticsearch metrics. package collector import ( "context" "errors" "fmt" "log/slog" "net/http" "net/url" "sync" "time" "github.com/alecthomas/kingpin/v2" "github.com/prometheus/client_golang/prometheus" ) const ( // Namespace defines the common namespace to be used by all metrics. namespace = "elasticsearch" defaultEnabled = true defaultDisabled = false ) type factoryFunc func(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) var ( factories = make(map[string]factoryFunc) initiatedCollectorsMtx = sync.Mutex{} initiatedCollectors = make(map[string]Collector) collectorState = make(map[string]*bool) forcedCollectors = map[string]bool{} // collectors which have been explicitly enabled or disabled ) var ( scrapeDurationDesc = prometheus.NewDesc( prometheus.BuildFQName(namespace, "scrape", "duration_seconds"), "elasticsearch_exporter: Duration of a collector scrape.", []string{"collector"}, nil, ) scrapeSuccessDesc = prometheus.NewDesc( prometheus.BuildFQName(namespace, "scrape", "success"), "elasticsearch_exporter: Whether a collector succeeded.", []string{"collector"}, nil, ) ) // Collector is the interface a collector has to implement. type Collector interface { // Get new metrics and expose them via prometheus registry. Update(context.Context, chan<- prometheus.Metric) error } func registerCollector(name string, isDefaultEnabled bool, createFunc factoryFunc) { var helpDefaultState string if isDefaultEnabled { helpDefaultState = "enabled" } else { helpDefaultState = "disabled" } // Create flag for this collector flagName := fmt.Sprintf("collector.%s", name) flagHelp := fmt.Sprintf("Enable the %s collector (default: %s).", name, helpDefaultState) defaultValue := fmt.Sprintf("%v", isDefaultEnabled) flag := kingpin.Flag(flagName, flagHelp).Default(defaultValue).Action(collectorFlagAction(name)).Bool() collectorState[name] = flag // Register the create function for this collector factories[name] = createFunc } type ElasticsearchCollector struct { Collectors map[string]Collector logger *slog.Logger esURL *url.URL httpClient *http.Client } type Option func(*ElasticsearchCollector) error // NewElasticsearchCollector creates a new ElasticsearchCollector func NewElasticsearchCollector(logger *slog.Logger, filters []string, options ...Option) (*ElasticsearchCollector, error) { e := &ElasticsearchCollector{logger: logger} // Apply options to customize the collector for _, o := range options { if err := o(e); err != nil { return nil, err } } f := make(map[string]bool) for _, filter := range filters { enabled, exist := collectorState[filter] if !exist { return nil, fmt.Errorf("missing collector: %s", filter) } if !*enabled { return nil, fmt.Errorf("disabled collector: %s", filter) } f[filter] = true } collectors := make(map[string]Collector) initiatedCollectorsMtx.Lock() defer initiatedCollectorsMtx.Unlock() for key, enabled := range collectorState { if !*enabled || (len(f) > 0 && !f[key]) { continue } if collector, ok := initiatedCollectors[key]; ok { collectors[key] = collector } else { collector, err := factories[key](logger.With("collector", key), e.esURL, e.httpClient) if err != nil { return nil, err } collectors[key] = collector initiatedCollectors[key] = collector } } e.Collectors = collectors return e, nil } func WithElasticsearchURL(esURL *url.URL) Option { return func(e *ElasticsearchCollector) error { e.esURL = esURL return nil } } func WithHTTPClient(hc *http.Client) Option { return func(e *ElasticsearchCollector) error { e.httpClient = hc return nil } } // Describe implements the prometheus.Collector interface. func (e ElasticsearchCollector) Describe(ch chan<- *prometheus.Desc) { ch <- scrapeDurationDesc ch <- scrapeSuccessDesc } // Collect implements the prometheus.Collector interface. func (e ElasticsearchCollector) Collect(ch chan<- prometheus.Metric) { wg := sync.WaitGroup{} ctx := context.TODO() wg.Add(len(e.Collectors)) for name, c := range e.Collectors { go func(name string, c Collector) { execute(ctx, name, c, ch, e.logger) wg.Done() }(name, c) } wg.Wait() } func execute(ctx context.Context, name string, c Collector, ch chan<- prometheus.Metric, logger *slog.Logger) { begin := time.Now() err := c.Update(ctx, ch) duration := time.Since(begin) var success float64 if err != nil { if IsNoDataError(err) { logger.Debug("collector returned no data", "name", name, "duration_seconds", duration.Seconds(), "err", err) } else { logger.Warn("collector failed", "name", name, "duration_seconds", duration.Seconds(), "err", err) } success = 0 } else { logger.Debug("collector succeeded", "name", name, "duration_seconds", duration.Seconds()) success = 1 } ch <- prometheus.MustNewConstMetric(scrapeDurationDesc, prometheus.GaugeValue, duration.Seconds(), name) ch <- prometheus.MustNewConstMetric(scrapeSuccessDesc, prometheus.GaugeValue, success, name) } // collectorFlagAction generates a new action function for the given collector // to track whether it has been explicitly enabled or disabled from the command line. // A new action function is needed for each collector flag because the ParseContext // does not contain information about which flag called the action. // See: https://github.com/alecthomas/kingpin/issues/294 func collectorFlagAction(collector string) func(ctx *kingpin.ParseContext) error { return func(ctx *kingpin.ParseContext) error { forcedCollectors[collector] = true return nil } } // ErrNoData indicates the collector found no data to collect, but had no other error. var ErrNoData = errors.New("collector returned no data") func IsNoDataError(err error) bool { return err == ErrNoData } prometheus-elasticsearch-exporter-1.10.0/collector/collector_test.go000066400000000000000000000021661511562765300260240ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "github.com/prometheus/client_golang/prometheus" ) // wrapCollector is a util to let you test your Collector implementation. // // Use this with prometheus/client_golang/prometheus/testutil to test metric output, for example: // // testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(want)) type wrapCollector struct { c Collector } func (w wrapCollector) Describe(_ chan<- *prometheus.Desc) { } func (w wrapCollector) Collect(ch chan<- prometheus.Metric) { w.c.Update(context.Background(), ch) } prometheus-elasticsearch-exporter-1.10.0/collector/data_stream.go000066400000000000000000000064631511562765300252670ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "fmt" "log/slog" "net/http" "net/url" "github.com/prometheus/client_golang/prometheus" ) var ( dataStreamBackingIndicesTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "data_stream", "backing_indices_total"), "Number of backing indices", []string{"data_stream"}, nil, ) dataStreamStoreSizeBytes = prometheus.NewDesc( prometheus.BuildFQName(namespace, "data_stream", "store_size_bytes"), "Store size of data stream", []string{"data_stream"}, nil, ) ) func init() { registerCollector("data-stream", defaultDisabled, NewDataStream) } // DataStream Information Struct type DataStream struct { logger *slog.Logger hc *http.Client u *url.URL } // NewDataStream defines DataStream Prometheus metrics func NewDataStream(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &DataStream{ logger: logger, hc: hc, u: u, }, nil } // DataStreamStatsResponse is a representation of the Data Stream stats type DataStreamStatsResponse struct { Shards DataStreamStatsShards `json:"_shards"` DataStreamCount int64 `json:"data_stream_count"` BackingIndices int64 `json:"backing_indices"` TotalStoreSizeBytes int64 `json:"total_store_size_bytes"` DataStreamStats []DataStreamStatsDataStream `json:"data_streams"` } // DataStreamStatsShards defines data stream stats shards information structure type DataStreamStatsShards struct { Total int64 `json:"total"` Successful int64 `json:"successful"` Failed int64 `json:"failed"` } // DataStreamStatsDataStream defines the structure of per data stream stats type DataStreamStatsDataStream struct { DataStream string `json:"data_stream"` BackingIndices int64 `json:"backing_indices"` StoreSizeBytes int64 `json:"store_size_bytes"` MaximumTimestamp int64 `json:"maximum_timestamp"` } func (ds *DataStream) Update(ctx context.Context, ch chan<- prometheus.Metric) error { var dsr DataStreamStatsResponse u := ds.u.ResolveReference(&url.URL{Path: "/_data_stream/*/_stats"}) resp, err := getURL(ctx, ds.hc, ds.logger, u.String()) if err != nil { return err } if err := json.Unmarshal(resp, &dsr); err != nil { return err } for _, dataStream := range dsr.DataStreamStats { fmt.Printf("Metric: %+v", dataStream) ch <- prometheus.MustNewConstMetric( dataStreamBackingIndicesTotal, prometheus.CounterValue, float64(dataStream.BackingIndices), dataStream.DataStream, ) ch <- prometheus.MustNewConstMetric( dataStreamStoreSizeBytes, prometheus.CounterValue, float64(dataStream.StoreSizeBytes), dataStream.DataStream, ) } return nil } prometheus-elasticsearch-exporter-1.10.0/collector/data_stream_test.go000066400000000000000000000043311511562765300263160ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestDataStream(t *testing.T) { tests := []struct { name string file string want string }{ { name: "7.15.0", file: "../fixtures/datastream/7.15.0.json", want: `# HELP elasticsearch_data_stream_backing_indices_total Number of backing indices # TYPE elasticsearch_data_stream_backing_indices_total counter elasticsearch_data_stream_backing_indices_total{data_stream="bar"} 2 elasticsearch_data_stream_backing_indices_total{data_stream="foo"} 5 # HELP elasticsearch_data_stream_store_size_bytes Store size of data stream # TYPE elasticsearch_data_stream_store_size_bytes counter elasticsearch_data_stream_store_size_bytes{data_stream="bar"} 6.7382272e+08 elasticsearch_data_stream_store_size_bytes{data_stream="foo"} 4.29205396e+08 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewDataStream(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/health_report.go000066400000000000000000000407741511562765300256460ustar00rootroot00000000000000// Copyright 2025 The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "log/slog" "net/http" "net/url" "github.com/prometheus/client_golang/prometheus" ) var ( statusColors = []string{"green", "yellow", "red"} defaultHealthReportLabels = []string{"cluster"} ) var ( healthReportTotalRepositories = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "total_repositories"), "The number of snapshot repositories", defaultHealthReportLabels, nil, ) healthReportMaxShardsInClusterData = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "max_shards_in_cluster_data"), "The number of maximum shards in a cluster", defaultHealthReportLabels, nil, ) healthReportMaxShardsInClusterFrozen = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "max_shards_in_cluster_frozen"), "The number of maximum frozen shards in a cluster", defaultHealthReportLabels, nil, ) healthReportRestartingReplicas = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "restarting_replicas"), "The number of restarting replica shards", defaultHealthReportLabels, nil, ) healthReportCreatingPrimaries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "creating_primaries"), "The number of creating primary shards", defaultHealthReportLabels, nil, ) healthReportInitializingReplicas = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "initializing_replicas"), "The number of initializing replica shards", defaultHealthReportLabels, nil, ) healthReportUnassignedReplicas = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "unassigned_replicas"), "The number of unassigned replica shards", defaultHealthReportLabels, nil, ) healthReportStartedPrimaries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "started_primaries"), "The number of started primary shards", defaultHealthReportLabels, nil, ) healthReportRestartingPrimaries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "restarting_primaries"), "The number of restarting primary shards", defaultHealthReportLabels, nil, ) healthReportInitializingPrimaries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "initializing_primaries"), "The number of initializing primary shards", defaultHealthReportLabels, nil, ) healthReportCreatingReplicas = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "creating_replicas"), "The number of creating replica shards", defaultHealthReportLabels, nil, ) healthReportStartedReplicas = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "started_replicas"), "The number of started replica shards", defaultHealthReportLabels, nil, ) healthReportUnassignedPrimaries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "unassigned_primaries"), "The number of unassigned primary shards", defaultHealthReportLabels, nil, ) healthReportSlmPolicies = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "slm_policies"), "The number of SLM policies", defaultHealthReportLabels, nil, ) healthReportIlmPolicies = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "ilm_policies"), "The number of ILM Policies", defaultHealthReportLabels, nil, ) healthReportIlmStagnatingIndices = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "ilm_stagnating_indices"), "The number of stagnating indices", defaultHealthReportLabels, nil, ) healthReportStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "status"), "Overall cluster status", []string{"cluster", "color"}, nil, ) healthReportMasterIsStableStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "master_is_stable_status"), "Master is stable status", []string{"cluster", "color"}, nil, ) healthReportRepositoryIntegrityStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "repository_integrity_status"), "Repository integrity status", []string{"cluster", "color"}, nil, ) healthReportDiskStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "disk_status"), "Disk status", []string{"cluster", "color"}, nil, ) healthReportShardsCapacityStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "shards_capacity_status"), "Shards capacity status", []string{"cluster", "color"}, nil, ) healthReportShardsAvailabiltystatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "shards_availabilty_status"), "Shards availabilty status", []string{"cluster", "color"}, nil, ) healthReportDataStreamLifecycleStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "data_stream_lifecycle_status"), "Data stream lifecycle status", []string{"cluster", "color"}, nil, ) healthReportSlmStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "slm_status"), "SLM status", []string{"cluster", "color"}, nil, ) healthReportIlmStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "health_report", "ilm_status"), "ILM status", []string{"cluster", "color"}, nil, ) ) func init() { registerCollector("health-report", defaultDisabled, NewHealthReport) } type HealthReport struct { logger *slog.Logger client *http.Client url *url.URL } func NewHealthReport(logger *slog.Logger, url *url.URL, client *http.Client) (Collector, error) { return &HealthReport{ logger: logger, client: client, url: url, }, nil } type HealthReportResponse struct { ClusterName string `json:"cluster_name"` Status string `json:"status"` Indicators HealthReportIndicators `json:"indicators"` } type HealthReportIndicators struct { MasterIsStable HealthReportMasterIsStable `json:"master_is_stable"` RepositoryIntegrity HealthReportRepositoryIntegrity `json:"repository_integrity"` Disk HealthReportDisk `json:"disk"` ShardsCapacity HealthReportShardsCapacity `json:"shards_capacity"` ShardsAvailability HealthReportShardsAvailability `json:"shards_availability"` DataStreamLifecycle HealthReportDataStreamLifecycle `json:"data_stream_lifecycle"` Slm HealthReportSlm `json:"slm"` Ilm HealthReportIlm `json:"ilm"` } type HealthReportMasterIsStable struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportMasterIsStableDetails `json:"details"` } type HealthReportMasterIsStableDetails struct { CurrentMaster HealthReportMasterIsStableDetailsNode `json:"current_master"` RecentMasters []HealthReportMasterIsStableDetailsNode `json:"recent_masters"` } type HealthReportMasterIsStableDetailsNode struct { NodeID string `json:"node_id"` Name string `json:"name"` } type HealthReportRepositoryIntegrity struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportRepositoriyIntegrityDetails `json:"details"` } type HealthReportRepositoriyIntegrityDetails struct { TotalRepositories int `json:"total_repositories"` } type HealthReportDisk struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportDiskDetails `json:"details"` } type HealthReportDiskDetails struct { IndicesWithReadonlyBlock int `json:"indices_with_readonly_block"` NodesWithEnoughDiskSpace int `json:"nodes_with_enough_disk_space"` NodesWithUnknownDiskStatus int `json:"nodes_with_unknown_disk_status"` NodesOverHighWatermark int `json:"nodes_over_high_watermark"` NodesOverFloodStageWatermark int `json:"nodes_over_flood_stage_watermark"` } type HealthReportShardsCapacity struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportShardsCapacityDetails `json:"details"` } type HealthReportShardsCapacityDetails struct { Data HealthReportShardsCapacityDetailsMaxShards `json:"data"` Frozen HealthReportShardsCapacityDetailsMaxShards `json:"frozen"` } type HealthReportShardsCapacityDetailsMaxShards struct { MaxShardsInCluster int `json:"max_shards_in_cluster"` } type HealthReportShardsAvailability struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportShardsAvailabilityDetails `json:"details"` } type HealthReportShardsAvailabilityDetails struct { RestartingReplicas int `json:"restarting_replicas"` CreatingPrimaries int `json:"creating_primaries"` InitializingReplicas int `json:"initializing_replicas"` UnassignedReplicas int `json:"unassigned_replicas"` StartedPrimaries int `json:"started_primaries"` RestartingPrimaries int `json:"restarting_primaries"` InitializingPrimaries int `json:"initializing_primaries"` CreatingReplicas int `json:"creating_replicas"` StartedReplicas int `json:"started_replicas"` UnassignedPrimaries int `json:"unassigned_primaries"` } type HealthReportDataStreamLifecycle struct { Status string `json:"status"` Symptom string `json:"symptom"` } type HealthReportSlm struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportSlmDetails `json:"details"` } type HealthReportSlmDetails struct { SlmStatus string `json:"slm_status"` Policies int `json:"policies"` } type HealthReportIlm struct { Status string `json:"status"` Symptom string `json:"symptom"` Details HealthReportIlmDetails `json:"details"` } type HealthReportIlmDetails struct { Policies int `json:"policies"` StagnatingIndices int `json:"stagnating_indices"` IlmStatus string `json:"ilm_status"` } func statusValue(value string, color string) float64 { if value == color { return 1 } return 0 } func (c *HealthReport) Update(ctx context.Context, ch chan<- prometheus.Metric) error { u := c.url.ResolveReference(&url.URL{Path: "/_health_report"}) var healthReportResponse HealthReportResponse resp, err := getURL(ctx, c.client, c.logger, u.String()) if err != nil { return err } err = json.Unmarshal(resp, &healthReportResponse) if err != nil { return err } ch <- prometheus.MustNewConstMetric( healthReportTotalRepositories, prometheus.GaugeValue, float64(healthReportResponse.Indicators.RepositoryIntegrity.Details.TotalRepositories), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportMaxShardsInClusterData, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsCapacity.Details.Data.MaxShardsInCluster), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportMaxShardsInClusterFrozen, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsCapacity.Details.Frozen.MaxShardsInCluster), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportRestartingReplicas, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.RestartingReplicas), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportCreatingPrimaries, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.CreatingPrimaries), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportInitializingReplicas, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.InitializingReplicas), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportUnassignedReplicas, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.UnassignedReplicas), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportStartedPrimaries, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.StartedPrimaries), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportRestartingPrimaries, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.RestartingPrimaries), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportInitializingPrimaries, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.InitializingPrimaries), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportCreatingReplicas, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.CreatingReplicas), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportStartedReplicas, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.StartedReplicas), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportUnassignedPrimaries, prometheus.GaugeValue, float64(healthReportResponse.Indicators.ShardsAvailability.Details.UnassignedPrimaries), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportSlmPolicies, prometheus.GaugeValue, float64(healthReportResponse.Indicators.Slm.Details.Policies), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportIlmPolicies, prometheus.GaugeValue, float64(healthReportResponse.Indicators.Ilm.Details.Policies), healthReportResponse.ClusterName, ) ch <- prometheus.MustNewConstMetric( healthReportIlmStagnatingIndices, prometheus.GaugeValue, float64(healthReportResponse.Indicators.Ilm.Details.StagnatingIndices), healthReportResponse.ClusterName, ) for _, color := range statusColors { ch <- prometheus.MustNewConstMetric( healthReportStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportMasterIsStableStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.MasterIsStable.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportRepositoryIntegrityStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.RepositoryIntegrity.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportDiskStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.Disk.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportShardsCapacityStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.ShardsCapacity.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportShardsAvailabiltystatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.ShardsAvailability.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportDataStreamLifecycleStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.DataStreamLifecycle.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportSlmStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.Slm.Status, color), healthReportResponse.ClusterName, color, ) ch <- prometheus.MustNewConstMetric( healthReportIlmStatus, prometheus.GaugeValue, statusValue(healthReportResponse.Indicators.Ilm.Status, color), healthReportResponse.ClusterName, color, ) } return nil } prometheus-elasticsearch-exporter-1.10.0/collector/health_report_test.go000066400000000000000000000224161511562765300266760ustar00rootroot00000000000000// Copyright 2025 The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestHealthReport(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION // curl -XPUT http://localhost:9200/twitter // curl http://localhost:9200/_health_report tests := []struct { name string file string want string }{ { name: "8.7.0", file: "../fixtures/healthreport/8.7.0.json", want: ` # HELP elasticsearch_health_report_creating_primaries The number of creating primary shards # TYPE elasticsearch_health_report_creating_primaries gauge elasticsearch_health_report_creating_primaries{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_creating_replicas The number of creating replica shards # TYPE elasticsearch_health_report_creating_replicas gauge elasticsearch_health_report_creating_replicas{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_data_stream_lifecycle_status Data stream lifecycle status # TYPE elasticsearch_health_report_data_stream_lifecycle_status gauge elasticsearch_health_report_data_stream_lifecycle_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_data_stream_lifecycle_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_data_stream_lifecycle_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_disk_status Disk status # TYPE elasticsearch_health_report_disk_status gauge elasticsearch_health_report_disk_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_disk_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_disk_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_ilm_policies The number of ILM Policies # TYPE elasticsearch_health_report_ilm_policies gauge elasticsearch_health_report_ilm_policies{cluster="docker-cluster"} 17 # HELP elasticsearch_health_report_ilm_stagnating_indices The number of stagnating indices # TYPE elasticsearch_health_report_ilm_stagnating_indices gauge elasticsearch_health_report_ilm_stagnating_indices{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_ilm_status ILM status # TYPE elasticsearch_health_report_ilm_status gauge elasticsearch_health_report_ilm_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_ilm_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_ilm_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_initializing_primaries The number of initializing primary shards # TYPE elasticsearch_health_report_initializing_primaries gauge elasticsearch_health_report_initializing_primaries{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_initializing_replicas The number of initializing replica shards # TYPE elasticsearch_health_report_initializing_replicas gauge elasticsearch_health_report_initializing_replicas{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_master_is_stable_status Master is stable status # TYPE elasticsearch_health_report_master_is_stable_status gauge elasticsearch_health_report_master_is_stable_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_master_is_stable_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_master_is_stable_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_max_shards_in_cluster_data The number of maximum shards in a cluster # TYPE elasticsearch_health_report_max_shards_in_cluster_data gauge elasticsearch_health_report_max_shards_in_cluster_data{cluster="docker-cluster"} 13500 # HELP elasticsearch_health_report_max_shards_in_cluster_frozen The number of maximum frozen shards in a cluster # TYPE elasticsearch_health_report_max_shards_in_cluster_frozen gauge elasticsearch_health_report_max_shards_in_cluster_frozen{cluster="docker-cluster"} 9000 # HELP elasticsearch_health_report_repository_integrity_status Repository integrity status # TYPE elasticsearch_health_report_repository_integrity_status gauge elasticsearch_health_report_repository_integrity_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_repository_integrity_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_repository_integrity_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_restarting_primaries The number of restarting primary shards # TYPE elasticsearch_health_report_restarting_primaries gauge elasticsearch_health_report_restarting_primaries{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_restarting_replicas The number of restarting replica shards # TYPE elasticsearch_health_report_restarting_replicas gauge elasticsearch_health_report_restarting_replicas{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_shards_availabilty_status Shards availabilty status # TYPE elasticsearch_health_report_shards_availabilty_status gauge elasticsearch_health_report_shards_availabilty_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_shards_availabilty_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_shards_availabilty_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_shards_capacity_status Shards capacity status # TYPE elasticsearch_health_report_shards_capacity_status gauge elasticsearch_health_report_shards_capacity_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_shards_capacity_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_shards_capacity_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_slm_policies The number of SLM policies # TYPE elasticsearch_health_report_slm_policies gauge elasticsearch_health_report_slm_policies{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_slm_status SLM status # TYPE elasticsearch_health_report_slm_status gauge elasticsearch_health_report_slm_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_slm_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_slm_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_started_primaries The number of started primary shards # TYPE elasticsearch_health_report_started_primaries gauge elasticsearch_health_report_started_primaries{cluster="docker-cluster"} 11703 # HELP elasticsearch_health_report_started_replicas The number of started replica shards # TYPE elasticsearch_health_report_started_replicas gauge elasticsearch_health_report_started_replicas{cluster="docker-cluster"} 1701 # HELP elasticsearch_health_report_status Overall cluster status # TYPE elasticsearch_health_report_status gauge elasticsearch_health_report_status{cluster="docker-cluster",color="green"} 1 elasticsearch_health_report_status{cluster="docker-cluster",color="red"} 0 elasticsearch_health_report_status{cluster="docker-cluster",color="yellow"} 0 # HELP elasticsearch_health_report_total_repositories The number of snapshot repositories # TYPE elasticsearch_health_report_total_repositories gauge elasticsearch_health_report_total_repositories{cluster="docker-cluster"} 1 # HELP elasticsearch_health_report_unassigned_primaries The number of unassigned primary shards # TYPE elasticsearch_health_report_unassigned_primaries gauge elasticsearch_health_report_unassigned_primaries{cluster="docker-cluster"} 0 # HELP elasticsearch_health_report_unassigned_replicas The number of unassigned replica shards # TYPE elasticsearch_health_report_unassigned_replicas gauge elasticsearch_health_report_unassigned_replicas{cluster="docker-cluster"} 0 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewHealthReport(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/ilm.go000066400000000000000000000062331511562765300235570ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "fmt" "log/slog" "net/http" "net/url" "github.com/prometheus/client_golang/prometheus" ) var ( ilmStatusOptions = []string{"STOPPED", "RUNNING", "STOPPING"} ilmIndexStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "ilm_index", "status"), "Status of ILM policy for index", []string{"index", "phase", "action", "step"}, nil) ilmStatus = prometheus.NewDesc( prometheus.BuildFQName(namespace, "ilm", "status"), "Current status of ILM. Status can be STOPPED, RUNNING, STOPPING.", []string{"operation_mode"}, nil, ) ) func init() { registerCollector("ilm", defaultDisabled, NewILM) } type ILM struct { logger *slog.Logger hc *http.Client u *url.URL } func NewILM(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &ILM{ logger: logger, hc: hc, u: u, }, nil } type IlmResponse struct { Indices map[string]IlmIndexResponse `json:"indices"` } type IlmIndexResponse struct { Index string `json:"index"` Managed bool `json:"managed"` Phase string `json:"phase"` Action string `json:"action"` Step string `json:"step"` StepTimeMillis float64 `json:"step_time_millis"` } type IlmStatusResponse struct { OperationMode string `json:"operation_mode"` } func (i *ILM) Update(ctx context.Context, ch chan<- prometheus.Metric) error { var ir IlmResponse indexURL := i.u.ResolveReference(&url.URL{Path: "/_all/_ilm/explain"}) indexResp, err := getURL(ctx, i.hc, i.logger, indexURL.String()) if err != nil { return fmt.Errorf("failed to load ILM url: %w", err) } if err := json.Unmarshal(indexResp, &ir); err != nil { return fmt.Errorf("failed to decode JSON body: %w", err) } var isr IlmStatusResponse indexStatusURL := i.u.ResolveReference(&url.URL{Path: "/_ilm/status"}) indexStatusResp, err := getURL(ctx, i.hc, i.logger, indexStatusURL.String()) if err != nil { return fmt.Errorf("failed to load ILM url: %w", err) } if err := json.Unmarshal(indexStatusResp, &isr); err != nil { return fmt.Errorf("failed to decode JSON body: %w", err) } for name, ilm := range ir.Indices { ch <- prometheus.MustNewConstMetric( ilmIndexStatus, prometheus.GaugeValue, bool2Float(ilm.Managed), name, ilm.Phase, ilm.Action, ilm.Step, ) } for _, status := range ilmStatusOptions { statusActive := false if isr.OperationMode == status { statusActive = true } ch <- prometheus.MustNewConstMetric( ilmStatus, prometheus.GaugeValue, bool2Float(statusActive), status, ) } return nil } prometheus-elasticsearch-exporter-1.10.0/collector/ilm_test.go000066400000000000000000000052101511562765300246100ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "path" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestILM(t *testing.T) { tests := []struct { name string file string want string }{ { name: "6.6.0", file: "6.6.0.json", want: ` # HELP elasticsearch_ilm_index_status Status of ILM policy for index # TYPE elasticsearch_ilm_index_status gauge elasticsearch_ilm_index_status{action="",index="twitter",phase="",step=""} 0 elasticsearch_ilm_index_status{action="complete",index="facebook",phase="new",step="complete"} 1 # HELP elasticsearch_ilm_status Current status of ILM. Status can be STOPPED, RUNNING, STOPPING. # TYPE elasticsearch_ilm_status gauge elasticsearch_ilm_status{operation_mode="RUNNING"} 1 elasticsearch_ilm_status{operation_mode="STOPPED"} 0 elasticsearch_ilm_status{operation_mode="STOPPING"} 0 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { indexF, err := os.Open(path.Join("../fixtures/ilm_indices", tt.file)) if err != nil { t.Fatal(err) } defer indexF.Close() statusF, err := os.Open(path.Join("../fixtures/ilm_status", tt.file)) if err != nil { t.Fatal(err) } defer statusF.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { sm := http.NewServeMux() sm.HandleFunc("/_all/_ilm/explain", func(w http.ResponseWriter, r *http.Request) { io.Copy(w, indexF) }) sm.HandleFunc("/_ilm/status", func(w http.ResponseWriter, r *http.Request) { io.Copy(w, statusF) }) sm.ServeHTTP(w, r) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewILM(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/indices.go000066400000000000000000001153721511562765300244210ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "log/slog" "net/http" "net/url" "path" "sort" "strconv" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus-community/elasticsearch_exporter/pkg/clusterinfo" ) var ( indicesLabels = []string{"index", "cluster"} indicesDocsPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "docs_primary"), "Count of documents with only primary shards", indicesLabels, nil, ) indicesDeletedDocsPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "deleted_docs_primary"), "Count of deleted documents with only primary shards", indicesLabels, nil, ) indicesDocsTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "docs_total"), "Total count of documents", indicesLabels, nil, ) indicesDeletedDocsTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "deleted_docs_total"), "Total count of deleted documents", indicesLabels, nil, ) indicesStoreSizeBytesPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "store_size_bytes_primary"), "Current total size of stored index data in bytes with only primary shards on all nodes", indicesLabels, nil, ) indicesStoreSizeBytesTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "store_size_bytes_total"), "Current total size of stored index data in bytes with all shards on all nodes", indicesLabels, nil, ) indicesSegmentCountPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_count_primary"), "Current number of segments with only primary shards on all nodes", indicesLabels, nil, ) indicesSegmentCountTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_count_total"), "Current number of segments with all shards on all nodes", indicesLabels, nil, ) indicesSegmentMemoryBytesPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_memory_bytes_primary"), "Current size of segments with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentMemoryBytesTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_memory_bytes_total"), "Current size of segments with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentTermsMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_terms_memory_primary"), "Current size of terms with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentTermsMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_terms_memory_total"), "Current number of terms with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentFieldsMemoryBytesPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_fields_memory_bytes_primary"), "Current size of fields with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentFieldsMemoryBytesTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_fields_memory_bytes_total"), "Current size of fields with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentTermVectorsMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_term_vectors_memory_primary_bytes"), "Current size of term vectors with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentTermVectorsMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_term_vectors_memory_total_bytes"), "Current size of term vectors with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentNormsMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_norms_memory_bytes_primary"), "Current size of norms with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentNormsMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_norms_memory_bytes_total"), "Current size of norms with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentPointsMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_points_memory_bytes_primary"), "Current size of points with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentPointsMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_points_memory_bytes_total"), "Current size of points with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentDocValuesMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_doc_values_memory_bytes_primary"), "Current size of doc values with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentDocValuesMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_doc_values_memory_bytes_total"), "Current size of doc values with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentIndexWriterMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_index_writer_memory_bytes_primary"), "Current size of index writer with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentIndexWriterMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_index_writer_memory_bytes_total"), "Current size of index writer with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentVersionMapMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_version_map_memory_bytes_primary"), "Current size of version map with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentVersionMapMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_version_map_memory_bytes_total"), "Current size of version map with all shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentFBSMemoryPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_fixed_bit_set_memory_bytes_primary"), "Current size of fixed bit with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesSegmentFBSMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segment_fixed_bit_set_memory_bytes_total"), "Current size of fixed bit with all shards on all nodes in bytes", indicesLabels, nil, ) indicesCompletionPrimary = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "completion_bytes_primary"), "Current size of completion with only primary shards on all nodes in bytes", indicesLabels, nil, ) indicesCompletionTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "completion_bytes_total"), "Current size of completion with all shards on all nodes in bytes", indicesLabels, nil, ) // TODO(@sysadmind): The metrics below should change the subsystem to "indices" indicesSearchQueryTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_query_time_seconds_total"), "Total search query time in seconds", indicesLabels, nil, ) indicesActiveQueries = prometheus.NewDesc( prometheus.BuildFQName(namespace, "search", "active_queries"), "The number of currently active queries", indicesLabels, nil, ) indicesSearchQueryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_query_total"), "Total number of queries", indicesLabels, nil, ) indicesSearchFetchTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_fetch_time_seconds_total"), "Total search fetch time in seconds", indicesLabels, nil, ) indicesSearchFetchTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_fetch_total"), "Total search fetch count", indicesLabels, nil, ) indicesSearchScrollTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_scroll_time_seconds_total"), "Total search scroll time in seconds", indicesLabels, nil, ) indicesSearchScrollCurrent = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_scroll_current"), "Current search scroll count", indicesLabels, nil, ) indicesSearchScrollTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_scroll_total"), "Total search scroll count", indicesLabels, nil, ) indicesSearchSuggestTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_suggest_time_seconds_total"), "Total search suggest time in seconds", indicesLabels, nil, ) indicesSearchSuggestTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "search_suggest_total"), "Total search suggest count", indicesLabels, nil, ) indicesIndexingTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_index_time_seconds_total"), "Total indexing index time in seconds", indicesLabels, nil, ) indicesIndexCurrent = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "index_current"), "The number of documents currently being indexed to an index", indicesLabels, nil, ) indicesIndexingIndexTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_index_total"), "Total indexing index count", indicesLabels, nil, ) indicesIndexingDeleteSecondsTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_delete_time_seconds_total"), "Total indexing delete time in seconds", indicesLabels, nil, ) indicesIndexingDeleteTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_delete_total"), "Total indexing delete count", indicesLabels, nil, ) indicesIndexingNoopUpdateTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_noop_update_total"), "Total indexing no-op update count", indicesLabels, nil, ) indicesIndexingThrottleSecondsTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "indexing_throttle_time_seconds_total"), "Total indexing throttle time in seconds", indicesLabels, nil, ) indicesGetTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "get_time_seconds_total"), "Total get time in seconds", indicesLabels, nil, ) indicesGetTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "get_total"), "Total get count", indicesLabels, nil, ) indicesMergeTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "merge_time_seconds_total"), "Total merge time in seconds", indicesLabels, nil, ) indicesMergeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "merge_total"), "Total merge count", indicesLabels, nil, ) indicesMergeThrottleTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "merge_throttle_time_seconds_total"), "Total merge I/O throttle time in seconds", indicesLabels, nil, ) indicesMergeStoppedTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "merge_stopped_time_seconds_total"), "Total large merge stopped time in seconds, allowing smaller merges to complete", indicesLabels, nil, ) indicesMergeAutoThrottleBytesTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "merge_auto_throttle_bytes_total"), "Total bytes that were auto-throttled during merging", indicesLabels, nil, ) indicesRefreshTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "refresh_time_seconds_total"), "Total refresh time in seconds", indicesLabels, nil, ) indicesRefreshExternalTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "refresh_external_time_seconds_total"), "Total external refresh time in seconds", indicesLabels, nil, ) indicesRefreshExternalTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "refresh_external_total"), "Total external refresh count", indicesLabels, nil, ) indicesRefreshTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "refresh_total"), "Total refresh count", indicesLabels, nil, ) indicesFlushTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "flush_time_seconds_total"), "Total flush time in seconds", indicesLabels, nil, ) indicesFlushTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "flush_total"), "Total flush count", indicesLabels, nil, ) indicesWarmerTimeTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "warmer_time_seconds_total"), "Total warmer time in seconds", indicesLabels, nil, ) indicesWarmerTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "warmer_total"), "Total warmer count", indicesLabels, nil, ) indicesQueryCacheMemoryTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_memory_bytes_total"), "Total query cache memory bytes", indicesLabels, nil, ) indicesQueryCacheSize = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_size"), "Total query cache size", indicesLabels, nil, ) indicesQueryCacheHits = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_hits_total"), "Total query cache hits count", indicesLabels, nil, ) indicesQueryCacheMisses = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_misses_total"), "Total query cache misses count", indicesLabels, nil, ) indicesQueryCacheCaches = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_caches_total"), "Total query cache caches count", indicesLabels, nil, ) indicesQueryCacheEvictions = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "query_cache_evictions_total"), "Total query cache evictions count", indicesLabels, nil, ) indicesRequestCacheMemory = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "request_cache_memory_bytes_total"), "Total request cache memory bytes", indicesLabels, nil, ) indicesRequestCacheHits = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "request_cache_hits_total"), "Total request cache hits count", indicesLabels, nil, ) indicesRequestCacheMisses = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "request_cache_misses_total"), "Total request cache misses count", indicesLabels, nil, ) indicesRequestCacheEvictions = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "request_cache_evictions_total"), "Total request cache evictions count", indicesLabels, nil, ) indicesFielddataMemory = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "fielddata_memory_bytes_total"), "Total fielddata memory bytes", indicesLabels, nil, ) indicesFielddataEvictions = prometheus.NewDesc( prometheus.BuildFQName(namespace, "index_stats", "fielddata_evictions_total"), "Total fielddata evictions count", indicesLabels, nil, ) indicesAliases = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "aliases"), "Record aliases associated with an index", []string{"index", "alias", "cluster"}, nil, ) indicesShardsLabels = []string{"index", "shard", "node", "primary", "cluster"} indicesShardDocs = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "shards_docs"), "Count of documents on this shard", indicesShardsLabels, nil, ) indicesShardDocsDeleted = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "shards_docs_deleted"), "Count of deleted documents on this shard", indicesShardsLabels, nil, ) indicesShardStoreSizeBytes = prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "shards_store_size_in_bytes"), "Store size of this shard", indicesShardsLabels, nil, ) ) type labels struct { keys func(...string) []string values func(*clusterinfo.Response, ...string) []string } // Indices information struct type Indices struct { logger *slog.Logger client *http.Client url *url.URL shards bool aliases bool clusterInfoCh chan *clusterinfo.Response lastClusterInfo *clusterinfo.Response } // NewIndices defines Indices Prometheus metrics func NewIndices(logger *slog.Logger, client *http.Client, url *url.URL, shards bool, includeAliases bool) *Indices { indices := &Indices{ logger: logger, client: client, url: url, shards: shards, aliases: includeAliases, clusterInfoCh: make(chan *clusterinfo.Response), lastClusterInfo: &clusterinfo.Response{ ClusterName: "unknown_cluster", }, } // start go routine to fetch clusterinfo updates and save them to lastClusterinfo go func() { logger.Debug("starting cluster info receive loop") for ci := range indices.clusterInfoCh { if ci != nil { logger.Debug("received cluster info update", "cluster", ci.ClusterName) indices.lastClusterInfo = ci } } logger.Debug("exiting cluster info receive loop") }() return indices } // ClusterLabelUpdates returns a pointer to a channel to receive cluster info updates. It implements the // (not exported) clusterinfo.consumer interface func (i *Indices) ClusterLabelUpdates() *chan *clusterinfo.Response { return &i.clusterInfoCh } // String implements the stringer interface. It is part of the clusterinfo.consumer interface func (i *Indices) String() string { return namespace + "indices" } // Describe add Indices metrics descriptions func (i *Indices) Describe(ch chan<- *prometheus.Desc) { ch <- indicesDocsPrimary ch <- indicesDeletedDocsPrimary ch <- indicesDocsTotal ch <- indicesDeletedDocsTotal ch <- indicesStoreSizeBytesPrimary ch <- indicesStoreSizeBytesTotal ch <- indicesSegmentCountPrimary ch <- indicesSegmentCountTotal ch <- indicesSegmentMemoryBytesPrimary ch <- indicesSegmentMemoryBytesTotal ch <- indicesSegmentTermsMemoryPrimary ch <- indicesSegmentTermsMemoryTotal ch <- indicesSegmentFieldsMemoryBytesPrimary ch <- indicesSegmentFieldsMemoryBytesTotal ch <- indicesSegmentTermVectorsMemoryPrimary ch <- indicesSegmentTermVectorsMemoryTotal ch <- indicesSegmentNormsMemoryPrimary ch <- indicesSegmentNormsMemoryTotal ch <- indicesSegmentPointsMemoryPrimary ch <- indicesSegmentPointsMemoryTotal ch <- indicesSegmentDocValuesMemoryPrimary ch <- indicesSegmentDocValuesMemoryTotal ch <- indicesSegmentIndexWriterMemoryPrimary ch <- indicesSegmentIndexWriterMemoryTotal ch <- indicesSegmentVersionMapMemoryPrimary ch <- indicesSegmentVersionMapMemoryTotal ch <- indicesSegmentFBSMemoryPrimary ch <- indicesSegmentFBSMemoryTotal ch <- indicesCompletionPrimary ch <- indicesCompletionTotal ch <- indicesSearchQueryTimeTotal ch <- indicesActiveQueries ch <- indicesSearchQueryTotal ch <- indicesSearchFetchTimeTotal ch <- indicesSearchFetchTotal ch <- indicesSearchScrollTimeTotal ch <- indicesSearchScrollCurrent ch <- indicesSearchScrollTotal ch <- indicesSearchSuggestTimeTotal ch <- indicesSearchSuggestTotal ch <- indicesIndexingTimeTotal ch <- indicesIndexCurrent ch <- indicesIndexingIndexTotal ch <- indicesIndexingDeleteSecondsTotal ch <- indicesIndexingDeleteTotal ch <- indicesIndexingNoopUpdateTotal ch <- indicesIndexingThrottleSecondsTotal ch <- indicesGetTimeTotal ch <- indicesGetTotal ch <- indicesMergeTimeTotal ch <- indicesMergeTotal ch <- indicesMergeThrottleTimeTotal ch <- indicesMergeStoppedTimeTotal ch <- indicesMergeAutoThrottleBytesTotal ch <- indicesRefreshTimeTotal ch <- indicesRefreshExternalTimeTotal ch <- indicesRefreshExternalTotal ch <- indicesRefreshTotal ch <- indicesFlushTimeTotal ch <- indicesFlushTotal ch <- indicesWarmerTimeTotal ch <- indicesWarmerTotal ch <- indicesQueryCacheMemoryTotal ch <- indicesQueryCacheSize ch <- indicesQueryCacheHits ch <- indicesQueryCacheMisses ch <- indicesQueryCacheCaches ch <- indicesQueryCacheEvictions ch <- indicesRequestCacheMemory ch <- indicesRequestCacheHits ch <- indicesRequestCacheMisses ch <- indicesRequestCacheEvictions ch <- indicesFielddataMemory ch <- indicesFielddataEvictions ch <- indicesAliases ch <- indicesShardDocs ch <- indicesShardDocsDeleted ch <- indicesShardStoreSizeBytes } func (i *Indices) fetchAndDecodeIndexStats(ctx context.Context) (indexStatsResponse, error) { var isr indexStatsResponse u := i.url.ResolveReference(&url.URL{Path: "/_all/_stats"}) q := u.Query() q.Set("ignore_unavailable", "true") if i.shards { q.Set("level", "shards") } u.RawQuery = q.Encode() resp, err := getURL(ctx, i.client, i.logger, u.String()) if err != nil { return isr, err } if err := json.Unmarshal(resp, &isr); err != nil { return isr, err } if i.aliases { isr.Aliases = map[string][]string{} u := i.url.ResolveReference(&url.URL{Path: "_alias"}) resp, err := getURL(ctx, i.client, i.logger, u.String()) if err != nil { i.logger.Error("error getting alias information", "err", err) return isr, err } var asr aliasesResponse if err := json.Unmarshal(resp, &asr); err != nil { return isr, err } for indexName, aliases := range asr { var aliasList []string for aliasName := range aliases.Aliases { aliasList = append(aliasList, aliasName) } if len(aliasList) > 0 { sort.Strings(aliasList) isr.Aliases[indexName] = aliasList } } } return isr, nil } // getClusterName returns the cluster name. If no clusterinfo retriever is // attached (e.g. /probe mode) it performs a lightweight call to the root // endpoint once and caches the result. func (i *Indices) getClusterName() string { if i.lastClusterInfo != nil && i.lastClusterInfo.ClusterName != "unknown_cluster" { return i.lastClusterInfo.ClusterName } u := *i.url u.Path = path.Join(u.Path, "/") resp, err := i.client.Get(u.String()) if err == nil { defer resp.Body.Close() if resp.StatusCode == http.StatusOK { var root struct { ClusterName string `json:"cluster_name"` } if err := json.NewDecoder(resp.Body).Decode(&root); err == nil && root.ClusterName != "" { i.lastClusterInfo = &clusterinfo.Response{ClusterName: root.ClusterName} return root.ClusterName } } } return "unknown_cluster" } // Collect gets Indices metric values func (i *Indices) Collect(ch chan<- prometheus.Metric) { // indices ctx := context.TODO() indexStatsResp, err := i.fetchAndDecodeIndexStats(ctx) if err != nil { i.logger.Warn( "failed to fetch and decode index stats", "err", err, ) return } // Alias stats if i.aliases { for indexName, aliases := range indexStatsResp.Aliases { for _, alias := range aliases { ch <- prometheus.MustNewConstMetric( indicesAliases, prometheus.GaugeValue, 1, indexName, alias, i.getClusterName(), ) } } } // Index stats for indexName, indexStats := range indexStatsResp.Indices { ch <- prometheus.MustNewConstMetric( indicesDocsPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Docs.Count), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesDeletedDocsPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Docs.Deleted), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesDocsTotal, prometheus.GaugeValue, float64(indexStats.Total.Docs.Count), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesDeletedDocsTotal, prometheus.GaugeValue, float64(indexStats.Total.Docs.Deleted), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesStoreSizeBytesPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Store.SizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesStoreSizeBytesTotal, prometheus.GaugeValue, float64(indexStats.Total.Store.SizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentCountPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.Count), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentCountTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.Count), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentMemoryBytesPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.MemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentMemoryBytesTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.MemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentTermsMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.TermsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentTermsMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.TermsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentFieldsMemoryBytesPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.StoredFieldsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentFieldsMemoryBytesTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.StoredFieldsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentTermVectorsMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.TermVectorsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentTermVectorsMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.TermVectorsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentNormsMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.NormsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentNormsMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.NormsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentPointsMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.PointsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentPointsMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.PointsMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentDocValuesMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.DocValuesMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentDocValuesMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.DocValuesMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentIndexWriterMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.IndexWriterMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentIndexWriterMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.IndexWriterMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentVersionMapMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.VersionMapMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentVersionMapMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.VersionMapMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentFBSMemoryPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Segments.FixedBitSetMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSegmentFBSMemoryTotal, prometheus.GaugeValue, float64(indexStats.Total.Segments.FixedBitSetMemoryInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesCompletionPrimary, prometheus.GaugeValue, float64(indexStats.Primaries.Completion.SizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesCompletionTotal, prometheus.GaugeValue, float64(indexStats.Total.Completion.SizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchQueryTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Search.QueryTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesActiveQueries, prometheus.GaugeValue, float64(indexStats.Total.Search.QueryCurrent), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchQueryTotal, prometheus.CounterValue, float64(indexStats.Total.Search.QueryTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchFetchTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Search.FetchTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchFetchTotal, prometheus.CounterValue, float64(indexStats.Total.Search.FetchTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchScrollTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Search.ScrollTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchScrollCurrent, prometheus.GaugeValue, float64(indexStats.Total.Search.ScrollCurrent), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchScrollTotal, prometheus.CounterValue, float64(indexStats.Total.Search.ScrollTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchSuggestTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Search.SuggestTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesSearchSuggestTotal, prometheus.CounterValue, float64(indexStats.Total.Search.SuggestTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.IndexTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexCurrent, prometheus.GaugeValue, float64(indexStats.Total.Indexing.IndexCurrent), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingIndexTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.IndexTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingDeleteSecondsTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.DeleteTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingDeleteTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.DeleteTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingNoopUpdateTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.NoopUpdateTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesIndexingThrottleSecondsTotal, prometheus.CounterValue, float64(indexStats.Total.Indexing.ThrottleTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesGetTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Get.TimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesGetTotal, prometheus.CounterValue, float64(indexStats.Total.Get.Total), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesMergeTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Merges.TotalTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesMergeTotal, prometheus.CounterValue, float64(indexStats.Total.Merges.Total), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesMergeThrottleTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Merges.TotalThrottledTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesMergeStoppedTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Merges.TotalStoppedTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesMergeAutoThrottleBytesTotal, prometheus.CounterValue, float64(indexStats.Total.Merges.TotalAutoThrottleInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRefreshTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Refresh.TotalTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRefreshExternalTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Refresh.ExternalTotalTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRefreshExternalTotal, prometheus.CounterValue, float64(indexStats.Total.Refresh.ExternalTotal), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRefreshTotal, prometheus.CounterValue, float64(indexStats.Total.Refresh.Total), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesFlushTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Flush.TotalTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesFlushTotal, prometheus.CounterValue, float64(indexStats.Total.Flush.Total), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesWarmerTimeTotal, prometheus.CounterValue, float64(indexStats.Total.Warmer.TotalTimeInMillis)/1000, indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesWarmerTotal, prometheus.CounterValue, float64(indexStats.Total.Warmer.Total), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheMemoryTotal, prometheus.CounterValue, float64(indexStats.Total.QueryCache.MemorySizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheSize, prometheus.GaugeValue, float64(indexStats.Total.QueryCache.CacheSize), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheHits, prometheus.CounterValue, float64(indexStats.Total.QueryCache.HitCount), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheMisses, prometheus.CounterValue, float64(indexStats.Total.QueryCache.MissCount), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheCaches, prometheus.CounterValue, float64(indexStats.Total.QueryCache.CacheCount), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesQueryCacheEvictions, prometheus.CounterValue, float64(indexStats.Total.QueryCache.Evictions), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRequestCacheMemory, prometheus.CounterValue, float64(indexStats.Total.RequestCache.MemorySizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRequestCacheHits, prometheus.CounterValue, float64(indexStats.Total.RequestCache.HitCount), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRequestCacheMisses, prometheus.CounterValue, float64(indexStats.Total.RequestCache.MissCount), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesRequestCacheEvictions, prometheus.CounterValue, float64(indexStats.Total.RequestCache.Evictions), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesFielddataMemory, prometheus.CounterValue, float64(indexStats.Total.Fielddata.MemorySizeInBytes), indexName, i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesFielddataEvictions, prometheus.CounterValue, float64(indexStats.Total.Fielddata.Evictions), indexName, i.getClusterName(), ) if i.shards { for shardNumber, shards := range indexStats.Shards { for _, shard := range shards { ch <- prometheus.MustNewConstMetric( indicesShardDocs, prometheus.GaugeValue, float64(shard.Docs.Count), indexName, shardNumber, shard.Routing.Node, strconv.FormatBool(shard.Routing.Primary), i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesShardDocsDeleted, prometheus.GaugeValue, float64(shard.Docs.Deleted), indexName, shardNumber, shard.Routing.Node, strconv.FormatBool(shard.Routing.Primary), i.getClusterName(), ) ch <- prometheus.MustNewConstMetric( indicesShardStoreSizeBytes, prometheus.GaugeValue, float64(shard.Store.SizeInBytes), indexName, shardNumber, shard.Routing.Node, strconv.FormatBool(shard.Routing.Primary), i.getClusterName(), ) } } } } } prometheus-elasticsearch-exporter-1.10.0/collector/indices_mappings.go000066400000000000000000000102321511562765300263040ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "path" "github.com/prometheus/client_golang/prometheus" ) var defaultIndicesMappingsLabels = []string{"index"} type indicesMappingsMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(indexMapping IndexMapping) float64 } // IndicesMappings information struct type IndicesMappings struct { logger *slog.Logger client *http.Client url *url.URL metrics []*indicesMappingsMetric } // NewIndicesMappings defines Indices IndexMappings Prometheus metrics func NewIndicesMappings(logger *slog.Logger, client *http.Client, url *url.URL) *IndicesMappings { subsystem := "indices_mappings_stats" return &IndicesMappings{ logger: logger, client: client, url: url, metrics: []*indicesMappingsMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, subsystem, "fields"), "Current number fields within cluster.", defaultIndicesMappingsLabels, nil, ), Value: func(indexMapping IndexMapping) float64 { return countFieldsRecursive(indexMapping.Mappings.Properties, 0) }, }, }, } } func countFieldsRecursive(properties IndexMappingProperties, fieldCounter float64) float64 { // iterate over all properties for _, property := range properties { if property.Type != nil && *property.Type != "object" { // property has a type set - counts as a field unless the value is object // as the recursion below will handle counting that fieldCounter++ // iterate over all fields of that property for _, field := range property.Fields { // field has a type set - counts as a field if field.Type != nil { fieldCounter++ } } } // count recursively in case the property has more properties if property.Properties != nil { fieldCounter = 1 + countFieldsRecursive(property.Properties, fieldCounter) } } return fieldCounter } // Describe add Snapshots metrics descriptions func (im *IndicesMappings) Describe(ch chan<- *prometheus.Desc) { for _, metric := range im.metrics { ch <- metric.Desc } } func (im *IndicesMappings) getAndParseURL(u *url.URL) (*IndicesMappingsResponse, error) { res, err := im.client.Get(u.String()) if err != nil { return nil, fmt.Errorf("failed to get from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } if res.StatusCode != http.StatusOK { return nil, fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } body, err := io.ReadAll(res.Body) if err != nil { im.logger.Warn("failed to read response body", "err", err) return nil, err } err = res.Body.Close() if err != nil { im.logger.Warn("failed to close response body", "err", err) return nil, err } var imr IndicesMappingsResponse if err := json.Unmarshal(body, &imr); err != nil { return nil, err } return &imr, nil } func (im *IndicesMappings) fetchAndDecodeIndicesMappings() (*IndicesMappingsResponse, error) { u := *im.url u.Path = path.Join(u.Path, "/_all/_mappings") return im.getAndParseURL(&u) } // Collect gets all indices mappings metric values func (im *IndicesMappings) Collect(ch chan<- prometheus.Metric) { indicesMappingsResponse, err := im.fetchAndDecodeIndicesMappings() if err != nil { im.logger.Warn( "failed to fetch and decode cluster mappings stats", "err", err, ) return } for _, metric := range im.metrics { for indexName, mappings := range *indicesMappingsResponse { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(mappings), indexName, ) } } } prometheus-elasticsearch-exporter-1.10.0/collector/indices_mappings_response.go000066400000000000000000000034441511562765300302310ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector // IndicesMappingsResponse is a representation of elasticsearch mappings for each index type IndicesMappingsResponse map[string]IndexMapping // IndexMapping defines the struct of the tree for the mappings of each index type IndexMapping struct { Mappings IndexMappings `json:"mappings"` } // IndexMappings defines all index mappings type IndexMappings struct { Properties IndexMappingProperties `json:"properties"` } // IndexMappingProperties defines all the properties of the current mapping type IndexMappingProperties map[string]*IndexMappingProperty // IndexMappingFields defines all the fields of the current mapping type IndexMappingFields map[string]*IndexMappingField // IndexMappingProperty defines a single property of the current index properties type IndexMappingProperty struct { Type *string `json:"type"` Properties IndexMappingProperties `json:"properties"` Fields IndexMappingFields `json:"fields"` } // IndexMappingField defines a single property of the current index field type IndexMappingField struct { Type *string `json:"type"` Properties IndexMappingProperties `json:"properties"` Fields IndexMappingFields `json:"fields"` } prometheus-elasticsearch-exporter-1.10.0/collector/indices_mappings_test.go000066400000000000000000000065361511562765300273570ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestMapping(t *testing.T) { // Testcases created using: // docker run -p 9200:9200 -e "discovery.type=single-node" elasticsearch:7.8.0 // curl -XPUT http://localhost:9200/twitter // curl -XPUT http://localhost:9200/facebook /* curl -XPUT http://localhost:9200/twitter/_mapping -H 'Content-Type: application/json' -d'{ "properties": { "email": { "type": "keyword" }, "phone": { "type": "keyword" } } }'*/ /* curl -XPUT http://localhost:9200/facebook/_mapping -H 'Content-Type: application/json' -d'{ "properties": { "name": { "type": "text", "fields": { "raw": { "type": "keyword" } } }, "contact": { "properties": { "email": { "type": "text", "fields": { "raw": { "type": "keyword" } } }, "phone": { "type": "text" } } } } }'*/ // curl http://localhost:9200/_all/_mapping tests := []struct { name string file string want string }{ { name: "7.8.0", file: "../fixtures/indices_mappings/7.8.0.json", want: ` # HELP elasticsearch_indices_mappings_stats_fields Current number fields within cluster. # TYPE elasticsearch_indices_mappings_stats_fields gauge elasticsearch_indices_mappings_stats_fields{index="facebook"} 6 elasticsearch_indices_mappings_stats_fields{index="twitter"} 2 `, }, { name: "counts", file: "../fixtures/indices_mappings/counts.json", want: ` # HELP elasticsearch_indices_mappings_stats_fields Current number fields within cluster. # TYPE elasticsearch_indices_mappings_stats_fields gauge elasticsearch_indices_mappings_stats_fields{index="test-data-2023.01.20"} 40 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c := NewIndicesMappings(promslog.NewNopLogger(), http.DefaultClient, u) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(c, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/indices_response.go000066400000000000000000000240451511562765300263330ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector // indexStatsResponse is a representation of a Elasticsearch Index Stats type indexStatsResponse struct { Shards IndexStatsShardsResponse `json:"_shards"` All IndexStatsIndexResponse `json:"_all"` Indices map[string]IndexStatsIndexResponse `json:"indices"` Aliases map[string][]string } // aliasesResponse is a representation of a Elasticsearch Alias Query type aliasesResponse map[string]aliasMapping // aliasMapping is a mapping of index names to a map of associated alias names where the alias names are keys type aliasMapping struct { Aliases map[string]map[string]interface{} `json:"aliases"` } // IndexStatsShardsResponse defines index stats shards information structure type IndexStatsShardsResponse struct { Total int64 `json:"total"` Successful int64 `json:"successful"` Failed int64 `json:"failed"` } // IndexStatsIndexResponse defines index stats index information structure type IndexStatsIndexResponse struct { Primaries IndexStatsIndexDetailResponse `json:"primaries"` Total IndexStatsIndexDetailResponse `json:"total"` Shards map[string][]IndexStatsIndexShardsDetailResponse `json:"shards"` } // IndexStatsIndexDetailResponse defines index stats index details information structure type IndexStatsIndexDetailResponse struct { Docs IndexStatsIndexDocsResponse `json:"docs"` Store IndexStatsIndexStoreResponse `json:"store"` Indexing IndexStatsIndexIndexingResponse `json:"indexing"` Get IndexStatsIndexGetResponse `json:"get"` Search IndexStatsIndexSearchResponse `json:"search"` Merges IndexStatsIndexMergesResponse `json:"merges"` Refresh IndexStatsIndexRefreshResponse `json:"refresh"` Flush IndexStatsIndexFlushResponse `json:"flush"` Warmer IndexStatsIndexWarmerResponse `json:"warmer"` QueryCache IndexStatsIndexQueryCacheResponse `json:"query_cache"` Fielddata IndexStatsIndexFielddataResponse `json:"fielddata"` Completion IndexStatsIndexCompletionResponse `json:"completion"` Segments IndexStatsIndexSegmentsResponse `json:"segments"` Translog IndexStatsIndexTranslogResponse `json:"translog"` RequestCache IndexStatsIndexRequestCacheResponse `json:"request_cache"` Recovery IndexStatsIndexRecoveryResponse `json:"recovery"` } // IndexStatsIndexShardsDetailResponse defines index stats index shard details information structure type IndexStatsIndexShardsDetailResponse struct { *IndexStatsIndexDetailResponse Routing IndexStatsIndexRoutingResponse `json:"routing"` } // IndexStatsIndexRoutingResponse defines index stats index routing information structure type IndexStatsIndexRoutingResponse struct { Node string `json:"node"` Primary bool `json:"primary"` } // IndexStatsIndexDocsResponse defines index stats index documents information structure type IndexStatsIndexDocsResponse struct { Count int64 `json:"count"` Deleted int64 `json:"deleted"` } // IndexStatsIndexStoreResponse defines index stats index store information structure type IndexStatsIndexStoreResponse struct { SizeInBytes int64 `json:"size_in_bytes"` ThrottleTimeInMillis int64 `json:"throttle_time_in_millis"` } // IndexStatsIndexIndexingResponse defines index stats index indexing information structure type IndexStatsIndexIndexingResponse struct { IndexTotal int64 `json:"index_total"` IndexTimeInMillis int64 `json:"index_time_in_millis"` IndexCurrent int64 `json:"index_current"` IndexFailed int64 `json:"index_failed"` DeleteTotal int64 `json:"delete_total"` DeleteTimeInMillis int64 `json:"delete_time_in_millis"` DeleteCurrent int64 `json:"delete_current"` NoopUpdateTotal int64 `json:"noop_update_total"` IsThrottled bool `json:"is_throttled"` ThrottleTimeInMillis int64 `json:"throttle_time_in_millis"` } // IndexStatsIndexGetResponse defines index stats index get information structure type IndexStatsIndexGetResponse struct { Total int64 `json:"total"` TimeInMillis int64 `json:"time_in_millis"` ExistsTotal int64 `json:"exists_total"` ExistsTimeInMillis int64 `json:"exists_time_in_millis"` MissingTotal int64 `json:"missing_total"` MissingTimeInMillis int64 `json:"missing_time_in_millis"` Current int64 `json:"current"` } // IndexStatsIndexSearchResponse defines index stats index search information structure type IndexStatsIndexSearchResponse struct { OpenContexts int64 `json:"open_contexts"` QueryTotal int64 `json:"query_total"` QueryTimeInMillis int64 `json:"query_time_in_millis"` QueryCurrent int64 `json:"query_current"` FetchTotal int64 `json:"fetch_total"` FetchTimeInMillis int64 `json:"fetch_time_in_millis"` FetchCurrent int64 `json:"fetch_current"` ScrollTotal int64 `json:"scroll_total"` ScrollTimeInMillis int64 `json:"scroll_time_in_millis"` ScrollCurrent int64 `json:"scroll_current"` SuggestTotal int64 `json:"suggest_total"` SuggestTimeInMillis int64 `json:"suggest_time_in_millis"` SuggestCurrent int64 `json:"suggest_current"` } // IndexStatsIndexMergesResponse defines index stats index merges information structure type IndexStatsIndexMergesResponse struct { Current int64 `json:"current"` CurrentDocs int64 `json:"current_docs"` CurrentSizeInBytes int64 `json:"current_size_in_bytes"` Total int64 `json:"total"` TotalTimeInMillis int64 `json:"total_time_in_millis"` TotalDocs int64 `json:"total_docs"` TotalSizeInBytes int64 `json:"total_size_in_bytes"` TotalStoppedTimeInMillis int64 `json:"total_stopped_time_in_millis"` TotalThrottledTimeInMillis int64 `json:"total_throttled_time_in_millis"` TotalAutoThrottleInBytes int64 `json:"total_auto_throttle_in_bytes"` } // IndexStatsIndexRefreshResponse defines index stats index refresh information structure type IndexStatsIndexRefreshResponse struct { Total int64 `json:"total"` TotalTimeInMillis int64 `json:"total_time_in_millis"` ExternalTotal int64 `json:"external_total"` ExternalTotalTimeInMillis int64 `json:"external_total_time_in_millis"` Listeners int64 `json:"listeners"` } // IndexStatsIndexFlushResponse defines index stats index flush information structure type IndexStatsIndexFlushResponse struct { Total int64 `json:"total"` TotalTimeInMillis int64 `json:"total_time_in_millis"` } // IndexStatsIndexWarmerResponse defines index stats index warmer information structure type IndexStatsIndexWarmerResponse struct { Current int64 `json:"current"` Total int64 `json:"total"` TotalTimeInMillis int64 `json:"total_time_in_millis"` } // IndexStatsIndexQueryCacheResponse defines index stats index query cache information structure type IndexStatsIndexQueryCacheResponse struct { MemorySizeInBytes int64 `json:"memory_size_in_bytes"` TotalCount int64 `json:"total_count"` HitCount int64 `json:"hit_count"` MissCount int64 `json:"miss_count"` CacheSize int64 `json:"cache_size"` CacheCount int64 `json:"cache_count"` Evictions int64 `json:"evictions"` } // IndexStatsIndexFielddataResponse defines index stats index fielddata information structure type IndexStatsIndexFielddataResponse struct { MemorySizeInBytes int64 `json:"memory_size_in_bytes"` Evictions int64 `json:"evictions"` } // IndexStatsIndexCompletionResponse defines index stats index completion information structure type IndexStatsIndexCompletionResponse struct { SizeInBytes int64 `json:"size_in_bytes"` } // IndexStatsIndexSegmentsResponse defines index stats index segments information structure type IndexStatsIndexSegmentsResponse struct { Count int64 `json:"count"` MemoryInBytes int64 `json:"memory_in_bytes"` TermsMemoryInBytes int64 `json:"terms_memory_in_bytes"` StoredFieldsMemoryInBytes int64 `json:"stored_fields_memory_in_bytes"` TermVectorsMemoryInBytes int64 `json:"term_vectors_memory_in_bytes"` NormsMemoryInBytes int64 `json:"norms_memory_in_bytes"` PointsMemoryInBytes int64 `json:"points_memory_in_bytes"` DocValuesMemoryInBytes int64 `json:"doc_values_memory_in_bytes"` IndexWriterMemoryInBytes int64 `json:"index_writer_memory_in_bytes"` VersionMapMemoryInBytes int64 `json:"version_map_memory_in_bytes"` FixedBitSetMemoryInBytes int64 `json:"fixed_bit_set_memory_in_bytes"` MaxUnsafeAutoIDTimestamp int64 `json:"max_unsafe_auto_id_timestamp"` } // IndexStatsIndexTranslogResponse defines index stats index translog information structure type IndexStatsIndexTranslogResponse struct { Operations int64 `json:"operations"` SizeInBytes int64 `json:"size_in_bytes"` } // IndexStatsIndexRequestCacheResponse defines index stats index request cache information structure type IndexStatsIndexRequestCacheResponse struct { MemorySizeInBytes int64 `json:"memory_size_in_bytes"` Evictions int64 `json:"evictions"` HitCount int64 `json:"hit_count"` MissCount int64 `json:"miss_count"` } // IndexStatsIndexRecoveryResponse defines index stats index recovery information structure type IndexStatsIndexRecoveryResponse struct { CurrentAsSource int64 `json:"current_as_source"` CurrentAsTarget int64 `json:"current_as_target"` ThrottleTimeInMillis int64 `json:"throttle_time_in_millis"` } prometheus-elasticsearch-exporter-1.10.0/collector/indices_settings.go000066400000000000000000000117231511562765300263340ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "path" "strconv" "github.com/prometheus/client_golang/prometheus" ) // IndicesSettings information struct type IndicesSettings struct { logger *slog.Logger client *http.Client url *url.URL readOnlyIndices prometheus.Gauge metrics []*indicesSettingsMetric } var ( defaultIndicesTotalFieldsLabels = []string{"index"} defaultTotalFieldsValue = 1000 // es default configuration for total fields defaultDateCreation = 0 // es index default creation date ) type indicesSettingsMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(indexSettings Settings) float64 } // NewIndicesSettings defines Indices Settings Prometheus metrics func NewIndicesSettings(logger *slog.Logger, client *http.Client, url *url.URL) *IndicesSettings { return &IndicesSettings{ logger: logger, client: client, url: url, readOnlyIndices: prometheus.NewGauge(prometheus.GaugeOpts{ Name: prometheus.BuildFQName(namespace, "indices_settings_stats", "read_only_indices"), Help: "Current number of read only indices within cluster", }), metrics: []*indicesSettingsMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_settings", "total_fields"), "index mapping setting for total_fields", defaultIndicesTotalFieldsLabels, nil, ), Value: func(indexSettings Settings) float64 { val, err := strconv.ParseFloat(indexSettings.IndexInfo.Mapping.TotalFields.Limit, 64) if err != nil { return float64(defaultTotalFieldsValue) } return val }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_settings", "replicas"), "index setting number_of_replicas", defaultIndicesTotalFieldsLabels, nil, ), Value: func(indexSettings Settings) float64 { val, err := strconv.ParseFloat(indexSettings.IndexInfo.NumberOfReplicas, 64) if err != nil { return float64(defaultTotalFieldsValue) } return val }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_settings", "creation_timestamp_seconds"), "index setting creation_date", defaultIndicesTotalFieldsLabels, nil, ), Value: func(indexSettings Settings) float64 { val, err := strconv.ParseFloat(indexSettings.IndexInfo.CreationDate, 64) if err != nil { return float64(defaultDateCreation) } return val / 1000.0 }, }, }, } } // Describe add Snapshots metrics descriptions func (cs *IndicesSettings) Describe(ch chan<- *prometheus.Desc) { ch <- cs.readOnlyIndices.Desc() for _, metric := range cs.metrics { ch <- metric.Desc } } func (cs *IndicesSettings) getAndParseURL(u *url.URL, data interface{}) error { res, err := cs.client.Get(u.String()) if err != nil { return fmt.Errorf("failed to get from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } defer func() { err = res.Body.Close() if err != nil { cs.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } bts, err := io.ReadAll(res.Body) if err != nil { return err } if err := json.Unmarshal(bts, data); err != nil { return err } return nil } func (cs *IndicesSettings) fetchAndDecodeIndicesSettings() (IndicesSettingsResponse, error) { u := *cs.url u.Path = path.Join(u.Path, "/_all/_settings") var asr IndicesSettingsResponse err := cs.getAndParseURL(&u, &asr) if err != nil { return asr, err } return asr, err } // Collect gets all indices settings metric values func (cs *IndicesSettings) Collect(ch chan<- prometheus.Metric) { asr, err := cs.fetchAndDecodeIndicesSettings() if err != nil { cs.readOnlyIndices.Set(0) cs.logger.Warn( "failed to fetch and decode cluster settings stats", "err", err, ) return } var c int for indexName, value := range asr { if value.Settings.IndexInfo.Blocks.ReadOnly == "true" { c++ } for _, metric := range cs.metrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(value.Settings), indexName, ) } } cs.readOnlyIndices.Set(float64(c)) ch <- cs.readOnlyIndices } prometheus-elasticsearch-exporter-1.10.0/collector/indices_settings_response.go000066400000000000000000000031271511562765300302510ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector // IndicesSettingsResponse is a representation of Elasticsearch Settings for each Index type IndicesSettingsResponse map[string]Index // Index defines the struct of the tree for the settings of each index type Index struct { Settings Settings `json:"settings"` } // Settings defines current index settings type Settings struct { IndexInfo IndexInfo `json:"index"` } // IndexInfo defines the blocks of the current index type IndexInfo struct { Blocks Blocks `json:"blocks"` Mapping Mapping `json:"mapping"` NumberOfReplicas string `json:"number_of_replicas"` CreationDate string `json:"creation_date"` } // Blocks defines whether current index has read_only_allow_delete enabled type Blocks struct { ReadOnly string `json:"read_only_allow_delete"` } // Mapping defines mapping settings type Mapping struct { TotalFields TotalFields `json:"total_fields"` } // TotalFields defines the limit on the number of mapped fields type TotalFields struct { Limit string `json:"limit"` } prometheus-elasticsearch-exporter-1.10.0/collector/indices_settings_test.go000066400000000000000000000103311511562765300273650ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "path" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestIndicesSettings(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION // curl -XPUT http://localhost:9200/twitter // curl -XPUT http://localhost:9200/facebook // curl -XPUT http://localhost:9200/instagram // curl -XPUT http://localhost:9200/viber // curl -XPUT http://localhost:9200/instagram/_settings --header "Content-Type: application/json" -d ' // { // "index": { // "mapping": { // "total_fields": { // "limit": 10000 // } // }, // "blocks": { // "read_only_allow_delete": "true" // } // } // }' // curl -XPUT http://localhost:9200/twitter/_settings --header "Content-Type: application/json" -d ' // { // "index": { // "blocks": { // "read_only_allow_delete": "true" // } // } // }' // curl http://localhost:9200/_all/_settings tests := []struct { name string file string want string }{ { name: "6.5.4", file: "6.5.4.json", want: `# HELP elasticsearch_indices_settings_creation_timestamp_seconds index setting creation_date # TYPE elasticsearch_indices_settings_creation_timestamp_seconds gauge elasticsearch_indices_settings_creation_timestamp_seconds{index="facebook"} 1.618593199101e+09 elasticsearch_indices_settings_creation_timestamp_seconds{index="instagram"} 1.618593203353e+09 elasticsearch_indices_settings_creation_timestamp_seconds{index="twitter"} 1.618593193641e+09 elasticsearch_indices_settings_creation_timestamp_seconds{index="viber"} 1.618593207186e+09 # HELP elasticsearch_indices_settings_replicas index setting number_of_replicas # TYPE elasticsearch_indices_settings_replicas gauge elasticsearch_indices_settings_replicas{index="facebook"} 1 elasticsearch_indices_settings_replicas{index="instagram"} 1 elasticsearch_indices_settings_replicas{index="twitter"} 1 elasticsearch_indices_settings_replicas{index="viber"} 1 # HELP elasticsearch_indices_settings_stats_read_only_indices Current number of read only indices within cluster # TYPE elasticsearch_indices_settings_stats_read_only_indices gauge elasticsearch_indices_settings_stats_read_only_indices 2 # HELP elasticsearch_indices_settings_total_fields index mapping setting for total_fields # TYPE elasticsearch_indices_settings_total_fields gauge elasticsearch_indices_settings_total_fields{index="facebook"} 1000 elasticsearch_indices_settings_total_fields{index="instagram"} 10000 elasticsearch_indices_settings_total_fields{index="twitter"} 1000 elasticsearch_indices_settings_total_fields{index="viber"} 1000 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(path.Join("../fixtures/indices_settings", tt.file)) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c := NewIndicesSettings(promslog.NewNopLogger(), http.DefaultClient, u) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(c, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/indices_test.go000066400000000000000000006613331511562765300254630ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "path" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestIndices(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION-alpine // curl -XPUT -H "Content-Type: application/json" http://localhost:9200/foo_1/type1/1 -d '{"title":"abc","content":"hello"}' // curl -XPUT -H "Content-Type: application/json" http://localhost:9200/foo_1/type1/2 -d '{"title":"def","content":"world"}' // curl -XPUT -H "Content-Type: application/json" http://localhost:9200/foo_2/type1/1 -d '{"title":"abc001","content":"hello001"}' // curl -XPUT -H "Content-Type: application/json" http://localhost:9200/foo_2/type1/2 -d '{"title":"def002","content":"world002"}' // curl -XPUT -H "Content-Type: application/json" http://localhost:9200/foo_2/type1/3 -d '{"title":"def003","content":"world003"}' // Make an index for foo_3 // curl -XPUT http://localhost:9200/foo_3 // curl -XPOST -H "Content-Type: application/json" http://localhost:9200/_aliases -d '{"actions": [{"add": {"index": "foo_2","alias": "foo_alias_2_1"}}]}' // curl -XPOST -H "Content-Type: application/json" http://localhost:9200/_aliases -d '{"actions": [{"add": {"index": "foo_3","alias": "foo_alias_3_2"}}]}' // curl -XPOST -H "Content-Type: application/json" http://localhost:9200/_aliases -d '{"actions": [{"add": {"index": "foo_3","alias": "foo_alias_3_1", "is_write_index": true, "routing": "title"}}]}' // curl http://localhost:9200/_all/_stats tests := []struct { name string file string shards bool want string }{ { name: "1.7.6", file: "1.7.6.json", want: `# HELP elasticsearch_index_stats_fielddata_evictions_total Total fielddata evictions count # TYPE elasticsearch_index_stats_fielddata_evictions_total counter elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_fielddata_memory_bytes_total Total fielddata memory bytes # TYPE elasticsearch_index_stats_fielddata_memory_bytes_total counter elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_time_seconds_total Total flush time in seconds # TYPE elasticsearch_index_stats_flush_time_seconds_total counter elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_total Total flush count # TYPE elasticsearch_index_stats_flush_total counter elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_time_seconds_total Total get time in seconds # TYPE elasticsearch_index_stats_get_time_seconds_total counter elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_total Total get count # TYPE elasticsearch_index_stats_get_total counter elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_index_current The number of documents currently being indexed to an index # TYPE elasticsearch_index_stats_index_current gauge elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_time_seconds_total Total indexing delete time in seconds # TYPE elasticsearch_index_stats_indexing_delete_time_seconds_total counter elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_total Total indexing delete count # TYPE elasticsearch_index_stats_indexing_delete_total counter elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_index_time_seconds_total Total indexing index time in seconds # TYPE elasticsearch_index_stats_indexing_index_time_seconds_total counter elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.046 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.006 # HELP elasticsearch_index_stats_indexing_index_total Total indexing index count # TYPE elasticsearch_index_stats_indexing_index_total counter elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_indexing_noop_update_total Total indexing no-op update count # TYPE elasticsearch_index_stats_indexing_noop_update_total counter elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_throttle_time_seconds_total Total indexing throttle time in seconds # TYPE elasticsearch_index_stats_indexing_throttle_time_seconds_total counter elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_auto_throttle_bytes_total Total bytes that were auto-throttled during merging # TYPE elasticsearch_index_stats_merge_auto_throttle_bytes_total counter elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_stopped_time_seconds_total Total large merge stopped time in seconds, allowing smaller merges to complete # TYPE elasticsearch_index_stats_merge_stopped_time_seconds_total counter elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_throttle_time_seconds_total Total merge I/O throttle time in seconds # TYPE elasticsearch_index_stats_merge_throttle_time_seconds_total counter elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_time_seconds_total Total merge time in seconds # TYPE elasticsearch_index_stats_merge_time_seconds_total counter elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_total Total merge count # TYPE elasticsearch_index_stats_merge_total counter elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_caches_total Total query cache caches count # TYPE elasticsearch_index_stats_query_cache_caches_total counter elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_evictions_total Total query cache evictions count # TYPE elasticsearch_index_stats_query_cache_evictions_total counter elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_hits_total Total query cache hits count # TYPE elasticsearch_index_stats_query_cache_hits_total counter elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_memory_bytes_total Total query cache memory bytes # TYPE elasticsearch_index_stats_query_cache_memory_bytes_total counter elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_misses_total Total query cache misses count # TYPE elasticsearch_index_stats_query_cache_misses_total counter elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_size Total query cache size # TYPE elasticsearch_index_stats_query_cache_size gauge elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_time_seconds_total Total external refresh time in seconds # TYPE elasticsearch_index_stats_refresh_external_time_seconds_total counter elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_total Total external refresh count # TYPE elasticsearch_index_stats_refresh_external_total counter elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_time_seconds_total Total refresh time in seconds # TYPE elasticsearch_index_stats_refresh_time_seconds_total counter elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.125 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.038 # HELP elasticsearch_index_stats_refresh_total Total refresh count # TYPE elasticsearch_index_stats_refresh_total counter elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_request_cache_evictions_total Total request cache evictions count # TYPE elasticsearch_index_stats_request_cache_evictions_total counter elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_hits_total Total request cache hits count # TYPE elasticsearch_index_stats_request_cache_hits_total counter elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_memory_bytes_total Total request cache memory bytes # TYPE elasticsearch_index_stats_request_cache_memory_bytes_total counter elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_misses_total Total request cache misses count # TYPE elasticsearch_index_stats_request_cache_misses_total counter elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_time_seconds_total Total search fetch time in seconds # TYPE elasticsearch_index_stats_search_fetch_time_seconds_total counter elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_total Total search fetch count # TYPE elasticsearch_index_stats_search_fetch_total counter elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_time_seconds_total Total search query time in seconds # TYPE elasticsearch_index_stats_search_query_time_seconds_total counter elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_total Total number of queries # TYPE elasticsearch_index_stats_search_query_total counter elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_current Current search scroll count # TYPE elasticsearch_index_stats_search_scroll_current gauge elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_time_seconds_total Total search scroll time in seconds # TYPE elasticsearch_index_stats_search_scroll_time_seconds_total counter elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_total Total search scroll count # TYPE elasticsearch_index_stats_search_scroll_total counter elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_time_seconds_total Total search suggest time in seconds # TYPE elasticsearch_index_stats_search_suggest_time_seconds_total counter elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_total Total search suggest count # TYPE elasticsearch_index_stats_search_suggest_total counter elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_index_stats_warmer_time_seconds_total counter elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.042 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_warmer_total Total warmer count # TYPE elasticsearch_index_stats_warmer_total counter elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_1"} 14 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_2"} 16 # HELP elasticsearch_indices_aliases Record aliases associated with an index # TYPE elasticsearch_indices_aliases gauge elasticsearch_indices_aliases{alias="foo_alias_2_1",cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_1",cluster="unknown_cluster",index="foo_3"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_2",cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_completion_bytes_primary Current size of completion with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_primary gauge elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_completion_bytes_total Current size of completion with all shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_total gauge elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_primary Count of deleted documents with only primary shards # TYPE elasticsearch_indices_deleted_docs_primary gauge elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_total Total count of deleted documents # TYPE elasticsearch_indices_deleted_docs_total gauge elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_docs_primary Count of documents with only primary shards # TYPE elasticsearch_indices_docs_primary gauge elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_docs_total Total count of documents # TYPE elasticsearch_indices_docs_total gauge elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_primary Current number of segments with only primary shards on all nodes # TYPE elasticsearch_indices_segment_count_primary gauge elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_total Current number of segments with all shards on all nodes # TYPE elasticsearch_indices_segment_count_total gauge elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_primary Current size of doc values with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_primary gauge elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_total Current size of doc values with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_total gauge elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fields_memory_bytes_primary Current size of fields with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_primary gauge elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fields_memory_bytes_total Current size of fields with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_total gauge elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary Current size of fixed bit with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total Current size of fixed bit with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_primary Current size of index writer with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_primary gauge elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_total Current size of index writer with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_total gauge elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_memory_bytes_primary Current size of segments with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_primary gauge elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 7364 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 11046 # HELP elasticsearch_indices_segment_memory_bytes_total Current size of segments with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_total gauge elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 7364 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 11046 # HELP elasticsearch_indices_segment_norms_memory_bytes_primary Current size of norms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_primary gauge elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_norms_memory_bytes_total Current size of norms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_total gauge elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_primary Current size of points with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_primary gauge elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_total Current size of points with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_total gauge elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_primary_bytes Current size of term vectors with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_primary_bytes gauge elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_total_bytes Current size of term vectors with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_total_bytes gauge elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_terms_memory_primary Current size of terms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_primary gauge elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_terms_memory_total Current number of terms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_total gauge elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_primary Current size of version map with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_primary gauge elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_total Current size of version map with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_total gauge elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_store_size_bytes_primary Current total size of stored index data in bytes with only primary shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_primary gauge elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_1"} 5591 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_2"} 8207 # HELP elasticsearch_indices_store_size_bytes_total Current total size of stored index data in bytes with all shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_total gauge elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_1"} 5591 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_2"} 8207 # HELP elasticsearch_search_active_queries The number of currently active queries # TYPE elasticsearch_search_active_queries gauge elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_2"} 0 `, }, { name: "2.4.5", file: "2.4.5.json", want: `# HELP elasticsearch_index_stats_fielddata_evictions_total Total fielddata evictions count # TYPE elasticsearch_index_stats_fielddata_evictions_total counter elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_fielddata_memory_bytes_total Total fielddata memory bytes # TYPE elasticsearch_index_stats_fielddata_memory_bytes_total counter elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_time_seconds_total Total flush time in seconds # TYPE elasticsearch_index_stats_flush_time_seconds_total counter elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_total Total flush count # TYPE elasticsearch_index_stats_flush_total counter elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_time_seconds_total Total get time in seconds # TYPE elasticsearch_index_stats_get_time_seconds_total counter elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_total Total get count # TYPE elasticsearch_index_stats_get_total counter elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_index_current The number of documents currently being indexed to an index # TYPE elasticsearch_index_stats_index_current gauge elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_time_seconds_total Total indexing delete time in seconds # TYPE elasticsearch_index_stats_indexing_delete_time_seconds_total counter elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_total Total indexing delete count # TYPE elasticsearch_index_stats_indexing_delete_total counter elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_index_time_seconds_total Total indexing index time in seconds # TYPE elasticsearch_index_stats_indexing_index_time_seconds_total counter elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.034 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.006 # HELP elasticsearch_index_stats_indexing_index_total Total indexing index count # TYPE elasticsearch_index_stats_indexing_index_total counter elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_indexing_noop_update_total Total indexing no-op update count # TYPE elasticsearch_index_stats_indexing_noop_update_total counter elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_throttle_time_seconds_total Total indexing throttle time in seconds # TYPE elasticsearch_index_stats_indexing_throttle_time_seconds_total counter elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_auto_throttle_bytes_total Total bytes that were auto-throttled during merging # TYPE elasticsearch_index_stats_merge_auto_throttle_bytes_total counter elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_1"} 1.048576e+08 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_2"} 1.048576e+08 # HELP elasticsearch_index_stats_merge_stopped_time_seconds_total Total large merge stopped time in seconds, allowing smaller merges to complete # TYPE elasticsearch_index_stats_merge_stopped_time_seconds_total counter elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_throttle_time_seconds_total Total merge I/O throttle time in seconds # TYPE elasticsearch_index_stats_merge_throttle_time_seconds_total counter elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_time_seconds_total Total merge time in seconds # TYPE elasticsearch_index_stats_merge_time_seconds_total counter elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_total Total merge count # TYPE elasticsearch_index_stats_merge_total counter elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_caches_total Total query cache caches count # TYPE elasticsearch_index_stats_query_cache_caches_total counter elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_evictions_total Total query cache evictions count # TYPE elasticsearch_index_stats_query_cache_evictions_total counter elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_hits_total Total query cache hits count # TYPE elasticsearch_index_stats_query_cache_hits_total counter elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_memory_bytes_total Total query cache memory bytes # TYPE elasticsearch_index_stats_query_cache_memory_bytes_total counter elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_misses_total Total query cache misses count # TYPE elasticsearch_index_stats_query_cache_misses_total counter elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_size Total query cache size # TYPE elasticsearch_index_stats_query_cache_size gauge elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_time_seconds_total Total external refresh time in seconds # TYPE elasticsearch_index_stats_refresh_external_time_seconds_total counter elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_total Total external refresh count # TYPE elasticsearch_index_stats_refresh_external_total counter elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_time_seconds_total Total refresh time in seconds # TYPE elasticsearch_index_stats_refresh_time_seconds_total counter elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.137 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.034 # HELP elasticsearch_index_stats_refresh_total Total refresh count # TYPE elasticsearch_index_stats_refresh_total counter elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_request_cache_evictions_total Total request cache evictions count # TYPE elasticsearch_index_stats_request_cache_evictions_total counter elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_hits_total Total request cache hits count # TYPE elasticsearch_index_stats_request_cache_hits_total counter elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_memory_bytes_total Total request cache memory bytes # TYPE elasticsearch_index_stats_request_cache_memory_bytes_total counter elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_misses_total Total request cache misses count # TYPE elasticsearch_index_stats_request_cache_misses_total counter elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_time_seconds_total Total search fetch time in seconds # TYPE elasticsearch_index_stats_search_fetch_time_seconds_total counter elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_total Total search fetch count # TYPE elasticsearch_index_stats_search_fetch_total counter elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_time_seconds_total Total search query time in seconds # TYPE elasticsearch_index_stats_search_query_time_seconds_total counter elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_total Total number of queries # TYPE elasticsearch_index_stats_search_query_total counter elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_current Current search scroll count # TYPE elasticsearch_index_stats_search_scroll_current gauge elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_time_seconds_total Total search scroll time in seconds # TYPE elasticsearch_index_stats_search_scroll_time_seconds_total counter elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_total Total search scroll count # TYPE elasticsearch_index_stats_search_scroll_total counter elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_time_seconds_total Total search suggest time in seconds # TYPE elasticsearch_index_stats_search_suggest_time_seconds_total counter elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_total Total search suggest count # TYPE elasticsearch_index_stats_search_suggest_total counter elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_index_stats_warmer_time_seconds_total counter elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.012 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_warmer_total Total warmer count # TYPE elasticsearch_index_stats_warmer_total counter elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_1"} 14 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_2"} 16 # HELP elasticsearch_indices_aliases Record aliases associated with an index # TYPE elasticsearch_indices_aliases gauge elasticsearch_indices_aliases{alias="foo_alias_2_1",cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_1",cluster="unknown_cluster",index="foo_3"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_2",cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_completion_bytes_primary Current size of completion with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_primary gauge elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_completion_bytes_total Current size of completion with all shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_total gauge elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_primary Count of deleted documents with only primary shards # TYPE elasticsearch_indices_deleted_docs_primary gauge elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_total Total count of deleted documents # TYPE elasticsearch_indices_deleted_docs_total gauge elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_docs_primary Count of documents with only primary shards # TYPE elasticsearch_indices_docs_primary gauge elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_docs_total Total count of documents # TYPE elasticsearch_indices_docs_total gauge elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_primary Current number of segments with only primary shards on all nodes # TYPE elasticsearch_indices_segment_count_primary gauge elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_total Current number of segments with all shards on all nodes # TYPE elasticsearch_indices_segment_count_total gauge elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_primary Current size of doc values with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_primary gauge elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 184 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 276 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_total Current size of doc values with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_total gauge elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 184 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 276 # HELP elasticsearch_indices_segment_fields_memory_bytes_primary Current size of fields with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_primary gauge elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 624 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 936 # HELP elasticsearch_indices_segment_fields_memory_bytes_total Current size of fields with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_total gauge elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 624 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 936 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary Current size of fixed bit with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total Current size of fixed bit with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_primary Current size of index writer with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_primary gauge elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_total Current size of index writer with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_total gauge elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_memory_bytes_primary Current size of segments with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_primary gauge elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 4212 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 6318 # HELP elasticsearch_indices_segment_memory_bytes_total Current size of segments with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_total gauge elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 4212 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 6318 # HELP elasticsearch_indices_segment_norms_memory_bytes_primary Current size of norms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_primary gauge elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 384 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 576 # HELP elasticsearch_indices_segment_norms_memory_bytes_total Current size of norms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_total gauge elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 384 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 576 # HELP elasticsearch_indices_segment_points_memory_bytes_primary Current size of points with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_primary gauge elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_total Current size of points with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_total gauge elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_primary_bytes Current size of term vectors with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_primary_bytes gauge elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_total_bytes Current size of term vectors with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_total_bytes gauge elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_terms_memory_primary Current size of terms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_primary gauge elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_1"} 3020 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_2"} 4530 # HELP elasticsearch_indices_segment_terms_memory_total Current number of terms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_total gauge elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_1"} 3020 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_2"} 4530 # HELP elasticsearch_indices_segment_version_map_memory_bytes_primary Current size of version map with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_primary gauge elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_total Current size of version map with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_total gauge elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_store_size_bytes_primary Current total size of stored index data in bytes with only primary shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_primary gauge elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_1"} 260 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_2"} 3350 # HELP elasticsearch_indices_store_size_bytes_total Current total size of stored index data in bytes with all shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_total gauge elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_1"} 260 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_2"} 3350 # HELP elasticsearch_search_active_queries The number of currently active queries # TYPE elasticsearch_search_active_queries gauge elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_2"} 0 `, }, { name: "5.4.2", file: "5.4.2.json", want: `# HELP elasticsearch_index_stats_fielddata_evictions_total Total fielddata evictions count # TYPE elasticsearch_index_stats_fielddata_evictions_total counter elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_fielddata_memory_bytes_total Total fielddata memory bytes # TYPE elasticsearch_index_stats_fielddata_memory_bytes_total counter elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_time_seconds_total Total flush time in seconds # TYPE elasticsearch_index_stats_flush_time_seconds_total counter elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_flush_total Total flush count # TYPE elasticsearch_index_stats_flush_total counter elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_time_seconds_total Total get time in seconds # TYPE elasticsearch_index_stats_get_time_seconds_total counter elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_get_total Total get count # TYPE elasticsearch_index_stats_get_total counter elasticsearch_index_stats_get_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_index_current The number of documents currently being indexed to an index # TYPE elasticsearch_index_stats_index_current gauge elasticsearch_index_stats_index_current{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_time_seconds_total Total indexing delete time in seconds # TYPE elasticsearch_index_stats_indexing_delete_time_seconds_total counter elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_delete_total Total indexing delete count # TYPE elasticsearch_index_stats_indexing_delete_total counter elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_index_time_seconds_total Total indexing index time in seconds # TYPE elasticsearch_index_stats_indexing_index_time_seconds_total counter elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0.013 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0.106 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index=".watches"} 1.421 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.046 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.012 # HELP elasticsearch_index_stats_indexing_index_total Total indexing index count # TYPE elasticsearch_index_stats_indexing_index_total counter elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index=".monitoring-data-2"} 4 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 65 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_indexing_noop_update_total Total indexing no-op update count # TYPE elasticsearch_index_stats_indexing_noop_update_total counter elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_indexing_throttle_time_seconds_total Total indexing throttle time in seconds # TYPE elasticsearch_index_stats_indexing_throttle_time_seconds_total counter elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_auto_throttle_bytes_total Total bytes that were auto-throttled during merging # TYPE elasticsearch_index_stats_merge_auto_throttle_bytes_total counter elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index=".watches"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_1"} 1.048576e+08 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_2"} 1.048576e+08 # HELP elasticsearch_index_stats_merge_stopped_time_seconds_total Total large merge stopped time in seconds, allowing smaller merges to complete # TYPE elasticsearch_index_stats_merge_stopped_time_seconds_total counter elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_throttle_time_seconds_total Total merge I/O throttle time in seconds # TYPE elasticsearch_index_stats_merge_throttle_time_seconds_total counter elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_time_seconds_total Total merge time in seconds # TYPE elasticsearch_index_stats_merge_time_seconds_total counter elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_merge_total Total merge count # TYPE elasticsearch_index_stats_merge_total counter elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_caches_total Total query cache caches count # TYPE elasticsearch_index_stats_query_cache_caches_total counter elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_evictions_total Total query cache evictions count # TYPE elasticsearch_index_stats_query_cache_evictions_total counter elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_hits_total Total query cache hits count # TYPE elasticsearch_index_stats_query_cache_hits_total counter elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_memory_bytes_total Total query cache memory bytes # TYPE elasticsearch_index_stats_query_cache_memory_bytes_total counter elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_misses_total Total query cache misses count # TYPE elasticsearch_index_stats_query_cache_misses_total counter elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_query_cache_size Total query cache size # TYPE elasticsearch_index_stats_query_cache_size gauge elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_time_seconds_total Total external refresh time in seconds # TYPE elasticsearch_index_stats_refresh_external_time_seconds_total counter elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_external_total Total external refresh count # TYPE elasticsearch_index_stats_refresh_external_total counter elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_refresh_time_seconds_total Total refresh time in seconds # TYPE elasticsearch_index_stats_refresh_time_seconds_total counter elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0.074 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0.39 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0.771 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.084 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.042 # HELP elasticsearch_index_stats_refresh_total Total refresh count # TYPE elasticsearch_index_stats_refresh_total counter elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index=".monitoring-data-2"} 2 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 3 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index=".watches"} 5 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_index_stats_request_cache_evictions_total Total request cache evictions count # TYPE elasticsearch_index_stats_request_cache_evictions_total counter elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_hits_total Total request cache hits count # TYPE elasticsearch_index_stats_request_cache_hits_total counter elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_memory_bytes_total Total request cache memory bytes # TYPE elasticsearch_index_stats_request_cache_memory_bytes_total counter elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_request_cache_misses_total Total request cache misses count # TYPE elasticsearch_index_stats_request_cache_misses_total counter elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_time_seconds_total Total search fetch time in seconds # TYPE elasticsearch_index_stats_search_fetch_time_seconds_total counter elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_fetch_total Total search fetch count # TYPE elasticsearch_index_stats_search_fetch_total counter elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_time_seconds_total Total search query time in seconds # TYPE elasticsearch_index_stats_search_query_time_seconds_total counter elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_query_total Total number of queries # TYPE elasticsearch_index_stats_search_query_total counter elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_current Current search scroll count # TYPE elasticsearch_index_stats_search_scroll_current gauge elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_time_seconds_total Total search scroll time in seconds # TYPE elasticsearch_index_stats_search_scroll_time_seconds_total counter elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_scroll_total Total search scroll count # TYPE elasticsearch_index_stats_search_scroll_total counter elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_time_seconds_total Total search suggest time in seconds # TYPE elasticsearch_index_stats_search_suggest_time_seconds_total counter elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_search_suggest_total Total search suggest count # TYPE elasticsearch_index_stats_search_suggest_total counter elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_index_stats_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_index_stats_warmer_time_seconds_total counter elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0.002 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0.015 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index=".watches"} 0.009 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.094 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.004 # HELP elasticsearch_index_stats_warmer_total Total warmer count # TYPE elasticsearch_index_stats_warmer_total counter elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index=".monitoring-data-2"} 3 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 4 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_1"} 7 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_2"} 8 # HELP elasticsearch_indices_aliases Record aliases associated with an index # TYPE elasticsearch_indices_aliases gauge elasticsearch_indices_aliases{alias="foo_alias_2_1",cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_1",cluster="unknown_cluster",index="foo_3"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_2",cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_completion_bytes_primary Current size of completion with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_primary gauge elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_completion_bytes_total Current size of completion with all shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_total gauge elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_primary Count of deleted documents with only primary shards # TYPE elasticsearch_indices_deleted_docs_primary gauge elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_deleted_docs_total Total count of deleted documents # TYPE elasticsearch_indices_deleted_docs_total gauge elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_docs_primary Count of documents with only primary shards # TYPE elasticsearch_indices_docs_primary gauge elasticsearch_indices_docs_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 2 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 65 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_docs_total Total count of documents # TYPE elasticsearch_indices_docs_total gauge elasticsearch_indices_docs_total{cluster="unknown_cluster",index=".monitoring-data-2"} 2 elasticsearch_indices_docs_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 65 elasticsearch_indices_docs_total{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_primary Current number of segments with only primary shards on all nodes # TYPE elasticsearch_indices_segment_count_primary gauge elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 1 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 3 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_count_total Current number of segments with all shards on all nodes # TYPE elasticsearch_indices_segment_count_total gauge elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index=".monitoring-data-2"} 1 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 3 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_2"} 3 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_primary Current size of doc values with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_primary gauge elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 236 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 3452 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 368 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 184 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 276 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_total Current size of doc values with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_total gauge elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 236 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 3452 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 368 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 184 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 276 # HELP elasticsearch_indices_segment_fields_memory_bytes_primary Current size of fields with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_primary gauge elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 312 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 936 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 1248 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 624 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 936 # HELP elasticsearch_indices_segment_fields_memory_bytes_total Current size of fields with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_total gauge elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 312 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 936 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 1248 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 624 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 936 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary Current size of fixed bit with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total Current size of fixed bit with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_primary Current size of index writer with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_primary gauge elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_total Current size of index writer with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_total gauge elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_memory_bytes_primary Current size of segments with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_primary gauge elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 1335 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 23830 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 18418 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 5176 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 7764 # HELP elasticsearch_indices_segment_memory_bytes_total Current size of segments with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_total gauge elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 1335 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 23830 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 18418 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 5176 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 7764 # HELP elasticsearch_indices_segment_norms_memory_bytes_primary Current size of norms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_primary gauge elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 320 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 1600 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 384 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 576 # HELP elasticsearch_indices_segment_norms_memory_bytes_total Current size of norms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_total gauge elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 320 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 1600 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 384 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 576 # HELP elasticsearch_indices_segment_points_memory_bytes_primary Current size of points with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_primary gauge elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 648 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_total Current size of points with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_total gauge elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 648 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 4 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_primary_bytes Current size of term vectors with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_primary_bytes gauge elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_total_bytes Current size of term vectors with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_total_bytes gauge elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_terms_memory_primary Current size of terms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_primary gauge elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 787 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 18474 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index=".watches"} 15198 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_1"} 3984 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_2"} 5976 # HELP elasticsearch_indices_segment_terms_memory_total Current number of terms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_total gauge elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index=".monitoring-data-2"} 787 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 18474 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index=".watches"} 15198 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_1"} 3984 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_2"} 5976 # HELP elasticsearch_indices_segment_version_map_memory_bytes_primary Current size of version map with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_primary gauge elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_total Current size of version map with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_total gauge elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 # HELP elasticsearch_indices_store_size_bytes_primary Current total size of stored index data in bytes with only primary shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_primary gauge elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index=".monitoring-data-2"} 4226 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 68917 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index=".watches"} 35444 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_1"} 8038 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_2"} 11909 # HELP elasticsearch_indices_store_size_bytes_total Current total size of stored index data in bytes with all shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_total gauge elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index=".monitoring-data-2"} 4226 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 68917 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index=".watches"} 35444 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_1"} 8038 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_2"} 11909 # HELP elasticsearch_search_active_queries The number of currently active queries # TYPE elasticsearch_search_active_queries gauge elasticsearch_search_active_queries{cluster="unknown_cluster",index=".monitoring-data-2"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index=".monitoring-es-2-2017.08.23"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index=".watches"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_2"} 0 `, }, { name: "7.17.3", file: "7.17.3.json", want: `# HELP elasticsearch_index_stats_fielddata_evictions_total Total fielddata evictions count # TYPE elasticsearch_index_stats_fielddata_evictions_total counter elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_fielddata_memory_bytes_total Total fielddata memory bytes # TYPE elasticsearch_index_stats_fielddata_memory_bytes_total counter elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_flush_time_seconds_total Total flush time in seconds # TYPE elasticsearch_index_stats_flush_time_seconds_total counter elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.15 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_flush_total Total flush count # TYPE elasticsearch_index_stats_flush_total counter elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index=".geoip_databases"} 4 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_get_time_seconds_total Total get time in seconds # TYPE elasticsearch_index_stats_get_time_seconds_total counter elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_get_total Total get count # TYPE elasticsearch_index_stats_get_total counter elasticsearch_index_stats_get_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_index_current The number of documents currently being indexed to an index # TYPE elasticsearch_index_stats_index_current gauge elasticsearch_index_stats_index_current{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_delete_time_seconds_total Total indexing delete time in seconds # TYPE elasticsearch_index_stats_indexing_delete_time_seconds_total counter elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_delete_total Total indexing delete count # TYPE elasticsearch_index_stats_indexing_delete_total counter elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_index_time_seconds_total Total indexing index time in seconds # TYPE elasticsearch_index_stats_indexing_index_time_seconds_total counter elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.738 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.001 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.001 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0.001 # HELP elasticsearch_index_stats_indexing_index_total Total indexing index count # TYPE elasticsearch_index_stats_indexing_index_total counter elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index=".geoip_databases"} 40 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_1"} 1 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_index_stats_indexing_noop_update_total Total indexing no-op update count # TYPE elasticsearch_index_stats_indexing_noop_update_total counter elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_throttle_time_seconds_total Total indexing throttle time in seconds # TYPE elasticsearch_index_stats_indexing_throttle_time_seconds_total counter elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_auto_throttle_bytes_total Total bytes that were auto-throttled during merging # TYPE elasticsearch_index_stats_merge_auto_throttle_bytes_total counter elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_1"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_2"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_3"} 2.097152e+07 # HELP elasticsearch_index_stats_merge_stopped_time_seconds_total Total large merge stopped time in seconds, allowing smaller merges to complete # TYPE elasticsearch_index_stats_merge_stopped_time_seconds_total counter elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_throttle_time_seconds_total Total merge I/O throttle time in seconds # TYPE elasticsearch_index_stats_merge_throttle_time_seconds_total counter elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_time_seconds_total Total merge time in seconds # TYPE elasticsearch_index_stats_merge_time_seconds_total counter elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_total Total merge count # TYPE elasticsearch_index_stats_merge_total counter elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_caches_total Total query cache caches count # TYPE elasticsearch_index_stats_query_cache_caches_total counter elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_evictions_total Total query cache evictions count # TYPE elasticsearch_index_stats_query_cache_evictions_total counter elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_hits_total Total query cache hits count # TYPE elasticsearch_index_stats_query_cache_hits_total counter elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_memory_bytes_total Total query cache memory bytes # TYPE elasticsearch_index_stats_query_cache_memory_bytes_total counter elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_misses_total Total query cache misses count # TYPE elasticsearch_index_stats_query_cache_misses_total counter elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_size Total query cache size # TYPE elasticsearch_index_stats_query_cache_size gauge elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_refresh_external_time_seconds_total Total external refresh time in seconds # TYPE elasticsearch_index_stats_refresh_external_time_seconds_total counter elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.045 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.008 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.01 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0.01 # HELP elasticsearch_index_stats_refresh_external_total Total external refresh count # TYPE elasticsearch_index_stats_refresh_external_total counter elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index=".geoip_databases"} 6 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_1"} 3 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_3"} 3 # HELP elasticsearch_index_stats_refresh_time_seconds_total Total refresh time in seconds # TYPE elasticsearch_index_stats_refresh_time_seconds_total counter elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.05 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.008 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.009 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0.009 # HELP elasticsearch_index_stats_refresh_total Total refresh count # TYPE elasticsearch_index_stats_refresh_total counter elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index=".geoip_databases"} 9 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_1"} 3 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_3"} 3 # HELP elasticsearch_index_stats_request_cache_evictions_total Total request cache evictions count # TYPE elasticsearch_index_stats_request_cache_evictions_total counter elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_hits_total Total request cache hits count # TYPE elasticsearch_index_stats_request_cache_hits_total counter elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_memory_bytes_total Total request cache memory bytes # TYPE elasticsearch_index_stats_request_cache_memory_bytes_total counter elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_misses_total Total request cache misses count # TYPE elasticsearch_index_stats_request_cache_misses_total counter elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_fetch_time_seconds_total Total search fetch time in seconds # TYPE elasticsearch_index_stats_search_fetch_time_seconds_total counter elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.096 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_fetch_total Total search fetch count # TYPE elasticsearch_index_stats_search_fetch_total counter elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index=".geoip_databases"} 43 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_query_time_seconds_total Total search query time in seconds # TYPE elasticsearch_index_stats_search_query_time_seconds_total counter elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.071 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_query_total Total number of queries # TYPE elasticsearch_index_stats_search_query_total counter elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index=".geoip_databases"} 43 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_current Current search scroll count # TYPE elasticsearch_index_stats_search_scroll_current gauge elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_time_seconds_total Total search scroll time in seconds # TYPE elasticsearch_index_stats_search_scroll_time_seconds_total counter elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.06 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_total Total search scroll count # TYPE elasticsearch_index_stats_search_scroll_total counter elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index=".geoip_databases"} 3 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_suggest_time_seconds_total Total search suggest time in seconds # TYPE elasticsearch_index_stats_search_suggest_time_seconds_total counter elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_suggest_total Total search suggest count # TYPE elasticsearch_index_stats_search_suggest_total counter elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_index_stats_warmer_time_seconds_total counter elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_warmer_total Total warmer count # TYPE elasticsearch_index_stats_warmer_total counter elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index=".geoip_databases"} 5 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_2"} 2 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_3"} 2 # HELP elasticsearch_indices_aliases Record aliases associated with an index # TYPE elasticsearch_indices_aliases gauge elasticsearch_indices_aliases{alias="foo_alias_2_1",cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_1",cluster="unknown_cluster",index="foo_3"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_2",cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_completion_bytes_primary Current size of completion with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_primary gauge elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_completion_bytes_total Current size of completion with all shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_total gauge elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_deleted_docs_primary Count of deleted documents with only primary shards # TYPE elasticsearch_indices_deleted_docs_primary gauge elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_deleted_docs_total Total count of deleted documents # TYPE elasticsearch_indices_deleted_docs_total gauge elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_docs_primary Count of documents with only primary shards # TYPE elasticsearch_indices_docs_primary gauge elasticsearch_indices_docs_primary{cluster="unknown_cluster",index=".geoip_databases"} 40 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_1"} 1 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_docs_total Total count of documents # TYPE elasticsearch_indices_docs_total gauge elasticsearch_indices_docs_total{cluster="unknown_cluster",index=".geoip_databases"} 40 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_1"} 1 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_segment_count_primary Current number of segments with only primary shards on all nodes # TYPE elasticsearch_indices_segment_count_primary gauge elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index=".geoip_databases"} 4 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_1"} 1 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_segment_count_total Current number of segments with all shards on all nodes # TYPE elasticsearch_indices_segment_count_total gauge elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index=".geoip_databases"} 4 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_1"} 1 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_primary Current size of doc values with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_primary gauge elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 304 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 76 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 76 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 76 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_total Current size of doc values with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_total gauge elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 304 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 76 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 76 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 76 # HELP elasticsearch_indices_segment_fields_memory_bytes_primary Current size of fields with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_primary gauge elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 2016 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 488 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 488 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 488 # HELP elasticsearch_indices_segment_fields_memory_bytes_total Current size of fields with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_total gauge elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 2016 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 488 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 488 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 488 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary Current size of fixed bit with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total Current size of fixed bit with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_primary Current size of index writer with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_primary gauge elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_total Current size of index writer with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_total gauge elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_memory_bytes_primary Current size of segments with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_primary gauge elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 4368 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 1876 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 1876 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 1876 # HELP elasticsearch_indices_segment_memory_bytes_total Current size of segments with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_total gauge elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 4368 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 1876 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 1876 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 1876 # HELP elasticsearch_indices_segment_norms_memory_bytes_primary Current size of norms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_primary gauge elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 128 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 128 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 128 # HELP elasticsearch_indices_segment_norms_memory_bytes_total Current size of norms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_total gauge elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 128 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 128 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 128 # HELP elasticsearch_indices_segment_points_memory_bytes_primary Current size of points with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_primary gauge elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_total Current size of points with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_total gauge elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_primary_bytes Current size of term vectors with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_primary_bytes gauge elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_total_bytes Current size of term vectors with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_total_bytes gauge elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_terms_memory_primary Current size of terms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_primary gauge elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index=".geoip_databases"} 2048 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_1"} 1184 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_2"} 1184 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_3"} 1184 # HELP elasticsearch_indices_segment_terms_memory_total Current number of terms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_total gauge elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index=".geoip_databases"} 2048 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_1"} 1184 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_2"} 1184 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_3"} 1184 # HELP elasticsearch_indices_segment_version_map_memory_bytes_primary Current size of version map with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_primary gauge elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_total Current size of version map with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_total gauge elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_store_size_bytes_primary Current total size of stored index data in bytes with only primary shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_primary gauge elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 3.9904033e+07 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_1"} 4413 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_2"} 4459 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_3"} 4459 # HELP elasticsearch_indices_store_size_bytes_total Current total size of stored index data in bytes with all shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_total gauge elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 3.9904033e+07 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_1"} 4413 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_2"} 4459 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_3"} 4459 # HELP elasticsearch_search_active_queries The number of currently active queries # TYPE elasticsearch_search_active_queries gauge elasticsearch_search_active_queries{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_3"} 0 `, }, { name: "7.17.3", file: "7.17.3.json", shards: true, want: `# HELP elasticsearch_index_stats_fielddata_evictions_total Total fielddata evictions count # TYPE elasticsearch_index_stats_fielddata_evictions_total counter elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_fielddata_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_fielddata_memory_bytes_total Total fielddata memory bytes # TYPE elasticsearch_index_stats_fielddata_memory_bytes_total counter elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_fielddata_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_flush_time_seconds_total Total flush time in seconds # TYPE elasticsearch_index_stats_flush_time_seconds_total counter elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.31 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_flush_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_flush_total Total flush count # TYPE elasticsearch_index_stats_flush_total counter elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index=".geoip_databases"} 4 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_flush_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_get_time_seconds_total Total get time in seconds # TYPE elasticsearch_index_stats_get_time_seconds_total counter elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_get_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_get_total Total get count # TYPE elasticsearch_index_stats_get_total counter elasticsearch_index_stats_get_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_get_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_index_current The number of documents currently being indexed to an index # TYPE elasticsearch_index_stats_index_current gauge elasticsearch_index_stats_index_current{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_index_current{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_delete_time_seconds_total Total indexing delete time in seconds # TYPE elasticsearch_index_stats_indexing_delete_time_seconds_total counter elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_delete_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_delete_total Total indexing delete count # TYPE elasticsearch_index_stats_indexing_delete_total counter elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_delete_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_index_time_seconds_total Total indexing index time in seconds # TYPE elasticsearch_index_stats_indexing_index_time_seconds_total counter elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.866 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.002 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.003 elasticsearch_index_stats_indexing_index_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_index_total Total indexing index count # TYPE elasticsearch_index_stats_indexing_index_total counter elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index=".geoip_databases"} 37 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_index_stats_indexing_index_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_noop_update_total Total indexing no-op update count # TYPE elasticsearch_index_stats_indexing_noop_update_total counter elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_noop_update_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_indexing_throttle_time_seconds_total Total indexing throttle time in seconds # TYPE elasticsearch_index_stats_indexing_throttle_time_seconds_total counter elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_indexing_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_auto_throttle_bytes_total Total bytes that were auto-throttled during merging # TYPE elasticsearch_index_stats_merge_auto_throttle_bytes_total counter elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_1"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_2"} 2.097152e+07 elasticsearch_index_stats_merge_auto_throttle_bytes_total{cluster="unknown_cluster",index="foo_3"} 2.097152e+07 # HELP elasticsearch_index_stats_merge_stopped_time_seconds_total Total large merge stopped time in seconds, allowing smaller merges to complete # TYPE elasticsearch_index_stats_merge_stopped_time_seconds_total counter elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_stopped_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_throttle_time_seconds_total Total merge I/O throttle time in seconds # TYPE elasticsearch_index_stats_merge_throttle_time_seconds_total counter elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_throttle_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_time_seconds_total Total merge time in seconds # TYPE elasticsearch_index_stats_merge_time_seconds_total counter elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_merge_total Total merge count # TYPE elasticsearch_index_stats_merge_total counter elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_merge_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_caches_total Total query cache caches count # TYPE elasticsearch_index_stats_query_cache_caches_total counter elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_caches_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_evictions_total Total query cache evictions count # TYPE elasticsearch_index_stats_query_cache_evictions_total counter elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_hits_total Total query cache hits count # TYPE elasticsearch_index_stats_query_cache_hits_total counter elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_hits_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_memory_bytes_total Total query cache memory bytes # TYPE elasticsearch_index_stats_query_cache_memory_bytes_total counter elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_misses_total Total query cache misses count # TYPE elasticsearch_index_stats_query_cache_misses_total counter elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_misses_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_query_cache_size Total query cache size # TYPE elasticsearch_index_stats_query_cache_size gauge elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_query_cache_size{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_refresh_external_time_seconds_total Total external refresh time in seconds # TYPE elasticsearch_index_stats_refresh_external_time_seconds_total counter elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.074 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.014 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.02 elasticsearch_index_stats_refresh_external_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_refresh_external_total Total external refresh count # TYPE elasticsearch_index_stats_refresh_external_total counter elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index=".geoip_databases"} 7 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_1"} 4 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_2"} 5 elasticsearch_index_stats_refresh_external_total{cluster="unknown_cluster",index="foo_3"} 2 # HELP elasticsearch_index_stats_refresh_time_seconds_total Total refresh time in seconds # TYPE elasticsearch_index_stats_refresh_time_seconds_total counter elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.083 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0.014 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0.02 elasticsearch_index_stats_refresh_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_refresh_total Total refresh count # TYPE elasticsearch_index_stats_refresh_total counter elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index=".geoip_databases"} 10 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_1"} 4 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_2"} 5 elasticsearch_index_stats_refresh_total{cluster="unknown_cluster",index="foo_3"} 2 # HELP elasticsearch_index_stats_request_cache_evictions_total Total request cache evictions count # TYPE elasticsearch_index_stats_request_cache_evictions_total counter elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_evictions_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_hits_total Total request cache hits count # TYPE elasticsearch_index_stats_request_cache_hits_total counter elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_hits_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_memory_bytes_total Total request cache memory bytes # TYPE elasticsearch_index_stats_request_cache_memory_bytes_total counter elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_request_cache_misses_total Total request cache misses count # TYPE elasticsearch_index_stats_request_cache_misses_total counter elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_request_cache_misses_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_fetch_time_seconds_total Total search fetch time in seconds # TYPE elasticsearch_index_stats_search_fetch_time_seconds_total counter elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.069 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_fetch_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_fetch_total Total search fetch count # TYPE elasticsearch_index_stats_search_fetch_total counter elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index=".geoip_databases"} 40 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_fetch_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_query_time_seconds_total Total search query time in seconds # TYPE elasticsearch_index_stats_search_query_time_seconds_total counter elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.057 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_query_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_query_total Total number of queries # TYPE elasticsearch_index_stats_search_query_total counter elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index=".geoip_databases"} 40 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_query_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_current Current search scroll count # TYPE elasticsearch_index_stats_search_scroll_current gauge elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_current{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_time_seconds_total Total search scroll time in seconds # TYPE elasticsearch_index_stats_search_scroll_time_seconds_total counter elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0.048 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_scroll_total Total search scroll count # TYPE elasticsearch_index_stats_search_scroll_total counter elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index=".geoip_databases"} 3 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_scroll_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_suggest_time_seconds_total Total search suggest time in seconds # TYPE elasticsearch_index_stats_search_suggest_time_seconds_total counter elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_suggest_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_search_suggest_total Total search suggest count # TYPE elasticsearch_index_stats_search_suggest_total counter elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_search_suggest_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_index_stats_warmer_time_seconds_total counter elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_index_stats_warmer_time_seconds_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_index_stats_warmer_total Total warmer count # TYPE elasticsearch_index_stats_warmer_total counter elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index=".geoip_databases"} 6 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_1"} 3 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_2"} 4 elasticsearch_index_stats_warmer_total{cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_aliases Record aliases associated with an index # TYPE elasticsearch_indices_aliases gauge elasticsearch_indices_aliases{alias="foo_alias_2_1",cluster="unknown_cluster",index="foo_2"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_1",cluster="unknown_cluster",index="foo_3"} 1 elasticsearch_indices_aliases{alias="foo_alias_3_2",cluster="unknown_cluster",index="foo_3"} 1 # HELP elasticsearch_indices_completion_bytes_primary Current size of completion with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_primary gauge elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_completion_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_completion_bytes_total Current size of completion with all shards on all nodes in bytes # TYPE elasticsearch_indices_completion_bytes_total gauge elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_completion_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_deleted_docs_primary Count of deleted documents with only primary shards # TYPE elasticsearch_indices_deleted_docs_primary gauge elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_deleted_docs_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_deleted_docs_total Total count of deleted documents # TYPE elasticsearch_indices_deleted_docs_total gauge elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_deleted_docs_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_docs_primary Count of documents with only primary shards # TYPE elasticsearch_indices_docs_primary gauge elasticsearch_indices_docs_primary{cluster="unknown_cluster",index=".geoip_databases"} 37 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_indices_docs_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_docs_total Total count of documents # TYPE elasticsearch_indices_docs_total gauge elasticsearch_indices_docs_total{cluster="unknown_cluster",index=".geoip_databases"} 37 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_indices_docs_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_count_primary Current number of segments with only primary shards on all nodes # TYPE elasticsearch_indices_segment_count_primary gauge elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index=".geoip_databases"} 5 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_indices_segment_count_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_count_total Current number of segments with all shards on all nodes # TYPE elasticsearch_indices_segment_count_total gauge elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index=".geoip_databases"} 5 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_1"} 2 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_2"} 3 elasticsearch_indices_segment_count_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_primary Current size of doc values with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_primary gauge elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 380 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 152 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 228 elasticsearch_indices_segment_doc_values_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_doc_values_memory_bytes_total Current size of doc values with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_doc_values_memory_bytes_total gauge elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 380 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 152 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 228 elasticsearch_indices_segment_doc_values_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_fields_memory_bytes_primary Current size of fields with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_primary gauge elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 2504 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 976 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 1464 elasticsearch_indices_segment_fields_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_fields_memory_bytes_total Current size of fields with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fields_memory_bytes_total gauge elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 2504 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 976 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 1464 elasticsearch_indices_segment_fields_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary Current size of fixed bit with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total Current size of fixed bit with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total gauge elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_fixed_bit_set_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_primary Current size of index writer with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_primary gauge elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_index_writer_memory_bytes_total Current size of index writer with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_index_writer_memory_bytes_total gauge elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_index_writer_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_memory_bytes_primary Current size of segments with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_primary gauge elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 5444 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 3752 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 5628 elasticsearch_indices_segment_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_memory_bytes_total Current size of segments with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_memory_bytes_total gauge elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 5444 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 3752 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 5628 elasticsearch_indices_segment_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_norms_memory_bytes_primary Current size of norms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_primary gauge elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 256 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 384 elasticsearch_indices_segment_norms_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_norms_memory_bytes_total Current size of norms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_norms_memory_bytes_total gauge elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 256 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 384 elasticsearch_indices_segment_norms_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_primary Current size of points with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_primary gauge elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_points_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_points_memory_bytes_total Current size of points with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_points_memory_bytes_total gauge elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_points_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_primary_bytes Current size of term vectors with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_primary_bytes gauge elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_term_vectors_memory_primary_bytes{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_term_vectors_memory_total_bytes Current size of term vectors with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_term_vectors_memory_total_bytes gauge elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_term_vectors_memory_total_bytes{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_terms_memory_primary Current size of terms with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_primary gauge elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index=".geoip_databases"} 2560 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_1"} 2368 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_2"} 3552 elasticsearch_indices_segment_terms_memory_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_terms_memory_total Current number of terms with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_terms_memory_total gauge elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index=".geoip_databases"} 2560 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_1"} 2368 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_2"} 3552 elasticsearch_indices_segment_terms_memory_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_primary Current size of version map with only primary shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_primary gauge elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_primary{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_segment_version_map_memory_bytes_total Current size of version map with all shards on all nodes in bytes # TYPE elasticsearch_indices_segment_version_map_memory_bytes_total gauge elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_indices_segment_version_map_memory_bytes_total{cluster="unknown_cluster",index="foo_3"} 0 # HELP elasticsearch_indices_shards_docs Count of documents on this shard # TYPE elasticsearch_indices_shards_docs gauge elasticsearch_indices_shards_docs{cluster="unknown_cluster",index=".geoip_databases",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 37 elasticsearch_indices_shards_docs{cluster="unknown_cluster",index="foo_1",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 2 elasticsearch_indices_shards_docs{cluster="unknown_cluster",index="foo_2",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 3 elasticsearch_indices_shards_docs{cluster="unknown_cluster",index="foo_3",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 0 # HELP elasticsearch_indices_shards_docs_deleted Count of deleted documents on this shard # TYPE elasticsearch_indices_shards_docs_deleted gauge elasticsearch_indices_shards_docs_deleted{cluster="unknown_cluster",index=".geoip_databases",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 0 elasticsearch_indices_shards_docs_deleted{cluster="unknown_cluster",index="foo_1",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 0 elasticsearch_indices_shards_docs_deleted{cluster="unknown_cluster",index="foo_2",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 0 elasticsearch_indices_shards_docs_deleted{cluster="unknown_cluster",index="foo_3",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 0 # HELP elasticsearch_indices_shards_store_size_in_bytes Store size of this shard # TYPE elasticsearch_indices_shards_store_size_in_bytes gauge elasticsearch_indices_shards_store_size_in_bytes{cluster="unknown_cluster",index=".geoip_databases",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 3.7286036e+07 elasticsearch_indices_shards_store_size_in_bytes{cluster="unknown_cluster",index="foo_1",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 8600 elasticsearch_indices_shards_store_size_in_bytes{cluster="unknown_cluster",index="foo_2",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 12925 elasticsearch_indices_shards_store_size_in_bytes{cluster="unknown_cluster",index="foo_3",node="49nZYKtiQdGg7Nl_sVsI1A",primary="true",shard="0"} 226 # HELP elasticsearch_indices_store_size_bytes_primary Current total size of stored index data in bytes with only primary shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_primary gauge elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index=".geoip_databases"} 3.7286036e+07 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_1"} 8600 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_2"} 12925 elasticsearch_indices_store_size_bytes_primary{cluster="unknown_cluster",index="foo_3"} 226 # HELP elasticsearch_indices_store_size_bytes_total Current total size of stored index data in bytes with all shards on all nodes # TYPE elasticsearch_indices_store_size_bytes_total gauge elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index=".geoip_databases"} 3.7286036e+07 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_1"} 8600 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_2"} 12925 elasticsearch_indices_store_size_bytes_total{cluster="unknown_cluster",index="foo_3"} 226 # HELP elasticsearch_search_active_queries The number of currently active queries # TYPE elasticsearch_search_active_queries gauge elasticsearch_search_active_queries{cluster="unknown_cluster",index=".geoip_databases"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_1"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_2"} 0 elasticsearch_search_active_queries{cluster="unknown_cluster",index="foo_3"} 0 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { fStats, err := os.Open(path.Join("../fixtures/indices/", tt.file)) if err != nil { t.Fatal(err) } defer fStats.Close() fStatsShard, err := os.Open(path.Join("../fixtures/indices/shards/", tt.file)) if err != nil { t.Fatal(err) } defer fStatsShard.Close() fAlias, err := os.Open(path.Join("../fixtures/indices/alias/", tt.file)) if err != nil { t.Fatal(err) } defer fAlias.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { case "/_all/_stats": shards := r.URL.Query().Get("level") if shards == "shards" { io.Copy(w, fStatsShard) } else { io.Copy(w, fStats) } case "/_alias": io.Copy(w, fAlias) default: http.Error(w, "Not Found", http.StatusNotFound) } })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c := NewIndices(promslog.NewNopLogger(), http.DefaultClient, u, false, true) if err != nil { t.Fatal(err) } c.shards = tt.shards if err := testutil.CollectAndCompare(c, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/nodes.go000066400000000000000000001742401511562765300241120ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "path" "github.com/prometheus/client_golang/prometheus" ) func getRoles(node NodeStatsNodeResponse) map[string]bool { // default settings (2.x) and map, which roles to consider roles := map[string]bool{ "master": false, "data": false, "data_hot": false, "data_warm": false, "data_cold": false, "data_frozen": false, "data_content": false, "ml": false, "remote_cluster_client": false, "transform": false, "ingest": false, "client": true, } // assumption: a 5.x node has at least one role, otherwise it's a 1.7 or 2.x node if len(node.Roles) > 0 { for _, role := range node.Roles { // set every absent role to false if _, ok := roles[role]; !ok { roles[role] = false } else { // if present in the roles field, set to true roles[role] = true } } } else { for role, setting := range node.Attributes { if _, ok := roles[role]; ok { if setting == "false" { roles[role] = false } else { roles[role] = true } } } } if len(node.HTTP) == 0 { roles["client"] = false } return roles } var nodesRolesMetric = prometheus.NewDesc( prometheus.BuildFQName(namespace, "nodes", "roles"), "Node roles", append(defaultRoleLabels, "role"), nil, ) var ( defaultNodeLabels = []string{"cluster", "host", "name", "es_master_node", "es_data_node", "es_ingest_node", "es_client_node"} defaultRoleLabels = []string{"cluster", "host", "name"} defaultThreadPoolLabels = append(defaultNodeLabels, "type") defaultBreakerLabels = append(defaultNodeLabels, "breaker") defaultIndexingPressureLabels = []string{"cluster", "host", "name", "indexing_pressure"} defaultFilesystemDataLabels = append(defaultNodeLabels, "mount", "path") defaultFilesystemIODeviceLabels = append(defaultNodeLabels, "device") defaultCacheLabels = append(defaultNodeLabels, "cache") defaultNodeLabelValues = func(cluster string, node NodeStatsNodeResponse) []string { roles := getRoles(node) return []string{ cluster, node.Host, node.Name, fmt.Sprintf("%t", roles["master"]), fmt.Sprintf("%t", roles["data"]), fmt.Sprintf("%t", roles["ingest"]), fmt.Sprintf("%t", roles["client"]), } } defaultThreadPoolLabelValues = func(cluster string, node NodeStatsNodeResponse, pool string) []string { return append(defaultNodeLabelValues(cluster, node), pool) } defaultFilesystemDataLabelValues = func(cluster string, node NodeStatsNodeResponse, mount string, path string) []string { return append(defaultNodeLabelValues(cluster, node), mount, path) } defaultFilesystemIODeviceLabelValues = func(cluster string, node NodeStatsNodeResponse, device string) []string { return append(defaultNodeLabelValues(cluster, node), device) } defaultCacheHitLabelValues = func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "hit") } defaultCacheMissLabelValues = func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "miss") } ) type nodeMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(node NodeStatsNodeResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse) []string } type gcCollectionMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(gcStats NodeStatsJVMGCCollectorResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, collector string) []string } type breakerMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(breakerStats NodeStatsBreakersResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, breaker string) []string } type indexingPressureMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(indexingPressureStats NodeStatsIndexingPressureResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, indexingPressure string) []string } type threadPoolMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, breaker string) []string } type filesystemDataMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(fsStats NodeStatsFSDataResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, mount string, path string) []string } type filesystemIODeviceMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(fsStats NodeStatsFSIOStatsDeviceResponse) float64 Labels func(cluster string, node NodeStatsNodeResponse, device string) []string } // Nodes information struct type Nodes struct { logger *slog.Logger client *http.Client url *url.URL all bool node string nodeMetrics []*nodeMetric gcCollectionMetrics []*gcCollectionMetric breakerMetrics []*breakerMetric indexingPressureMetrics []*indexingPressureMetric threadPoolMetrics []*threadPoolMetric filesystemDataMetrics []*filesystemDataMetric filesystemIODeviceMetrics []*filesystemIODeviceMetric } // NewNodes defines Nodes Prometheus metrics func NewNodes(logger *slog.Logger, client *http.Client, url *url.URL, all bool, node string) *Nodes { return &Nodes{ logger: logger, client: client, url: url, all: all, node: node, nodeMetrics: []*nodeMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "load1"), "Shortterm load average", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return node.OS.CPU.LoadAvg.Load1 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "load5"), "Midterm load average", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return node.OS.CPU.LoadAvg.Load5 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "load15"), "Longterm load average", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return node.OS.CPU.LoadAvg.Load15 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "cpu_percent"), "Percent CPU used by OS", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.OS.CPU.Percent) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "mem_free_bytes"), "Amount of free physical memory in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.OS.Mem.Free) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "mem_used_bytes"), "Amount of used physical memory in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.OS.Mem.Used) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "mem_actual_free_bytes"), "Amount of free physical memory in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.OS.Mem.ActualFree) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "os", "mem_actual_used_bytes"), "Amount of used physical memory in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.OS.Mem.ActualUsed) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "fielddata_memory_size_bytes"), "Field data cache memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.FieldData.MemorySize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "fielddata_evictions"), "Evictions from field data", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.FieldData.Evictions) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "completion_size_in_bytes"), "Completion in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Completion.Size) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "filter_cache_memory_size_bytes"), "Filter cache memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.FilterCache.MemorySize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "filter_cache_evictions"), "Evictions from filter cache", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.FilterCache.Evictions) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_memory_size_bytes"), "Query cache memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.MemorySize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_evictions"), "Evictions from query cache", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.Evictions) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_total"), "Query cache total count", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.TotalCount) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_cache_size"), "Query cache cache size", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.CacheSize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_cache_total"), "Query cache cache count", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.CacheCount) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_cache_count"), "Query cache count", defaultCacheLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.HitCount) }, Labels: defaultCacheHitLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "query_miss_count"), "Query miss count", defaultCacheLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.QueryCache.MissCount) }, Labels: defaultCacheMissLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "request_cache_memory_size_bytes"), "Request cache memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.RequestCache.MemorySize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "request_cache_evictions"), "Evictions from request cache", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.RequestCache.Evictions) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "request_cache_count"), "Request cache count", defaultCacheLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.RequestCache.HitCount) }, Labels: defaultCacheHitLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "request_miss_count"), "Request miss count", defaultCacheLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.RequestCache.MissCount) }, Labels: defaultCacheMissLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "translog_operations"), "Total translog operations", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Translog.Operations) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "translog_size_in_bytes"), "Total translog size in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Translog.Size) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_time_seconds"), "Total get time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.Time) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_total"), "Total get", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.Total) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_missing_time_seconds"), "Total time of get missing in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.MissingTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_missing_total"), "Total get missing", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.MissingTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_exists_time_seconds"), "Total time get exists in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.ExistsTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "get_exists_total"), "Total get exists operations", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Get.ExistsTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_refresh", "time_seconds_total"), "Total time spent refreshing in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Refresh.TotalTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_refresh", "total"), "Total refreshes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Refresh.Total) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_refresh", "external_total"), "Total external refreshes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Refresh.ExternalTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_refresh", "external_time_seconds_total"), "Total time spent external refreshing in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Refresh.ExternalTotalTimeInMillis) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_query_time_seconds"), "Total search query time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.QueryTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_query_total"), "Total number of queries", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.QueryTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_fetch_time_seconds"), "Total search fetch time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.FetchTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_fetch_total"), "Total number of fetches", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.FetchTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_suggest_total"), "Total number of suggests", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.SuggestTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_suggest_time_seconds"), "Total suggest time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.SuggestTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_scroll_total"), "Total number of scrolls", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.ScrollTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "search_scroll_time_seconds"), "Total scroll time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Search.ScrollTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "docs"), "Count of documents on this node", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Docs.Count) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "docs_deleted"), "Count of deleted documents on this node", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Docs.Deleted) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "store_size_bytes"), "Current size of stored index data in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Store.Size) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "store_throttle_time_seconds_total"), "Throttle time for index store in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Store.ThrottleTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_memory_bytes"), "Current memory size of segments in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.Memory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_count"), "Count of index segments on this node", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.Count) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_terms_memory_in_bytes"), "Count of terms in memory for this node", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.TermsMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_index_writer_memory_in_bytes"), "Count of memory for index writer on this node", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.IndexWriterMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_norms_memory_in_bytes"), "Count of memory used by norms", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.NormsMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_stored_fields_memory_in_bytes"), "Count of stored fields memory", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.StoredFieldsMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_doc_values_memory_in_bytes"), "Count of doc values memory", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.DocValuesMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_fixed_bit_set_memory_in_bytes"), "Count of fixed bit set", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.FixedBitSet) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_term_vectors_memory_in_bytes"), "Term vectors memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.TermVectorsMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_points_memory_in_bytes"), "Point values memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.PointsMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "segments_version_map_memory_in_bytes"), "Version map memory usage in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Segments.VersionMapMemory) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "flush_total"), "Total flushes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Flush.Total) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "flush_time_seconds"), "Cumulative flush time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Flush.Time) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "warmer_total"), "Total warmer count", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Warmer.Total) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices", "warmer_time_seconds_total"), "Total warmer time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Warmer.TotalTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "index_time_seconds_total"), "Cumulative index time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Indexing.IndexTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "index_total"), "Total index calls", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Indexing.IndexTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "delete_time_seconds_total"), "Total time indexing delete in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Indexing.DeleteTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "delete_total"), "Total indexing deletes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Indexing.DeleteTotal) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "is_throttled"), "Indexing throttling", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { if node.Indices.Indexing.IsThrottled { return 1 } return 0 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_indexing", "throttle_time_seconds_total"), "Cumulative indexing throttling time", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Indexing.ThrottleTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "total"), "Total merges", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.Total) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "current"), "Current merges", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.Current) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "current_size_in_bytes"), "Size of a current merges in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.CurrentSize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "docs_total"), "Cumulative docs merged", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.TotalDocs) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "total_size_bytes_total"), "Total merge size in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.TotalSize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "total_time_seconds_total"), "Total time spent merging in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.TotalTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indices_merges", "total_throttled_time_seconds_total"), "Total throttled time of merges in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Indices.Merges.TotalThrottledTime) / 1000 }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory", "used_bytes"), "JVM memory currently used by area", append(defaultNodeLabels, "area"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.HeapUsed) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "heap") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory", "used_bytes"), "JVM memory currently used by area", append(defaultNodeLabels, "area"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.NonHeapUsed) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "non-heap") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory", "max_bytes"), "JVM memory max", append(defaultNodeLabels, "area"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.HeapMax) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "heap") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory", "committed_bytes"), "JVM memory currently committed by area", append(defaultNodeLabels, "area"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.HeapCommitted) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "heap") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory", "committed_bytes"), "JVM memory currently committed by area", append(defaultNodeLabels, "area"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.NonHeapCommitted) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "non-heap") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "used_bytes"), "JVM memory currently used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["young"].Used) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "young") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "max_bytes"), "JVM memory max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["young"].Max) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "young") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_used_bytes"), "JVM memory peak used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["young"].PeakUsed) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "young") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_max_bytes"), "JVM memory peak max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["young"].PeakMax) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "young") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "used_bytes"), "JVM memory currently used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["survivor"].Used) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "survivor") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "max_bytes"), "JVM memory max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["survivor"].Max) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "survivor") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_used_bytes"), "JVM memory peak used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["survivor"].PeakUsed) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "survivor") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_max_bytes"), "JVM memory peak max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["survivor"].PeakMax) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "survivor") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "used_bytes"), "JVM memory currently used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["old"].Used) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "old") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "max_bytes"), "JVM memory max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["old"].Max) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "old") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_used_bytes"), "JVM memory peak used by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["old"].PeakUsed) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "old") }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_memory_pool", "peak_max_bytes"), "JVM memory peak max by pool", append(defaultNodeLabels, "pool"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Mem.Pools["old"].PeakMax) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "old") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_buffer_pool", "used_bytes"), "JVM buffer currently used", append(defaultNodeLabels, "type"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.BufferPools["direct"].Used) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "direct") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_buffer_pool", "used_bytes"), "JVM buffer currently used", append(defaultNodeLabels, "type"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.BufferPools["mapped"].Used) }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "mapped") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm", "uptime_seconds"), "JVM process uptime in seconds", append(defaultNodeLabels, "type"), nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.JVM.Uptime) / 1000 }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return append(defaultNodeLabelValues(cluster, node), "mapped") }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "cpu_percent"), "Percent CPU used by process", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.CPU.Percent) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "mem_resident_size_bytes"), "Resident memory in use by process in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.Memory.Resident) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "mem_share_size_bytes"), "Shared memory in use by process in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.Memory.Share) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "mem_virtual_size_bytes"), "Total virtual memory used in bytes", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.Memory.TotalVirtual) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "open_files_count"), "Open file descriptors", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.OpenFD) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "max_files_descriptors"), "Max file descriptors", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.MaxFD) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "process", "cpu_seconds_total"), "Process CPU time in seconds", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Process.CPU.Total) / 1000 }, Labels: func(cluster string, node NodeStatsNodeResponse) []string { return defaultNodeLabelValues(cluster, node) }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "transport", "rx_packets_total"), "Count of packets received", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Transport.RxCount) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "transport", "rx_size_bytes_total"), "Total number of bytes received", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Transport.RxSize) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "transport", "tx_packets_total"), "Count of packets sent", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Transport.TxCount) }, Labels: defaultNodeLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "transport", "tx_size_bytes_total"), "Total number of bytes sent", defaultNodeLabels, nil, ), Value: func(node NodeStatsNodeResponse) float64 { return float64(node.Transport.TxSize) }, Labels: defaultNodeLabelValues, }, }, gcCollectionMetrics: []*gcCollectionMetric{ { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_gc", "collection_seconds_count"), "Count of JVM GC runs", append(defaultNodeLabels, "gc"), nil, ), Value: func(gcStats NodeStatsJVMGCCollectorResponse) float64 { return float64(gcStats.CollectionCount) }, Labels: func(cluster string, node NodeStatsNodeResponse, collector string) []string { return append(defaultNodeLabelValues(cluster, node), collector) }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "jvm_gc", "collection_seconds_sum"), "GC run time in seconds", append(defaultNodeLabels, "gc"), nil, ), Value: func(gcStats NodeStatsJVMGCCollectorResponse) float64 { return float64(gcStats.CollectionTime) / 1000 }, Labels: func(cluster string, node NodeStatsNodeResponse, collector string) []string { return append(defaultNodeLabelValues(cluster, node), collector) }, }, }, breakerMetrics: []*breakerMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "breakers", "estimated_size_bytes"), "Estimated size in bytes of breaker", defaultBreakerLabels, nil, ), Value: func(breakerStats NodeStatsBreakersResponse) float64 { return float64(breakerStats.EstimatedSize) }, Labels: func(cluster string, node NodeStatsNodeResponse, breaker string) []string { return append(defaultNodeLabelValues(cluster, node), breaker) }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "breakers", "limit_size_bytes"), "Limit size in bytes for breaker", defaultBreakerLabels, nil, ), Value: func(breakerStats NodeStatsBreakersResponse) float64 { return float64(breakerStats.LimitSize) }, Labels: func(cluster string, node NodeStatsNodeResponse, breaker string) []string { return append(defaultNodeLabelValues(cluster, node), breaker) }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "breakers", "tripped"), "tripped for breaker", defaultBreakerLabels, nil, ), Value: func(breakerStats NodeStatsBreakersResponse) float64 { return float64(breakerStats.Tripped) }, Labels: func(cluster string, node NodeStatsNodeResponse, breaker string) []string { return append(defaultNodeLabelValues(cluster, node), breaker) }, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "breakers", "overhead"), "Overhead of circuit breakers", defaultBreakerLabels, nil, ), Value: func(breakerStats NodeStatsBreakersResponse) float64 { return breakerStats.Overhead }, Labels: func(cluster string, node NodeStatsNodeResponse, breaker string) []string { return append(defaultNodeLabelValues(cluster, node), breaker) }, }, }, indexingPressureMetrics: []*indexingPressureMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indexing_pressure", "current_all_in_bytes"), "Memory consumed, in bytes, by indexing requests in the coordinating, primary, or replica stage.", defaultIndexingPressureLabels, nil, ), Value: func(indexingPressureMem NodeStatsIndexingPressureResponse) float64 { return float64(indexingPressureMem.Current.AllInBytes) }, Labels: func(cluster string, node NodeStatsNodeResponse, indexingPressure string) []string { return []string{ cluster, node.Host, node.Name, indexingPressure, } }, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "indexing_pressure", "limit_in_bytes"), "Configured memory limit, in bytes, for the indexing requests", defaultIndexingPressureLabels, nil, ), Value: func(indexingPressureStats NodeStatsIndexingPressureResponse) float64 { return float64(indexingPressureStats.LimitInBytes) }, Labels: func(cluster string, node NodeStatsNodeResponse, indexingPressure string) []string { return []string{ cluster, node.Host, node.Name, indexingPressure, } }, }, }, threadPoolMetrics: []*threadPoolMetric{ { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "completed_count"), "Thread Pool operations completed", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Completed) }, Labels: defaultThreadPoolLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "rejected_count"), "Thread Pool operations rejected", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Rejected) }, Labels: defaultThreadPoolLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "active_count"), "Thread Pool threads active", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Active) }, Labels: defaultThreadPoolLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "largest_count"), "Thread Pool largest threads count", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Largest) }, Labels: defaultThreadPoolLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "queue_count"), "Thread Pool operations queued", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Queue) }, Labels: defaultThreadPoolLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "thread_pool", "threads_count"), "Thread Pool current threads count", defaultThreadPoolLabels, nil, ), Value: func(threadPoolStats NodeStatsThreadPoolPoolResponse) float64 { return float64(threadPoolStats.Threads) }, Labels: defaultThreadPoolLabelValues, }, }, filesystemDataMetrics: []*filesystemDataMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_data", "available_bytes"), "Available space on block device in bytes", defaultFilesystemDataLabels, nil, ), Value: func(fsStats NodeStatsFSDataResponse) float64 { return float64(fsStats.Available) }, Labels: defaultFilesystemDataLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_data", "free_bytes"), "Free space on block device in bytes", defaultFilesystemDataLabels, nil, ), Value: func(fsStats NodeStatsFSDataResponse) float64 { return float64(fsStats.Free) }, Labels: defaultFilesystemDataLabelValues, }, { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_data", "size_bytes"), "Size of block device in bytes", defaultFilesystemDataLabels, nil, ), Value: func(fsStats NodeStatsFSDataResponse) float64 { return float64(fsStats.Total) }, Labels: defaultFilesystemDataLabelValues, }, }, filesystemIODeviceMetrics: []*filesystemIODeviceMetric{ { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_io_stats_device", "operations_count"), "Count of disk operations", defaultFilesystemIODeviceLabels, nil, ), Value: func(fsIODeviceStats NodeStatsFSIOStatsDeviceResponse) float64 { return float64(fsIODeviceStats.Operations) }, Labels: defaultFilesystemIODeviceLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_io_stats_device", "read_operations_count"), "Count of disk read operations", defaultFilesystemIODeviceLabels, nil, ), Value: func(fsIODeviceStats NodeStatsFSIOStatsDeviceResponse) float64 { return float64(fsIODeviceStats.ReadOperations) }, Labels: defaultFilesystemIODeviceLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_io_stats_device", "write_operations_count"), "Count of disk write operations", defaultFilesystemIODeviceLabels, nil, ), Value: func(fsIODeviceStats NodeStatsFSIOStatsDeviceResponse) float64 { return float64(fsIODeviceStats.WriteOperations) }, Labels: defaultFilesystemIODeviceLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_io_stats_device", "read_size_kilobytes_sum"), "Total kilobytes read from disk", defaultFilesystemIODeviceLabels, nil, ), Value: func(fsIODeviceStats NodeStatsFSIOStatsDeviceResponse) float64 { return float64(fsIODeviceStats.ReadSize) }, Labels: defaultFilesystemIODeviceLabelValues, }, { Type: prometheus.CounterValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "filesystem_io_stats_device", "write_size_kilobytes_sum"), "Total kilobytes written to disk", defaultFilesystemIODeviceLabels, nil, ), Value: func(fsIODeviceStats NodeStatsFSIOStatsDeviceResponse) float64 { return float64(fsIODeviceStats.WriteSize) }, Labels: defaultFilesystemIODeviceLabelValues, }, }, } } // Describe add metrics descriptions func (c *Nodes) Describe(ch chan<- *prometheus.Desc) { ch <- nodesRolesMetric for _, metric := range c.nodeMetrics { ch <- metric.Desc } for _, metric := range c.gcCollectionMetrics { ch <- metric.Desc } for _, metric := range c.breakerMetrics { ch <- metric.Desc } for _, metric := range c.indexingPressureMetrics { ch <- metric.Desc } for _, metric := range c.threadPoolMetrics { ch <- metric.Desc } for _, metric := range c.filesystemDataMetrics { ch <- metric.Desc } for _, metric := range c.filesystemIODeviceMetrics { ch <- metric.Desc } } func (c *Nodes) fetchAndDecodeNodeStats() (nodeStatsResponse, error) { var nsr nodeStatsResponse u := *c.url if c.all { u.Path = path.Join(u.Path, "/_nodes/stats") } else { u.Path = path.Join(u.Path, "_nodes", c.node, "stats") } res, err := c.client.Get(u.String()) if err != nil { return nsr, fmt.Errorf("failed to get cluster health from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } defer func() { err = res.Body.Close() if err != nil { c.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return nsr, fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } bts, err := io.ReadAll(res.Body) if err != nil { return nsr, err } if err := json.Unmarshal(bts, &nsr); err != nil { return nsr, err } return nsr, nil } // Collect gets nodes metric values func (c *Nodes) Collect(ch chan<- prometheus.Metric) { nodeStatsResp, err := c.fetchAndDecodeNodeStats() if err != nil { c.logger.Warn( "failed to fetch and decode node stats", "err", err, ) return } for _, node := range nodeStatsResp.Nodes { // Handle the node labels metric roles := getRoles(node) for role, roleEnabled := range roles { val := 0.0 if roleEnabled { val = 1.0 } labels := []string{ nodeStatsResp.ClusterName, node.Host, node.Name, role, } ch <- prometheus.MustNewConstMetric( nodesRolesMetric, prometheus.GaugeValue, val, labels..., ) } for _, metric := range c.nodeMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(node), metric.Labels(nodeStatsResp.ClusterName, node)..., ) } // GC Stats for collector, gcStats := range node.JVM.GC.Collectors { for _, metric := range c.gcCollectionMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(gcStats), metric.Labels(nodeStatsResp.ClusterName, node, collector)..., ) } } // Breaker stats for breaker, bstats := range node.Breakers { for _, metric := range c.breakerMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(bstats), metric.Labels(nodeStatsResp.ClusterName, node, breaker)..., ) } } // Indexing Pressure stats for indexingPressure, ipstats := range node.IndexingPressure { for _, metric := range c.indexingPressureMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(ipstats), metric.Labels(nodeStatsResp.ClusterName, node, indexingPressure)..., ) } } // Thread Pool stats for pool, pstats := range node.ThreadPool { for _, metric := range c.threadPoolMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(pstats), metric.Labels(nodeStatsResp.ClusterName, node, pool)..., ) } } // File System Data Stats for _, fsDataStats := range node.FS.Data { for _, metric := range c.filesystemDataMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(fsDataStats), metric.Labels(nodeStatsResp.ClusterName, node, fsDataStats.Mount, fsDataStats.Path)..., ) } } // File System IO Device Stats for _, fsIODeviceStats := range node.FS.IOStats.Devices { for _, metric := range c.filesystemIODeviceMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(fsIODeviceStats), metric.Labels(nodeStatsResp.ClusterName, node, fsIODeviceStats.DeviceName)..., ) } } } } prometheus-elasticsearch-exporter-1.10.0/collector/nodes_response.go000066400000000000000000000423711511562765300260270ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import "encoding/json" // nodeStatsResponse is a representation of an Elasticsearch Node Stats type nodeStatsResponse struct { ClusterName string `json:"cluster_name"` Nodes map[string]NodeStatsNodeResponse } // NodeStatsNodeResponse defines node stats information structure for nodes type NodeStatsNodeResponse struct { Name string `json:"name"` Host string `json:"host"` Timestamp int64 `json:"timestamp"` TransportAddress string `json:"transport_address"` Hostname string `json:"hostname"` Roles []string `json:"roles"` Attributes map[string]string `json:"attributes"` Indices NodeStatsIndicesResponse `json:"indices"` OS NodeStatsOSResponse `json:"os"` Network NodeStatsNetworkResponse `json:"network"` FS NodeStatsFSResponse `json:"fs"` ThreadPool map[string]NodeStatsThreadPoolPoolResponse `json:"thread_pool"` JVM NodeStatsJVMResponse `json:"jvm"` Breakers map[string]NodeStatsBreakersResponse `json:"breakers"` HTTP map[string]interface{} `json:"http"` Transport NodeStatsTransportResponse `json:"transport"` Process NodeStatsProcessResponse `json:"process"` IndexingPressure map[string]NodeStatsIndexingPressureResponse `json:"indexing_pressure"` } // NodeStatsBreakersResponse is a representation of a statistics about the field data circuit breaker type NodeStatsBreakersResponse struct { EstimatedSize int64 `json:"estimated_size_in_bytes"` LimitSize int64 `json:"limit_size_in_bytes"` Overhead float64 `json:"overhead"` Tripped int64 `json:"tripped"` } // NodeStatsIndexingPressureResponse is a representation of a elasticsearch indexing pressure type NodeStatsIndexingPressureResponse struct { Current NodeStatsIndexingPressureCurrentResponse `json:"current"` LimitInBytes int64 `json:"limit_in_bytes"` } // NodeStatsIndexingPressureMemoryCurrentResponse is a representation of a elasticsearch indexing pressure current memory usage type NodeStatsIndexingPressureCurrentResponse struct { AllInBytes int64 `json:"all_in_bytes"` } // NodeStatsJVMResponse is a representation of a JVM stats, memory pool information, garbage collection, buffer pools, number of loaded/unloaded classes type NodeStatsJVMResponse struct { BufferPools map[string]NodeStatsJVMBufferPoolResponse `json:"buffer_pools"` GC NodeStatsJVMGCResponse `json:"gc"` Mem NodeStatsJVMMemResponse `json:"mem"` Uptime int64 `json:"uptime_in_millis"` } // NodeStatsJVMGCResponse defines node stats JVM garbage collector information structure type NodeStatsJVMGCResponse struct { Collectors map[string]NodeStatsJVMGCCollectorResponse `json:"collectors"` } // NodeStatsJVMGCCollectorResponse defines node stats JVM garbage collector collection information structure type NodeStatsJVMGCCollectorResponse struct { CollectionCount int64 `json:"collection_count"` CollectionTime int64 `json:"collection_time_in_millis"` } // NodeStatsJVMBufferPoolResponse defines node stats JVM buffer pool information structure type NodeStatsJVMBufferPoolResponse struct { Count int64 `json:"count"` TotalCapacity int64 `json:"total_capacity_in_bytes"` Used int64 `json:"used_in_bytes"` } // NodeStatsJVMMemResponse defines node stats JVM memory information structure type NodeStatsJVMMemResponse struct { HeapCommitted int64 `json:"heap_committed_in_bytes"` HeapUsed int64 `json:"heap_used_in_bytes"` HeapMax int64 `json:"heap_max_in_bytes"` NonHeapCommitted int64 `json:"non_heap_committed_in_bytes"` NonHeapUsed int64 `json:"non_heap_used_in_bytes"` Pools map[string]NodeStatsJVMMemPoolResponse `json:"pools"` } // NodeStatsJVMMemPoolResponse defines node stats JVM memory pool information structure type NodeStatsJVMMemPoolResponse struct { Used int64 `json:"used_in_bytes"` Max int64 `json:"max_in_bytes"` PeakUsed int64 `json:"peak_used_in_bytes"` PeakMax int64 `json:"peak_max_in_bytes"` } // NodeStatsNetworkResponse defines node stats network information structure type NodeStatsNetworkResponse struct { TCP NodeStatsTCPResponse `json:"tcp"` } // NodeStatsTransportResponse is a representation of a transport statistics about sent and received bytes in cluster communication type NodeStatsTransportResponse struct { ServerOpen int64 `json:"server_open"` RxCount int64 `json:"rx_count"` RxSize int64 `json:"rx_size_in_bytes"` TxCount int64 `json:"tx_count"` TxSize int64 `json:"tx_size_in_bytes"` } // NodeStatsThreadPoolPoolResponse is a representation of a statistics about each thread pool, including current size, queue and rejected tasks type NodeStatsThreadPoolPoolResponse struct { Threads int64 `json:"threads"` Queue int64 `json:"queue"` Active int64 `json:"active"` Rejected int64 `json:"rejected"` Largest int64 `json:"largest"` Completed int64 `json:"completed"` } // NodeStatsTCPResponse defines node stats TCP information structure type NodeStatsTCPResponse struct { ActiveOpens int64 `json:"active_opens"` PassiveOpens int64 `json:"passive_opens"` CurrEstab int64 `json:"curr_estab"` InSegs int64 `json:"in_segs"` OutSegs int64 `json:"out_segs"` RetransSegs int64 `json:"retrans_segs"` EstabResets int64 `json:"estab_resets"` AttemptFails int64 `json:"attempt_fails"` InErrs int64 `json:"in_errs"` OutRsts int64 `json:"out_rsts"` } // NodeStatsIndicesResponse is a representation of a indices stats (size, document count, indexing and deletion times, search times, field cache size, merges and flushes) type NodeStatsIndicesResponse struct { Docs NodeStatsIndicesDocsResponse Store NodeStatsIndicesStoreResponse Indexing NodeStatsIndicesIndexingResponse Merges NodeStatsIndicesMergesResponse Get NodeStatsIndicesGetResponse Search NodeStatsIndicesSearchResponse FieldData NodeStatsIndicesCacheResponse `json:"fielddata"` FilterCache NodeStatsIndicesCacheResponse `json:"filter_cache"` QueryCache NodeStatsIndicesCacheResponse `json:"query_cache"` RequestCache NodeStatsIndicesCacheResponse `json:"request_cache"` Flush NodeStatsIndicesFlushResponse Warmer NodeStatsIndicesWarmerResponse Segments NodeStatsIndicesSegmentsResponse Refresh NodeStatsIndicesRefreshResponse Translog NodeStatsIndicesTranslogResponse Completion NodeStatsIndicesCompletionResponse } // NodeStatsIndicesDocsResponse defines node stats docs information structure for indices type NodeStatsIndicesDocsResponse struct { Count int64 `json:"count"` Deleted int64 `json:"deleted"` } // NodeStatsIndicesRefreshResponse defines node stats refresh information structure for indices type NodeStatsIndicesRefreshResponse struct { Total int64 `json:"total"` TotalTime int64 `json:"total_time_in_millis"` ExternalTotal int64 `json:"external_total"` ExternalTotalTimeInMillis int64 `json:"external_total_time_in_millis"` } // NodeStatsIndicesTranslogResponse defines node stats translog information structure for indices type NodeStatsIndicesTranslogResponse struct { Operations int64 `json:"operations"` Size int64 `json:"size_in_bytes"` } // NodeStatsIndicesCompletionResponse defines node stats completion information structure for indices type NodeStatsIndicesCompletionResponse struct { Size int64 `json:"size_in_bytes"` } // NodeStatsIndicesSegmentsResponse defines node stats segments information structure for indices type NodeStatsIndicesSegmentsResponse struct { Count int64 `json:"count"` Memory int64 `json:"memory_in_bytes"` TermsMemory int64 `json:"terms_memory_in_bytes"` IndexWriterMemory int64 `json:"index_writer_memory_in_bytes"` NormsMemory int64 `json:"norms_memory_in_bytes"` StoredFieldsMemory int64 `json:"stored_fields_memory_in_bytes"` FixedBitSet int64 `json:"fixed_bit_set_memory_in_bytes"` DocValuesMemory int64 `json:"doc_values_memory_in_bytes"` TermVectorsMemory int64 `json:"term_vectors_memory_in_bytes"` PointsMemory int64 `json:"points_memory_in_bytes"` VersionMapMemory int64 `json:"version_map_memory_in_bytes"` } // NodeStatsIndicesStoreResponse defines node stats store information structure for indices type NodeStatsIndicesStoreResponse struct { Size int64 `json:"size_in_bytes"` ThrottleTime int64 `json:"throttle_time_in_millis"` } // NodeStatsIndicesIndexingResponse defines node stats indexing information structure for indices type NodeStatsIndicesIndexingResponse struct { IndexTotal int64 `json:"index_total"` IndexTime int64 `json:"index_time_in_millis"` IndexCurrent int64 `json:"index_current"` DeleteTotal int64 `json:"delete_total"` DeleteTime int64 `json:"delete_time_in_millis"` DeleteCurrent int64 `json:"delete_current"` IsThrottled bool `json:"is_throttled"` ThrottleTime int64 `json:"throttle_time_in_millis"` } // NodeStatsIndicesMergesResponse defines node stats merges information structure for indices type NodeStatsIndicesMergesResponse struct { Current int64 `json:"current"` CurrentDocs int64 `json:"current_docs"` CurrentSize int64 `json:"current_size_in_bytes"` Total int64 `json:"total"` TotalDocs int64 `json:"total_docs"` TotalSize int64 `json:"total_size_in_bytes"` TotalTime int64 `json:"total_time_in_millis"` TotalThrottledTime int64 `json:"total_throttled_time_in_millis"` } // NodeStatsIndicesGetResponse defines node stats get information structure for indices type NodeStatsIndicesGetResponse struct { Total int64 `json:"total"` Time int64 `json:"time_in_millis"` ExistsTotal int64 `json:"exists_total"` ExistsTime int64 `json:"exists_time_in_millis"` MissingTotal int64 `json:"missing_total"` MissingTime int64 `json:"missing_time_in_millis"` Current int64 `json:"current"` } // NodeStatsIndicesSearchResponse defines node stats search information structure for indices type NodeStatsIndicesSearchResponse struct { OpenContext int64 `json:"open_contexts"` QueryTotal int64 `json:"query_total"` QueryTime int64 `json:"query_time_in_millis"` QueryCurrent int64 `json:"query_current"` FetchTotal int64 `json:"fetch_total"` FetchTime int64 `json:"fetch_time_in_millis"` FetchCurrent int64 `json:"fetch_current"` SuggestTotal int64 `json:"suggest_total"` SuggestTime int64 `json:"suggest_time_in_millis"` ScrollTotal int64 `json:"scroll_total"` ScrollTime int64 `json:"scroll_time_in_millis"` } // NodeStatsIndicesFlushResponse defines node stats flush information structure for indices type NodeStatsIndicesFlushResponse struct { Total int64 `json:"total"` Time int64 `json:"total_time_in_millis"` } // NodeStatsIndicesWarmerResponse defines node stats warmer information structure for indices type NodeStatsIndicesWarmerResponse struct { Total int64 `json:"total"` TotalTime int64 `json:"total_time_in_millis"` } // NodeStatsIndicesCacheResponse defines node stats cache information structure for indices type NodeStatsIndicesCacheResponse struct { Evictions int64 `json:"evictions"` MemorySize int64 `json:"memory_size_in_bytes"` CacheCount int64 `json:"cache_count"` CacheSize int64 `json:"cache_size"` HitCount int64 `json:"hit_count"` MissCount int64 `json:"miss_count"` TotalCount int64 `json:"total_count"` } // NodeStatsOSResponse is a representation of a operating system stats, load average, mem, swap type NodeStatsOSResponse struct { Timestamp int64 `json:"timestamp"` Uptime int64 `json:"uptime_in_millis"` // LoadAvg was an array of per-cpu values pre-2.0, and is a string in 2.0 // Leaving this here in case we want to implement parsing logic later LoadAvg json.RawMessage `json:"load_average"` CPU NodeStatsOSCPUResponse `json:"cpu"` Mem NodeStatsOSMemResponse `json:"mem"` Swap NodeStatsOSSwapResponse `json:"swap"` } // NodeStatsOSMemResponse defines node stats operating system memory usage structure type NodeStatsOSMemResponse struct { Free int64 `json:"free_in_bytes"` Used int64 `json:"used_in_bytes"` ActualFree int64 `json:"actual_free_in_bytes"` ActualUsed int64 `json:"actual_used_in_bytes"` } // NodeStatsOSSwapResponse defines node stats operating system swap usage structure type NodeStatsOSSwapResponse struct { Used int64 `json:"used_in_bytes"` Free int64 `json:"free_in_bytes"` } // NodeStatsOSCPUResponse defines node stats operating system CPU usage structure type NodeStatsOSCPUResponse struct { LoadAvg NodeStatsOSCPULoadResponse `json:"load_average"` Percent int64 `json:"percent"` } // NodeStatsOSCPULoadResponse defines node stats operating system CPU load structure type NodeStatsOSCPULoadResponse struct { Load1 float64 `json:"1m"` Load5 float64 `json:"5m"` Load15 float64 `json:"15m"` } // NodeStatsProcessResponse is a representation of a process statistics, memory consumption, cpu usage, open file descriptors type NodeStatsProcessResponse struct { Timestamp int64 `json:"timestamp"` OpenFD int64 `json:"open_file_descriptors"` MaxFD int64 `json:"max_file_descriptors"` CPU NodeStatsProcessCPUResponse `json:"cpu"` Memory NodeStatsProcessMemResponse `json:"mem"` } // NodeStatsProcessMemResponse defines node stats process memory usage structure type NodeStatsProcessMemResponse struct { Resident int64 `json:"resident_in_bytes"` Share int64 `json:"share_in_bytes"` TotalVirtual int64 `json:"total_virtual_in_bytes"` } // NodeStatsProcessCPUResponse defines node stats process CPU usage structure type NodeStatsProcessCPUResponse struct { Percent int64 `json:"percent"` Total int64 `json:"total_in_millis"` } // NodeStatsHTTPResponse defines node stats HTTP connections structure type NodeStatsHTTPResponse struct { CurrentOpen int64 `json:"current_open"` TotalOpen int64 `json:"total_open"` } // NodeStatsFSResponse is a representation of a file system information, data path, free disk space, read/write stats type NodeStatsFSResponse struct { Timestamp int64 `json:"timestamp"` Data []NodeStatsFSDataResponse `json:"data"` IOStats NodeStatsFSIOStatsResponse `json:"io_stats"` } // NodeStatsFSDataResponse defines node stats filesystem data structure type NodeStatsFSDataResponse struct { Path string `json:"path"` Mount string `json:"mount"` Device string `json:"dev"` Total int64 `json:"total_in_bytes"` Free int64 `json:"free_in_bytes"` Available int64 `json:"available_in_bytes"` } // NodeStatsFSIOStatsResponse defines node stats filesystem device structure type NodeStatsFSIOStatsResponse struct { Devices []NodeStatsFSIOStatsDeviceResponse `json:"devices"` } // NodeStatsFSIOStatsDeviceResponse is a representation of a node stat filesystem device type NodeStatsFSIOStatsDeviceResponse struct { DeviceName string `json:"device_name"` Operations int64 `json:"operations"` ReadOperations int64 `json:"read_operations"` WriteOperations int64 `json:"write_operations"` ReadSize int64 `json:"read_kilobytes"` WriteSize int64 `json:"write_kilobytes"` } // ClusterHealthResponse is a representation of a Elasticsearch Cluster Health type ClusterHealthResponse struct { ActivePrimaryShards int64 `json:"active_primary_shards"` ActiveShards int64 `json:"active_shards"` ClusterName string `json:"cluster_name"` DelayedUnassignedShards int64 `json:"delayed_unassigned_shards"` InitializingShards int64 `json:"initializing_shards"` NumberOfDataNodes int64 `json:"number_of_data_nodes"` NumberOfInFlightFetch int64 `json:"number_of_in_flight_fetch"` NumberOfNodes int64 `json:"number_of_nodes"` NumberOfPendingTasks int64 `json:"number_of_pending_tasks"` RelocatingShards int64 `json:"relocating_shards"` Status string `json:"status"` TimedOut bool `json:"timed_out"` UnassignedShards int64 `json:"unassigned_shards"` } prometheus-elasticsearch-exporter-1.10.0/collector/nodes_test.go000066400000000000000000007125111511562765300251500ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestNodesStats(t *testing.T) { tests := []struct { name string file string want string }{ // { // name: "5.4.2", // file: "../fixtures/nodestats/5.4.2.json", // want: ``, // }, { name: "5.6.16", file: "../fixtures/nodestats/5.6.16.json", want: `# HELP elasticsearch_breakers_estimated_size_bytes Estimated size in bytes of breaker # TYPE elasticsearch_breakers_estimated_size_bytes gauge elasticsearch_breakers_estimated_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_breakers_limit_size_bytes Limit size in bytes for breaker # TYPE elasticsearch_breakers_limit_size_bytes gauge elasticsearch_breakers_limit_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1.246652006e+09 elasticsearch_breakers_limit_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 2.077753344e+09 elasticsearch_breakers_limit_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1.45442734e+09 elasticsearch_breakers_limit_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1.246652006e+09 # HELP elasticsearch_breakers_overhead Overhead of circuit breakers # TYPE elasticsearch_breakers_overhead counter elasticsearch_breakers_overhead{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1.03 elasticsearch_breakers_overhead{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1 elasticsearch_breakers_overhead{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1 elasticsearch_breakers_overhead{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1 # HELP elasticsearch_breakers_tripped tripped for breaker # TYPE elasticsearch_breakers_tripped counter elasticsearch_breakers_tripped{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_tripped{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_tripped{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 elasticsearch_breakers_tripped{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_filesystem_data_available_bytes Available space on block device in bytes # TYPE elasticsearch_filesystem_data_available_bytes gauge elasticsearch_filesystem_data_available_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",mount="/usr/share/elasticsearch/data (/dev/mapper/vg0-root)",name="bVrN1Hx",path="/usr/share/elasticsearch/data/nodes/0"} 7.7533405184e+10 # HELP elasticsearch_filesystem_data_free_bytes Free space on block device in bytes # TYPE elasticsearch_filesystem_data_free_bytes gauge elasticsearch_filesystem_data_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",mount="/usr/share/elasticsearch/data (/dev/mapper/vg0-root)",name="bVrN1Hx",path="/usr/share/elasticsearch/data/nodes/0"} 7.7533405184e+10 # HELP elasticsearch_filesystem_data_size_bytes Size of block device in bytes # TYPE elasticsearch_filesystem_data_size_bytes gauge elasticsearch_filesystem_data_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",mount="/usr/share/elasticsearch/data (/dev/mapper/vg0-root)",name="bVrN1Hx",path="/usr/share/elasticsearch/data/nodes/0"} 4.76630163456e+11 # HELP elasticsearch_filesystem_io_stats_device_operations_count Count of disk operations # TYPE elasticsearch_filesystem_io_stats_device_operations_count counter elasticsearch_filesystem_io_stats_device_operations_count{cluster="elasticsearch",device="dm-2",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 2517 # HELP elasticsearch_filesystem_io_stats_device_read_operations_count Count of disk read operations # TYPE elasticsearch_filesystem_io_stats_device_read_operations_count counter elasticsearch_filesystem_io_stats_device_read_operations_count{cluster="elasticsearch",device="dm-2",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 706 # HELP elasticsearch_filesystem_io_stats_device_read_size_kilobytes_sum Total kilobytes read from disk # TYPE elasticsearch_filesystem_io_stats_device_read_size_kilobytes_sum counter elasticsearch_filesystem_io_stats_device_read_size_kilobytes_sum{cluster="elasticsearch",device="dm-2",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 12916 # HELP elasticsearch_filesystem_io_stats_device_write_operations_count Count of disk write operations # TYPE elasticsearch_filesystem_io_stats_device_write_operations_count counter elasticsearch_filesystem_io_stats_device_write_operations_count{cluster="elasticsearch",device="dm-2",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1811 # HELP elasticsearch_filesystem_io_stats_device_write_size_kilobytes_sum Total kilobytes written to disk # TYPE elasticsearch_filesystem_io_stats_device_write_size_kilobytes_sum counter elasticsearch_filesystem_io_stats_device_write_size_kilobytes_sum{cluster="elasticsearch",device="dm-2",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 17760 # HELP elasticsearch_indices_completion_size_in_bytes Completion in bytes # TYPE elasticsearch_indices_completion_size_in_bytes counter elasticsearch_indices_completion_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_docs Count of documents on this node # TYPE elasticsearch_indices_docs gauge elasticsearch_indices_docs{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 5 # HELP elasticsearch_indices_docs_deleted Count of deleted documents on this node # TYPE elasticsearch_indices_docs_deleted gauge elasticsearch_indices_docs_deleted{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_fielddata_evictions Evictions from field data # TYPE elasticsearch_indices_fielddata_evictions counter elasticsearch_indices_fielddata_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_fielddata_memory_size_bytes Field data cache memory usage in bytes # TYPE elasticsearch_indices_fielddata_memory_size_bytes gauge elasticsearch_indices_fielddata_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_filter_cache_evictions Evictions from filter cache # TYPE elasticsearch_indices_filter_cache_evictions counter elasticsearch_indices_filter_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_filter_cache_memory_size_bytes Filter cache memory usage in bytes # TYPE elasticsearch_indices_filter_cache_memory_size_bytes gauge elasticsearch_indices_filter_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_flush_time_seconds Cumulative flush time in seconds # TYPE elasticsearch_indices_flush_time_seconds counter elasticsearch_indices_flush_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_flush_total Total flushes # TYPE elasticsearch_indices_flush_total counter elasticsearch_indices_flush_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_exists_time_seconds Total time get exists in seconds # TYPE elasticsearch_indices_get_exists_time_seconds counter elasticsearch_indices_get_exists_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_exists_total Total get exists operations # TYPE elasticsearch_indices_get_exists_total counter elasticsearch_indices_get_exists_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_missing_time_seconds Total time of get missing in seconds # TYPE elasticsearch_indices_get_missing_time_seconds counter elasticsearch_indices_get_missing_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_missing_total Total get missing # TYPE elasticsearch_indices_get_missing_total counter elasticsearch_indices_get_missing_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_time_seconds Total get time in seconds # TYPE elasticsearch_indices_get_time_seconds counter elasticsearch_indices_get_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_get_total Total get # TYPE elasticsearch_indices_get_total counter elasticsearch_indices_get_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_indexing_delete_time_seconds_total Total time indexing delete in seconds # TYPE elasticsearch_indices_indexing_delete_time_seconds_total counter elasticsearch_indices_indexing_delete_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_indexing_delete_total Total indexing deletes # TYPE elasticsearch_indices_indexing_delete_total counter elasticsearch_indices_indexing_delete_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_indexing_index_time_seconds_total Cumulative index time in seconds # TYPE elasticsearch_indices_indexing_index_time_seconds_total counter elasticsearch_indices_indexing_index_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0.039 # HELP elasticsearch_indices_indexing_index_total Total index calls # TYPE elasticsearch_indices_indexing_index_total counter elasticsearch_indices_indexing_index_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 5 # HELP elasticsearch_indices_indexing_is_throttled Indexing throttling # TYPE elasticsearch_indices_indexing_is_throttled gauge elasticsearch_indices_indexing_is_throttled{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_indexing_throttle_time_seconds_total Cumulative indexing throttling time # TYPE elasticsearch_indices_indexing_throttle_time_seconds_total counter elasticsearch_indices_indexing_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_current Current merges # TYPE elasticsearch_indices_merges_current gauge elasticsearch_indices_merges_current{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_current_size_in_bytes Size of a current merges in bytes # TYPE elasticsearch_indices_merges_current_size_in_bytes gauge elasticsearch_indices_merges_current_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_docs_total Cumulative docs merged # TYPE elasticsearch_indices_merges_docs_total counter elasticsearch_indices_merges_docs_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_total Total merges # TYPE elasticsearch_indices_merges_total counter elasticsearch_indices_merges_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_total_size_bytes_total Total merge size in bytes # TYPE elasticsearch_indices_merges_total_size_bytes_total counter elasticsearch_indices_merges_total_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_total_throttled_time_seconds_total Total throttled time of merges in seconds # TYPE elasticsearch_indices_merges_total_throttled_time_seconds_total counter elasticsearch_indices_merges_total_throttled_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_merges_total_time_seconds_total Total time spent merging in seconds # TYPE elasticsearch_indices_merges_total_time_seconds_total counter elasticsearch_indices_merges_total_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_cache_size Query cache cache size # TYPE elasticsearch_indices_query_cache_cache_size gauge elasticsearch_indices_query_cache_cache_size{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_cache_total Query cache cache count # TYPE elasticsearch_indices_query_cache_cache_total counter elasticsearch_indices_query_cache_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_count Query cache count # TYPE elasticsearch_indices_query_cache_count counter elasticsearch_indices_query_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_evictions Evictions from query cache # TYPE elasticsearch_indices_query_cache_evictions counter elasticsearch_indices_query_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_memory_size_bytes Query cache memory usage in bytes # TYPE elasticsearch_indices_query_cache_memory_size_bytes gauge elasticsearch_indices_query_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_cache_total Query cache total count # TYPE elasticsearch_indices_query_cache_total counter elasticsearch_indices_query_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_query_miss_count Query miss count # TYPE elasticsearch_indices_query_miss_count counter elasticsearch_indices_query_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_refresh_external_time_seconds_total Total time spent external refreshing in seconds # TYPE elasticsearch_indices_refresh_external_time_seconds_total counter elasticsearch_indices_refresh_external_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_refresh_external_total Total external refreshes # TYPE elasticsearch_indices_refresh_external_total counter elasticsearch_indices_refresh_external_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_refresh_time_seconds_total Total time spent refreshing in seconds # TYPE elasticsearch_indices_refresh_time_seconds_total counter elasticsearch_indices_refresh_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0.086 # HELP elasticsearch_indices_refresh_total Total refreshes # TYPE elasticsearch_indices_refresh_total counter elasticsearch_indices_refresh_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 65 # HELP elasticsearch_indices_request_cache_count Request cache count # TYPE elasticsearch_indices_request_cache_count counter elasticsearch_indices_request_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_request_cache_evictions Evictions from request cache # TYPE elasticsearch_indices_request_cache_evictions counter elasticsearch_indices_request_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_request_cache_memory_size_bytes Request cache memory usage in bytes # TYPE elasticsearch_indices_request_cache_memory_size_bytes gauge elasticsearch_indices_request_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_request_miss_count Request miss count # TYPE elasticsearch_indices_request_miss_count counter elasticsearch_indices_request_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_fetch_time_seconds Total search fetch time in seconds # TYPE elasticsearch_indices_search_fetch_time_seconds counter elasticsearch_indices_search_fetch_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_fetch_total Total number of fetches # TYPE elasticsearch_indices_search_fetch_total counter elasticsearch_indices_search_fetch_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_query_time_seconds Total search query time in seconds # TYPE elasticsearch_indices_search_query_time_seconds counter elasticsearch_indices_search_query_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_query_total Total number of queries # TYPE elasticsearch_indices_search_query_total counter elasticsearch_indices_search_query_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_scroll_time_seconds Total scroll time in seconds # TYPE elasticsearch_indices_search_scroll_time_seconds counter elasticsearch_indices_search_scroll_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_scroll_total Total number of scrolls # TYPE elasticsearch_indices_search_scroll_total counter elasticsearch_indices_search_scroll_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_suggest_time_seconds Total suggest time in seconds # TYPE elasticsearch_indices_search_suggest_time_seconds counter elasticsearch_indices_search_suggest_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_search_suggest_total Total number of suggests # TYPE elasticsearch_indices_search_suggest_total counter elasticsearch_indices_search_suggest_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_segments_count Count of index segments on this node # TYPE elasticsearch_indices_segments_count gauge elasticsearch_indices_segments_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 5 # HELP elasticsearch_indices_segments_doc_values_memory_in_bytes Count of doc values memory # TYPE elasticsearch_indices_segments_doc_values_memory_in_bytes gauge elasticsearch_indices_segments_doc_values_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 460 # HELP elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes Count of fixed bit set # TYPE elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes gauge elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_segments_index_writer_memory_in_bytes Count of memory for index writer on this node # TYPE elasticsearch_indices_segments_index_writer_memory_in_bytes gauge elasticsearch_indices_segments_index_writer_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_segments_memory_bytes Current memory size of segments in bytes # TYPE elasticsearch_indices_segments_memory_bytes gauge elasticsearch_indices_segments_memory_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 12940 # HELP elasticsearch_indices_segments_norms_memory_in_bytes Count of memory used by norms # TYPE elasticsearch_indices_segments_norms_memory_in_bytes gauge elasticsearch_indices_segments_norms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 960 # HELP elasticsearch_indices_segments_points_memory_in_bytes Point values memory usage in bytes # TYPE elasticsearch_indices_segments_points_memory_in_bytes gauge elasticsearch_indices_segments_points_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_segments_stored_fields_memory_in_bytes Count of stored fields memory # TYPE elasticsearch_indices_segments_stored_fields_memory_in_bytes gauge elasticsearch_indices_segments_stored_fields_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1560 # HELP elasticsearch_indices_segments_term_vectors_memory_in_bytes Term vectors memory usage in bytes # TYPE elasticsearch_indices_segments_term_vectors_memory_in_bytes gauge elasticsearch_indices_segments_term_vectors_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_segments_terms_memory_in_bytes Count of terms in memory for this node # TYPE elasticsearch_indices_segments_terms_memory_in_bytes gauge elasticsearch_indices_segments_terms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 9960 # HELP elasticsearch_indices_segments_version_map_memory_in_bytes Version map memory usage in bytes # TYPE elasticsearch_indices_segments_version_map_memory_in_bytes gauge elasticsearch_indices_segments_version_map_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_store_size_bytes Current size of stored index data in bytes # TYPE elasticsearch_indices_store_size_bytes gauge elasticsearch_indices_store_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 5721 # HELP elasticsearch_indices_store_throttle_time_seconds_total Throttle time for index store in seconds # TYPE elasticsearch_indices_store_throttle_time_seconds_total counter elasticsearch_indices_store_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_indices_translog_operations Total translog operations # TYPE elasticsearch_indices_translog_operations counter elasticsearch_indices_translog_operations{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 5 # HELP elasticsearch_indices_translog_size_in_bytes Total translog size in bytes # TYPE elasticsearch_indices_translog_size_in_bytes gauge elasticsearch_indices_translog_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1743 # HELP elasticsearch_indices_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_indices_warmer_time_seconds_total counter elasticsearch_indices_warmer_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0.001 # HELP elasticsearch_indices_warmer_total Total warmer count # TYPE elasticsearch_indices_warmer_total counter elasticsearch_indices_warmer_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 35 # HELP elasticsearch_jvm_buffer_pool_used_bytes JVM buffer currently used # TYPE elasticsearch_jvm_buffer_pool_used_bytes gauge elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="direct"} 2.52727869e+08 elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="mapped"} 15007 # HELP elasticsearch_jvm_gc_collection_seconds_count Count of JVM GC runs # TYPE elasticsearch_jvm_gc_collection_seconds_count counter elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="127.0.0.1",name="bVrN1Hx"} 1 elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="127.0.0.1",name="bVrN1Hx"} 2 # HELP elasticsearch_jvm_gc_collection_seconds_sum GC run time in seconds # TYPE elasticsearch_jvm_gc_collection_seconds_sum counter elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="127.0.0.1",name="bVrN1Hx"} 0.109 elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="127.0.0.1",name="bVrN1Hx"} 0.143 # HELP elasticsearch_jvm_memory_committed_bytes JVM memory currently committed by area # TYPE elasticsearch_jvm_memory_committed_bytes gauge elasticsearch_jvm_memory_committed_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 2.077753344e+09 elasticsearch_jvm_memory_committed_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 7.5362304e+07 # HELP elasticsearch_jvm_memory_max_bytes JVM memory max # TYPE elasticsearch_jvm_memory_max_bytes gauge elasticsearch_jvm_memory_max_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 2.077753344e+09 # HELP elasticsearch_jvm_memory_pool_max_bytes JVM memory max by pool # TYPE elasticsearch_jvm_memory_pool_max_bytes counter elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="old"} 1.449590784e+09 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="survivor"} 6.9730304e+07 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="young"} 5.58432256e+08 # HELP elasticsearch_jvm_memory_pool_peak_max_bytes JVM memory peak max by pool # TYPE elasticsearch_jvm_memory_pool_peak_max_bytes counter elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="old"} 1.449590784e+09 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="survivor"} 6.9730304e+07 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="young"} 5.58432256e+08 # HELP elasticsearch_jvm_memory_pool_peak_used_bytes JVM memory peak used by pool # TYPE elasticsearch_jvm_memory_pool_peak_used_bytes counter elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="old"} 2.10051288e+08 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="survivor"} 6.9730304e+07 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="young"} 5.58432256e+08 # HELP elasticsearch_jvm_memory_pool_used_bytes JVM memory currently used by pool # TYPE elasticsearch_jvm_memory_pool_used_bytes gauge elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="old"} 2.10051288e+08 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="survivor"} 6.9730304e+07 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",pool="young"} 5.3925336e+07 # HELP elasticsearch_jvm_memory_used_bytes JVM memory currently used by area # TYPE elasticsearch_jvm_memory_used_bytes gauge elasticsearch_jvm_memory_used_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 3.33706928e+08 elasticsearch_jvm_memory_used_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 7.0212664e+07 # HELP elasticsearch_jvm_uptime_seconds JVM process uptime in seconds # TYPE elasticsearch_jvm_uptime_seconds gauge elasticsearch_jvm_uptime_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="mapped"} 14.845 # HELP elasticsearch_nodes_roles Node roles # TYPE elasticsearch_nodes_roles gauge elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="client"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data_cold"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data_content"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data_frozen"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data_hot"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="data_warm"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="ingest"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="master"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="ml"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="remote_cluster_client"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="127.0.0.1",name="bVrN1Hx",role="transform"} 0 # HELP elasticsearch_os_cpu_percent Percent CPU used by OS # TYPE elasticsearch_os_cpu_percent gauge elasticsearch_os_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 23 # HELP elasticsearch_os_load1 Shortterm load average # TYPE elasticsearch_os_load1 gauge elasticsearch_os_load1{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 45.68 # HELP elasticsearch_os_load15 Longterm load average # TYPE elasticsearch_os_load15 gauge elasticsearch_os_load15{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 96.01 # HELP elasticsearch_os_load5 Midterm load average # TYPE elasticsearch_os_load5 gauge elasticsearch_os_load5{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 150.34 # HELP elasticsearch_os_mem_actual_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_actual_free_bytes gauge elasticsearch_os_mem_actual_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_os_mem_actual_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_actual_used_bytes gauge elasticsearch_os_mem_actual_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_os_mem_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_free_bytes gauge elasticsearch_os_mem_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 7.009173504e+09 # HELP elasticsearch_os_mem_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_used_bytes gauge elasticsearch_os_mem_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 2.6614063104e+10 # HELP elasticsearch_process_cpu_percent Percent CPU used by process # TYPE elasticsearch_process_cpu_percent gauge elasticsearch_process_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 8 # HELP elasticsearch_process_cpu_seconds_total Process CPU time in seconds # TYPE elasticsearch_process_cpu_seconds_total counter elasticsearch_process_cpu_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 14.51 # HELP elasticsearch_process_max_files_descriptors Max file descriptors # TYPE elasticsearch_process_max_files_descriptors gauge elasticsearch_process_max_files_descriptors{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 1.048576e+06 # HELP elasticsearch_process_mem_resident_size_bytes Resident memory in use by process in bytes # TYPE elasticsearch_process_mem_resident_size_bytes gauge elasticsearch_process_mem_resident_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_process_mem_share_size_bytes Shared memory in use by process in bytes # TYPE elasticsearch_process_mem_share_size_bytes gauge elasticsearch_process_mem_share_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_process_mem_virtual_size_bytes Total virtual memory used in bytes # TYPE elasticsearch_process_mem_virtual_size_bytes gauge elasticsearch_process_mem_virtual_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 8.293711872e+09 # HELP elasticsearch_process_open_files_count Open file descriptors # TYPE elasticsearch_process_open_files_count gauge elasticsearch_process_open_files_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 308 # HELP elasticsearch_thread_pool_active_count Thread Pool threads active # TYPE elasticsearch_thread_pool_active_count gauge elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 1 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_thread_pool_completed_count Thread Pool operations completed # TYPE elasticsearch_thread_pool_completed_count counter elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 5 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 38 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 5 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 2 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 31 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_thread_pool_largest_count Thread Pool largest threads count # TYPE elasticsearch_thread_pool_largest_count gauge elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 5 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 4 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 4 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_thread_pool_queue_count Thread Pool operations queued # TYPE elasticsearch_thread_pool_queue_count gauge elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_thread_pool_rejected_count Thread Pool operations rejected # TYPE elasticsearch_thread_pool_rejected_count counter elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_thread_pool_threads_count Thread Pool current threads count # TYPE elasticsearch_thread_pool_threads_count gauge elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="bulk"} 5 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_started"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="fetch_shard_store"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="flush"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="force_merge"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="generic"} 4 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="get"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="index"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="listener"} 4 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="management"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="refresh"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="search"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="snapshot"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx",type="warmer"} 0 # HELP elasticsearch_transport_rx_packets_total Count of packets received # TYPE elasticsearch_transport_rx_packets_total counter elasticsearch_transport_rx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_transport_rx_size_bytes_total Total number of bytes received # TYPE elasticsearch_transport_rx_size_bytes_total counter elasticsearch_transport_rx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_transport_tx_packets_total Count of packets sent # TYPE elasticsearch_transport_tx_packets_total counter elasticsearch_transport_tx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 # HELP elasticsearch_transport_tx_size_bytes_total Total number of bytes sent # TYPE elasticsearch_transport_tx_size_bytes_total counter elasticsearch_transport_tx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="127.0.0.1",name="bVrN1Hx"} 0 `, }, { name: "6.8.8", file: "../fixtures/nodestats/6.8.8.json", want: `# HELP elasticsearch_breakers_estimated_size_bytes Estimated size in bytes of breaker # TYPE elasticsearch_breakers_estimated_size_bytes gauge elasticsearch_breakers_estimated_size_bytes{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 8490 elasticsearch_breakers_estimated_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 8490 elasticsearch_breakers_estimated_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_breakers_limit_size_bytes Limit size in bytes for breaker # TYPE elasticsearch_breakers_limit_size_bytes gauge elasticsearch_breakers_limit_size_bytes{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.073741824e+09 elasticsearch_breakers_limit_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 6.44245094e+08 elasticsearch_breakers_limit_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.073741824e+09 elasticsearch_breakers_limit_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 7.51619276e+08 elasticsearch_breakers_limit_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 6.44245094e+08 # HELP elasticsearch_breakers_overhead Overhead of circuit breakers # TYPE elasticsearch_breakers_overhead counter elasticsearch_breakers_overhead{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1 elasticsearch_breakers_overhead{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.03 elasticsearch_breakers_overhead{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1 elasticsearch_breakers_overhead{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1 elasticsearch_breakers_overhead{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1 # HELP elasticsearch_breakers_tripped tripped for breaker # TYPE elasticsearch_breakers_tripped counter elasticsearch_breakers_tripped{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_tripped{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_tripped{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_tripped{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_breakers_tripped{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_filesystem_data_available_bytes Available space on block device in bytes # TYPE elasticsearch_filesystem_data_available_bytes gauge elasticsearch_filesystem_data_available_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="9_P7yui",path="/usr/share/elasticsearch/data/nodes/0"} 7.753281536e+10 # HELP elasticsearch_filesystem_data_free_bytes Free space on block device in bytes # TYPE elasticsearch_filesystem_data_free_bytes gauge elasticsearch_filesystem_data_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="9_P7yui",path="/usr/share/elasticsearch/data/nodes/0"} 7.753281536e+10 # HELP elasticsearch_filesystem_data_size_bytes Size of block device in bytes # TYPE elasticsearch_filesystem_data_size_bytes gauge elasticsearch_filesystem_data_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="9_P7yui",path="/usr/share/elasticsearch/data/nodes/0"} 4.76630163456e+11 # HELP elasticsearch_indices_completion_size_in_bytes Completion in bytes # TYPE elasticsearch_indices_completion_size_in_bytes counter elasticsearch_indices_completion_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_docs Count of documents on this node # TYPE elasticsearch_indices_docs gauge elasticsearch_indices_docs{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_indices_docs_deleted Count of deleted documents on this node # TYPE elasticsearch_indices_docs_deleted gauge elasticsearch_indices_docs_deleted{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_fielddata_evictions Evictions from field data # TYPE elasticsearch_indices_fielddata_evictions counter elasticsearch_indices_fielddata_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_fielddata_memory_size_bytes Field data cache memory usage in bytes # TYPE elasticsearch_indices_fielddata_memory_size_bytes gauge elasticsearch_indices_fielddata_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_filter_cache_evictions Evictions from filter cache # TYPE elasticsearch_indices_filter_cache_evictions counter elasticsearch_indices_filter_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_filter_cache_memory_size_bytes Filter cache memory usage in bytes # TYPE elasticsearch_indices_filter_cache_memory_size_bytes gauge elasticsearch_indices_filter_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_flush_time_seconds Cumulative flush time in seconds # TYPE elasticsearch_indices_flush_time_seconds counter elasticsearch_indices_flush_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_flush_total Total flushes # TYPE elasticsearch_indices_flush_total counter elasticsearch_indices_flush_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_exists_time_seconds Total time get exists in seconds # TYPE elasticsearch_indices_get_exists_time_seconds counter elasticsearch_indices_get_exists_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_exists_total Total get exists operations # TYPE elasticsearch_indices_get_exists_total counter elasticsearch_indices_get_exists_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_missing_time_seconds Total time of get missing in seconds # TYPE elasticsearch_indices_get_missing_time_seconds counter elasticsearch_indices_get_missing_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_missing_total Total get missing # TYPE elasticsearch_indices_get_missing_total counter elasticsearch_indices_get_missing_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_time_seconds Total get time in seconds # TYPE elasticsearch_indices_get_time_seconds counter elasticsearch_indices_get_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_get_total Total get # TYPE elasticsearch_indices_get_total counter elasticsearch_indices_get_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_indexing_delete_time_seconds_total Total time indexing delete in seconds # TYPE elasticsearch_indices_indexing_delete_time_seconds_total counter elasticsearch_indices_indexing_delete_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_indexing_delete_total Total indexing deletes # TYPE elasticsearch_indices_indexing_delete_total counter elasticsearch_indices_indexing_delete_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_indexing_index_time_seconds_total Cumulative index time in seconds # TYPE elasticsearch_indices_indexing_index_time_seconds_total counter elasticsearch_indices_indexing_index_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0.038 # HELP elasticsearch_indices_indexing_index_total Total index calls # TYPE elasticsearch_indices_indexing_index_total counter elasticsearch_indices_indexing_index_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_indices_indexing_is_throttled Indexing throttling # TYPE elasticsearch_indices_indexing_is_throttled gauge elasticsearch_indices_indexing_is_throttled{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_indexing_throttle_time_seconds_total Cumulative indexing throttling time # TYPE elasticsearch_indices_indexing_throttle_time_seconds_total counter elasticsearch_indices_indexing_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_current Current merges # TYPE elasticsearch_indices_merges_current gauge elasticsearch_indices_merges_current{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_current_size_in_bytes Size of a current merges in bytes # TYPE elasticsearch_indices_merges_current_size_in_bytes gauge elasticsearch_indices_merges_current_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_docs_total Cumulative docs merged # TYPE elasticsearch_indices_merges_docs_total counter elasticsearch_indices_merges_docs_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_total Total merges # TYPE elasticsearch_indices_merges_total counter elasticsearch_indices_merges_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_total_size_bytes_total Total merge size in bytes # TYPE elasticsearch_indices_merges_total_size_bytes_total counter elasticsearch_indices_merges_total_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_total_throttled_time_seconds_total Total throttled time of merges in seconds # TYPE elasticsearch_indices_merges_total_throttled_time_seconds_total counter elasticsearch_indices_merges_total_throttled_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_merges_total_time_seconds_total Total time spent merging in seconds # TYPE elasticsearch_indices_merges_total_time_seconds_total counter elasticsearch_indices_merges_total_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_cache_size Query cache cache size # TYPE elasticsearch_indices_query_cache_cache_size gauge elasticsearch_indices_query_cache_cache_size{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_cache_total Query cache cache count # TYPE elasticsearch_indices_query_cache_cache_total counter elasticsearch_indices_query_cache_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_count Query cache count # TYPE elasticsearch_indices_query_cache_count counter elasticsearch_indices_query_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_evictions Evictions from query cache # TYPE elasticsearch_indices_query_cache_evictions counter elasticsearch_indices_query_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_memory_size_bytes Query cache memory usage in bytes # TYPE elasticsearch_indices_query_cache_memory_size_bytes gauge elasticsearch_indices_query_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_cache_total Query cache total count # TYPE elasticsearch_indices_query_cache_total counter elasticsearch_indices_query_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_query_miss_count Query miss count # TYPE elasticsearch_indices_query_miss_count counter elasticsearch_indices_query_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_refresh_external_time_seconds_total Total time spent external refreshing in seconds # TYPE elasticsearch_indices_refresh_external_time_seconds_total counter elasticsearch_indices_refresh_external_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_refresh_external_total Total external refreshes # TYPE elasticsearch_indices_refresh_external_total counter elasticsearch_indices_refresh_external_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_refresh_time_seconds_total Total time spent refreshing in seconds # TYPE elasticsearch_indices_refresh_time_seconds_total counter elasticsearch_indices_refresh_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0.103 # HELP elasticsearch_indices_refresh_total Total refreshes # TYPE elasticsearch_indices_refresh_total counter elasticsearch_indices_refresh_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 65 # HELP elasticsearch_indices_request_cache_count Request cache count # TYPE elasticsearch_indices_request_cache_count counter elasticsearch_indices_request_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_request_cache_evictions Evictions from request cache # TYPE elasticsearch_indices_request_cache_evictions counter elasticsearch_indices_request_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_request_cache_memory_size_bytes Request cache memory usage in bytes # TYPE elasticsearch_indices_request_cache_memory_size_bytes gauge elasticsearch_indices_request_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_request_miss_count Request miss count # TYPE elasticsearch_indices_request_miss_count counter elasticsearch_indices_request_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_fetch_time_seconds Total search fetch time in seconds # TYPE elasticsearch_indices_search_fetch_time_seconds counter elasticsearch_indices_search_fetch_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_fetch_total Total number of fetches # TYPE elasticsearch_indices_search_fetch_total counter elasticsearch_indices_search_fetch_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_query_time_seconds Total search query time in seconds # TYPE elasticsearch_indices_search_query_time_seconds counter elasticsearch_indices_search_query_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_query_total Total number of queries # TYPE elasticsearch_indices_search_query_total counter elasticsearch_indices_search_query_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_scroll_time_seconds Total scroll time in seconds # TYPE elasticsearch_indices_search_scroll_time_seconds counter elasticsearch_indices_search_scroll_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_scroll_total Total number of scrolls # TYPE elasticsearch_indices_search_scroll_total counter elasticsearch_indices_search_scroll_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_suggest_time_seconds Total suggest time in seconds # TYPE elasticsearch_indices_search_suggest_time_seconds counter elasticsearch_indices_search_suggest_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_search_suggest_total Total number of suggests # TYPE elasticsearch_indices_search_suggest_total counter elasticsearch_indices_search_suggest_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_segments_count Count of index segments on this node # TYPE elasticsearch_indices_segments_count gauge elasticsearch_indices_segments_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_indices_segments_doc_values_memory_in_bytes Count of doc values memory # TYPE elasticsearch_indices_segments_doc_values_memory_in_bytes gauge elasticsearch_indices_segments_doc_values_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 340 # HELP elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes Count of fixed bit set # TYPE elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes gauge elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_segments_index_writer_memory_in_bytes Count of memory for index writer on this node # TYPE elasticsearch_indices_segments_index_writer_memory_in_bytes gauge elasticsearch_indices_segments_index_writer_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_segments_memory_bytes Current memory size of segments in bytes # TYPE elasticsearch_indices_segments_memory_bytes gauge elasticsearch_indices_segments_memory_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 8490 # HELP elasticsearch_indices_segments_norms_memory_in_bytes Count of memory used by norms # TYPE elasticsearch_indices_segments_norms_memory_in_bytes gauge elasticsearch_indices_segments_norms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 640 # HELP elasticsearch_indices_segments_points_memory_in_bytes Point values memory usage in bytes # TYPE elasticsearch_indices_segments_points_memory_in_bytes gauge elasticsearch_indices_segments_points_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_indices_segments_stored_fields_memory_in_bytes Count of stored fields memory # TYPE elasticsearch_indices_segments_stored_fields_memory_in_bytes gauge elasticsearch_indices_segments_stored_fields_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1560 # HELP elasticsearch_indices_segments_term_vectors_memory_in_bytes Term vectors memory usage in bytes # TYPE elasticsearch_indices_segments_term_vectors_memory_in_bytes gauge elasticsearch_indices_segments_term_vectors_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_segments_terms_memory_in_bytes Count of terms in memory for this node # TYPE elasticsearch_indices_segments_terms_memory_in_bytes gauge elasticsearch_indices_segments_terms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5945 # HELP elasticsearch_indices_segments_version_map_memory_in_bytes Version map memory usage in bytes # TYPE elasticsearch_indices_segments_version_map_memory_in_bytes gauge elasticsearch_indices_segments_version_map_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_store_size_bytes Current size of stored index data in bytes # TYPE elasticsearch_indices_store_size_bytes gauge elasticsearch_indices_store_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 7261 # HELP elasticsearch_indices_store_throttle_time_seconds_total Throttle time for index store in seconds # TYPE elasticsearch_indices_store_throttle_time_seconds_total counter elasticsearch_indices_store_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_translog_operations Total translog operations # TYPE elasticsearch_indices_translog_operations counter elasticsearch_indices_translog_operations{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_indices_translog_size_in_bytes Total translog size in bytes # TYPE elasticsearch_indices_translog_size_in_bytes gauge elasticsearch_indices_translog_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 3753 # HELP elasticsearch_indices_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_indices_warmer_time_seconds_total counter elasticsearch_indices_warmer_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_indices_warmer_total Total warmer count # TYPE elasticsearch_indices_warmer_total counter elasticsearch_indices_warmer_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 35 # HELP elasticsearch_jvm_buffer_pool_used_bytes JVM buffer currently used # TYPE elasticsearch_jvm_buffer_pool_used_bytes gauge elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="direct"} 1.68849056e+08 elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="mapped"} 15179 # HELP elasticsearch_jvm_gc_collection_seconds_count Count of JVM GC runs # TYPE elasticsearch_jvm_gc_collection_seconds_count counter elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="172.17.0.2",name="9_P7yui"} 5 # HELP elasticsearch_jvm_gc_collection_seconds_sum GC run time in seconds # TYPE elasticsearch_jvm_gc_collection_seconds_sum counter elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="172.17.0.2",name="9_P7yui"} 0 elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="172.17.0.2",name="9_P7yui"} 0.08 # HELP elasticsearch_jvm_memory_committed_bytes JVM memory currently committed by area # TYPE elasticsearch_jvm_memory_committed_bytes gauge elasticsearch_jvm_memory_committed_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.073741824e+09 elasticsearch_jvm_memory_committed_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.179648e+08 # HELP elasticsearch_jvm_memory_max_bytes JVM memory max # TYPE elasticsearch_jvm_memory_max_bytes gauge elasticsearch_jvm_memory_max_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.073741824e+09 # HELP elasticsearch_jvm_memory_pool_max_bytes JVM memory max by pool # TYPE elasticsearch_jvm_memory_pool_max_bytes counter elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="old"} 1.073741824e+09 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="survivor"} 0 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="young"} 0 # HELP elasticsearch_jvm_memory_pool_peak_max_bytes JVM memory peak max by pool # TYPE elasticsearch_jvm_memory_pool_peak_max_bytes counter elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="old"} 1.073741824e+09 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="survivor"} 0 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="young"} 0 # HELP elasticsearch_jvm_memory_pool_peak_used_bytes JVM memory peak used by pool # TYPE elasticsearch_jvm_memory_pool_peak_used_bytes counter elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="old"} 2.55827968e+08 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="survivor"} 4.766816e+07 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="young"} 5.59417344e+08 # HELP elasticsearch_jvm_memory_pool_used_bytes JVM memory currently used by pool # TYPE elasticsearch_jvm_memory_pool_used_bytes gauge elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="old"} 2.55827968e+08 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="survivor"} 1.1010048e+07 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",pool="young"} 3.93216e+08 # HELP elasticsearch_jvm_memory_used_bytes JVM memory currently used by area # TYPE elasticsearch_jvm_memory_used_bytes gauge elasticsearch_jvm_memory_used_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 6.60054016e+08 elasticsearch_jvm_memory_used_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.08594112e+08 # HELP elasticsearch_jvm_uptime_seconds JVM process uptime in seconds # TYPE elasticsearch_jvm_uptime_seconds gauge elasticsearch_jvm_uptime_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="mapped"} 16.456 # HELP elasticsearch_nodes_roles Node roles # TYPE elasticsearch_nodes_roles gauge elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="client"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data_cold"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data_content"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data_frozen"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data_hot"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="data_warm"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="ingest"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="master"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="ml"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="remote_cluster_client"} 0 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="9_P7yui",role="transform"} 0 # HELP elasticsearch_os_cpu_percent Percent CPU used by OS # TYPE elasticsearch_os_cpu_percent gauge elasticsearch_os_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 30 # HELP elasticsearch_os_load1 Shortterm load average # TYPE elasticsearch_os_load1 gauge elasticsearch_os_load1{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 27.55 # HELP elasticsearch_os_load15 Longterm load average # TYPE elasticsearch_os_load15 gauge elasticsearch_os_load15{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 92.65 # HELP elasticsearch_os_load5 Midterm load average # TYPE elasticsearch_os_load5 gauge elasticsearch_os_load5{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 134.28 # HELP elasticsearch_os_mem_actual_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_actual_free_bytes gauge elasticsearch_os_mem_actual_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_os_mem_actual_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_actual_used_bytes gauge elasticsearch_os_mem_actual_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_os_mem_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_free_bytes gauge elasticsearch_os_mem_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 7.651008512e+09 # HELP elasticsearch_os_mem_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_used_bytes gauge elasticsearch_os_mem_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 2.5972228096e+10 # HELP elasticsearch_process_cpu_percent Percent CPU used by process # TYPE elasticsearch_process_cpu_percent gauge elasticsearch_process_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 17 # HELP elasticsearch_process_cpu_seconds_total Process CPU time in seconds # TYPE elasticsearch_process_cpu_seconds_total counter elasticsearch_process_cpu_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 32.81 # HELP elasticsearch_process_max_files_descriptors Max file descriptors # TYPE elasticsearch_process_max_files_descriptors gauge elasticsearch_process_max_files_descriptors{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 1.048576e+06 # HELP elasticsearch_process_mem_resident_size_bytes Resident memory in use by process in bytes # TYPE elasticsearch_process_mem_resident_size_bytes gauge elasticsearch_process_mem_resident_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_process_mem_share_size_bytes Shared memory in use by process in bytes # TYPE elasticsearch_process_mem_share_size_bytes gauge elasticsearch_process_mem_share_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_process_mem_virtual_size_bytes Total virtual memory used in bytes # TYPE elasticsearch_process_mem_virtual_size_bytes gauge elasticsearch_process_mem_virtual_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 7.269961728e+09 # HELP elasticsearch_process_open_files_count Open file descriptors # TYPE elasticsearch_process_open_files_count gauge elasticsearch_process_open_files_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 355 # HELP elasticsearch_thread_pool_active_count Thread Pool threads active # TYPE elasticsearch_thread_pool_active_count gauge elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 1 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 0 # HELP elasticsearch_thread_pool_completed_count Thread Pool operations completed # TYPE elasticsearch_thread_pool_completed_count counter elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 87 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 5 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 5 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 1 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 32 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 5 # HELP elasticsearch_thread_pool_largest_count Thread Pool largest threads count # TYPE elasticsearch_thread_pool_largest_count gauge elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 5 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 4 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 2 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 5 # HELP elasticsearch_thread_pool_queue_count Thread Pool operations queued # TYPE elasticsearch_thread_pool_queue_count gauge elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 0 # HELP elasticsearch_thread_pool_rejected_count Thread Pool operations rejected # TYPE elasticsearch_thread_pool_rejected_count counter elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 0 # HELP elasticsearch_thread_pool_threads_count Thread Pool current threads count # TYPE elasticsearch_thread_pool_threads_count gauge elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="analyze"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ccr"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_started"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="fetch_shard_store"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="flush"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="force_merge"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="generic"} 5 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="get"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="index"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="listener"} 4 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="management"} 2 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_autodetect"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_datafeed"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="ml_utility"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="refresh"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="rollup_indexing"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="search_throttled"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="security-token-key"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="snapshot"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="warmer"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="watcher"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui",type="write"} 5 # HELP elasticsearch_transport_rx_packets_total Count of packets received # TYPE elasticsearch_transport_rx_packets_total counter elasticsearch_transport_rx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_transport_rx_size_bytes_total Total number of bytes received # TYPE elasticsearch_transport_rx_size_bytes_total counter elasticsearch_transport_rx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_transport_tx_packets_total Count of packets sent # TYPE elasticsearch_transport_tx_packets_total counter elasticsearch_transport_tx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 # HELP elasticsearch_transport_tx_size_bytes_total Total number of bytes sent # TYPE elasticsearch_transport_tx_size_bytes_total counter elasticsearch_transport_tx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="9_P7yui"} 0 `, }, { name: "7.13.1", file: "../fixtures/nodestats/7.13.1.json", want: `# HELP elasticsearch_breakers_estimated_size_bytes Estimated size in bytes of breaker # TYPE elasticsearch_breakers_estimated_size_bytes gauge elasticsearch_breakers_estimated_size_bytes{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 9380 elasticsearch_breakers_estimated_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="model_inference",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_estimated_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.56194432e+08 elasticsearch_breakers_estimated_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_breakers_limit_size_bytes Limit size in bytes for breaker # TYPE elasticsearch_breakers_limit_size_bytes gauge elasticsearch_breakers_limit_size_bytes{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 7.88529152e+08 elasticsearch_breakers_limit_size_bytes{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 3.1541166e+08 elasticsearch_breakers_limit_size_bytes{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 7.88529152e+08 elasticsearch_breakers_limit_size_bytes{breaker="model_inference",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 3.94264576e+08 elasticsearch_breakers_limit_size_bytes{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 7.49102694e+08 elasticsearch_breakers_limit_size_bytes{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 4.73117491e+08 # HELP elasticsearch_breakers_overhead Overhead of circuit breakers # TYPE elasticsearch_breakers_overhead counter elasticsearch_breakers_overhead{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1 elasticsearch_breakers_overhead{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.03 elasticsearch_breakers_overhead{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 2 elasticsearch_breakers_overhead{breaker="model_inference",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1 elasticsearch_breakers_overhead{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1 elasticsearch_breakers_overhead{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1 # HELP elasticsearch_breakers_tripped tripped for breaker # TYPE elasticsearch_breakers_tripped counter elasticsearch_breakers_tripped{breaker="accounting",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_tripped{breaker="fielddata",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_tripped{breaker="in_flight_requests",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_tripped{breaker="model_inference",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_tripped{breaker="parent",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_breakers_tripped{breaker="request",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_filesystem_data_available_bytes Available space on block device in bytes # TYPE elasticsearch_filesystem_data_available_bytes gauge elasticsearch_filesystem_data_available_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="aaf5a8a0bceb",path="/usr/share/elasticsearch/data/nodes/0"} 6.3425642496e+10 # HELP elasticsearch_filesystem_data_free_bytes Free space on block device in bytes # TYPE elasticsearch_filesystem_data_free_bytes gauge elasticsearch_filesystem_data_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="aaf5a8a0bceb",path="/usr/share/elasticsearch/data/nodes/0"} 6.3425642496e+10 # HELP elasticsearch_filesystem_data_size_bytes Size of block device in bytes # TYPE elasticsearch_filesystem_data_size_bytes gauge elasticsearch_filesystem_data_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",mount="/ (overlay)",name="aaf5a8a0bceb",path="/usr/share/elasticsearch/data/nodes/0"} 4.76630163456e+11 # HELP elasticsearch_indexing_pressure_current_all_in_bytes Memory consumed, in bytes, by indexing requests in the coordinating, primary, or replica stage. # TYPE elasticsearch_indexing_pressure_current_all_in_bytes gauge elasticsearch_indexing_pressure_current_all_in_bytes{cluster="elasticsearch",host="172.17.0.2",indexing_pressure="memory",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indexing_pressure_limit_in_bytes Configured memory limit, in bytes, for the indexing requests # TYPE elasticsearch_indexing_pressure_limit_in_bytes gauge elasticsearch_indexing_pressure_limit_in_bytes{cluster="elasticsearch",host="172.17.0.2",indexing_pressure="memory",name="aaf5a8a0bceb"} 7.8852915e+07 # HELP elasticsearch_indices_completion_size_in_bytes Completion in bytes # TYPE elasticsearch_indices_completion_size_in_bytes counter elasticsearch_indices_completion_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_docs Count of documents on this node # TYPE elasticsearch_indices_docs gauge elasticsearch_indices_docs{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 5 # HELP elasticsearch_indices_docs_deleted Count of deleted documents on this node # TYPE elasticsearch_indices_docs_deleted gauge elasticsearch_indices_docs_deleted{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_fielddata_evictions Evictions from field data # TYPE elasticsearch_indices_fielddata_evictions counter elasticsearch_indices_fielddata_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_fielddata_memory_size_bytes Field data cache memory usage in bytes # TYPE elasticsearch_indices_fielddata_memory_size_bytes gauge elasticsearch_indices_fielddata_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_filter_cache_evictions Evictions from filter cache # TYPE elasticsearch_indices_filter_cache_evictions counter elasticsearch_indices_filter_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_filter_cache_memory_size_bytes Filter cache memory usage in bytes # TYPE elasticsearch_indices_filter_cache_memory_size_bytes gauge elasticsearch_indices_filter_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_flush_time_seconds Cumulative flush time in seconds # TYPE elasticsearch_indices_flush_time_seconds counter elasticsearch_indices_flush_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_flush_total Total flushes # TYPE elasticsearch_indices_flush_total counter elasticsearch_indices_flush_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_exists_time_seconds Total time get exists in seconds # TYPE elasticsearch_indices_get_exists_time_seconds counter elasticsearch_indices_get_exists_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_exists_total Total get exists operations # TYPE elasticsearch_indices_get_exists_total counter elasticsearch_indices_get_exists_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_missing_time_seconds Total time of get missing in seconds # TYPE elasticsearch_indices_get_missing_time_seconds counter elasticsearch_indices_get_missing_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_missing_total Total get missing # TYPE elasticsearch_indices_get_missing_total counter elasticsearch_indices_get_missing_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_time_seconds Total get time in seconds # TYPE elasticsearch_indices_get_time_seconds counter elasticsearch_indices_get_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_get_total Total get # TYPE elasticsearch_indices_get_total counter elasticsearch_indices_get_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_indexing_delete_time_seconds_total Total time indexing delete in seconds # TYPE elasticsearch_indices_indexing_delete_time_seconds_total counter elasticsearch_indices_indexing_delete_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_indexing_delete_total Total indexing deletes # TYPE elasticsearch_indices_indexing_delete_total counter elasticsearch_indices_indexing_delete_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_indexing_index_time_seconds_total Cumulative index time in seconds # TYPE elasticsearch_indices_indexing_index_time_seconds_total counter elasticsearch_indices_indexing_index_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0.014 # HELP elasticsearch_indices_indexing_index_total Total index calls # TYPE elasticsearch_indices_indexing_index_total counter elasticsearch_indices_indexing_index_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 5 # HELP elasticsearch_indices_indexing_is_throttled Indexing throttling # TYPE elasticsearch_indices_indexing_is_throttled gauge elasticsearch_indices_indexing_is_throttled{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_indexing_throttle_time_seconds_total Cumulative indexing throttling time # TYPE elasticsearch_indices_indexing_throttle_time_seconds_total counter elasticsearch_indices_indexing_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_current Current merges # TYPE elasticsearch_indices_merges_current gauge elasticsearch_indices_merges_current{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_current_size_in_bytes Size of a current merges in bytes # TYPE elasticsearch_indices_merges_current_size_in_bytes gauge elasticsearch_indices_merges_current_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_docs_total Cumulative docs merged # TYPE elasticsearch_indices_merges_docs_total counter elasticsearch_indices_merges_docs_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_total Total merges # TYPE elasticsearch_indices_merges_total counter elasticsearch_indices_merges_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_total_size_bytes_total Total merge size in bytes # TYPE elasticsearch_indices_merges_total_size_bytes_total counter elasticsearch_indices_merges_total_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_total_throttled_time_seconds_total Total throttled time of merges in seconds # TYPE elasticsearch_indices_merges_total_throttled_time_seconds_total counter elasticsearch_indices_merges_total_throttled_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_merges_total_time_seconds_total Total time spent merging in seconds # TYPE elasticsearch_indices_merges_total_time_seconds_total counter elasticsearch_indices_merges_total_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_cache_size Query cache cache size # TYPE elasticsearch_indices_query_cache_cache_size gauge elasticsearch_indices_query_cache_cache_size{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_cache_total Query cache cache count # TYPE elasticsearch_indices_query_cache_cache_total counter elasticsearch_indices_query_cache_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_count Query cache count # TYPE elasticsearch_indices_query_cache_count counter elasticsearch_indices_query_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_evictions Evictions from query cache # TYPE elasticsearch_indices_query_cache_evictions counter elasticsearch_indices_query_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_memory_size_bytes Query cache memory usage in bytes # TYPE elasticsearch_indices_query_cache_memory_size_bytes gauge elasticsearch_indices_query_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_cache_total Query cache total count # TYPE elasticsearch_indices_query_cache_total counter elasticsearch_indices_query_cache_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_query_miss_count Query miss count # TYPE elasticsearch_indices_query_miss_count counter elasticsearch_indices_query_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_refresh_external_time_seconds_total Total time spent external refreshing in seconds # TYPE elasticsearch_indices_refresh_external_time_seconds_total counter elasticsearch_indices_refresh_external_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0.15 # HELP elasticsearch_indices_refresh_external_total Total external refreshes # TYPE elasticsearch_indices_refresh_external_total counter elasticsearch_indices_refresh_external_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 17 # HELP elasticsearch_indices_refresh_time_seconds_total Total time spent refreshing in seconds # TYPE elasticsearch_indices_refresh_time_seconds_total counter elasticsearch_indices_refresh_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0.148 # HELP elasticsearch_indices_refresh_total Total refreshes # TYPE elasticsearch_indices_refresh_total counter elasticsearch_indices_refresh_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 17 # HELP elasticsearch_indices_request_cache_count Request cache count # TYPE elasticsearch_indices_request_cache_count counter elasticsearch_indices_request_cache_count{cache="hit",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_request_cache_evictions Evictions from request cache # TYPE elasticsearch_indices_request_cache_evictions counter elasticsearch_indices_request_cache_evictions{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_request_cache_memory_size_bytes Request cache memory usage in bytes # TYPE elasticsearch_indices_request_cache_memory_size_bytes gauge elasticsearch_indices_request_cache_memory_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_request_miss_count Request miss count # TYPE elasticsearch_indices_request_miss_count counter elasticsearch_indices_request_miss_count{cache="miss",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_fetch_time_seconds Total search fetch time in seconds # TYPE elasticsearch_indices_search_fetch_time_seconds counter elasticsearch_indices_search_fetch_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_fetch_total Total number of fetches # TYPE elasticsearch_indices_search_fetch_total counter elasticsearch_indices_search_fetch_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_query_time_seconds Total search query time in seconds # TYPE elasticsearch_indices_search_query_time_seconds counter elasticsearch_indices_search_query_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_query_total Total number of queries # TYPE elasticsearch_indices_search_query_total counter elasticsearch_indices_search_query_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_scroll_time_seconds Total scroll time in seconds # TYPE elasticsearch_indices_search_scroll_time_seconds counter elasticsearch_indices_search_scroll_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_scroll_total Total number of scrolls # TYPE elasticsearch_indices_search_scroll_total counter elasticsearch_indices_search_scroll_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_suggest_time_seconds Total suggest time in seconds # TYPE elasticsearch_indices_search_suggest_time_seconds counter elasticsearch_indices_search_suggest_time_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_search_suggest_total Total number of suggests # TYPE elasticsearch_indices_search_suggest_total counter elasticsearch_indices_search_suggest_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_segments_count Count of index segments on this node # TYPE elasticsearch_indices_segments_count gauge elasticsearch_indices_segments_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 5 # HELP elasticsearch_indices_segments_doc_values_memory_in_bytes Count of doc values memory # TYPE elasticsearch_indices_segments_doc_values_memory_in_bytes gauge elasticsearch_indices_segments_doc_values_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 380 # HELP elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes Count of fixed bit set # TYPE elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes gauge elasticsearch_indices_segments_fixed_bit_set_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_segments_index_writer_memory_in_bytes Count of memory for index writer on this node # TYPE elasticsearch_indices_segments_index_writer_memory_in_bytes gauge elasticsearch_indices_segments_index_writer_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_segments_memory_bytes Current memory size of segments in bytes # TYPE elasticsearch_indices_segments_memory_bytes gauge elasticsearch_indices_segments_memory_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 9380 # HELP elasticsearch_indices_segments_norms_memory_in_bytes Count of memory used by norms # TYPE elasticsearch_indices_segments_norms_memory_in_bytes gauge elasticsearch_indices_segments_norms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 640 # HELP elasticsearch_indices_segments_points_memory_in_bytes Point values memory usage in bytes # TYPE elasticsearch_indices_segments_points_memory_in_bytes gauge elasticsearch_indices_segments_points_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_segments_stored_fields_memory_in_bytes Count of stored fields memory # TYPE elasticsearch_indices_segments_stored_fields_memory_in_bytes gauge elasticsearch_indices_segments_stored_fields_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 2440 # HELP elasticsearch_indices_segments_term_vectors_memory_in_bytes Term vectors memory usage in bytes # TYPE elasticsearch_indices_segments_term_vectors_memory_in_bytes gauge elasticsearch_indices_segments_term_vectors_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_segments_terms_memory_in_bytes Count of terms in memory for this node # TYPE elasticsearch_indices_segments_terms_memory_in_bytes gauge elasticsearch_indices_segments_terms_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 5920 # HELP elasticsearch_indices_segments_version_map_memory_in_bytes Version map memory usage in bytes # TYPE elasticsearch_indices_segments_version_map_memory_in_bytes gauge elasticsearch_indices_segments_version_map_memory_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_store_size_bytes Current size of stored index data in bytes # TYPE elasticsearch_indices_store_size_bytes gauge elasticsearch_indices_store_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 22296 # HELP elasticsearch_indices_store_throttle_time_seconds_total Throttle time for index store in seconds # TYPE elasticsearch_indices_store_throttle_time_seconds_total counter elasticsearch_indices_store_throttle_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_translog_operations Total translog operations # TYPE elasticsearch_indices_translog_operations counter elasticsearch_indices_translog_operations{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 5 # HELP elasticsearch_indices_translog_size_in_bytes Total translog size in bytes # TYPE elasticsearch_indices_translog_size_in_bytes gauge elasticsearch_indices_translog_size_in_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 773 # HELP elasticsearch_indices_warmer_time_seconds_total Total warmer time in seconds # TYPE elasticsearch_indices_warmer_time_seconds_total counter elasticsearch_indices_warmer_time_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_indices_warmer_total Total warmer count # TYPE elasticsearch_indices_warmer_total counter elasticsearch_indices_warmer_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 11 # HELP elasticsearch_jvm_buffer_pool_used_bytes JVM buffer currently used # TYPE elasticsearch_jvm_buffer_pool_used_bytes gauge elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="direct"} 8.811046e+06 elasticsearch_jvm_buffer_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="mapped"} 16868 # HELP elasticsearch_jvm_gc_collection_seconds_count Count of JVM GC runs # TYPE elasticsearch_jvm_gc_collection_seconds_count counter elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_jvm_gc_collection_seconds_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="172.17.0.2",name="aaf5a8a0bceb"} 11 # HELP elasticsearch_jvm_gc_collection_seconds_sum GC run time in seconds # TYPE elasticsearch_jvm_gc_collection_seconds_sum counter elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="old",host="172.17.0.2",name="aaf5a8a0bceb"} 0 elasticsearch_jvm_gc_collection_seconds_sum{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",gc="young",host="172.17.0.2",name="aaf5a8a0bceb"} 0.113 # HELP elasticsearch_jvm_memory_committed_bytes JVM memory currently committed by area # TYPE elasticsearch_jvm_memory_committed_bytes gauge elasticsearch_jvm_memory_committed_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 7.88529152e+08 elasticsearch_jvm_memory_committed_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.42606336e+08 # HELP elasticsearch_jvm_memory_max_bytes JVM memory max # TYPE elasticsearch_jvm_memory_max_bytes gauge elasticsearch_jvm_memory_max_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 7.88529152e+08 # HELP elasticsearch_jvm_memory_pool_max_bytes JVM memory max by pool # TYPE elasticsearch_jvm_memory_pool_max_bytes counter elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="old"} 7.88529152e+08 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="survivor"} 0 elasticsearch_jvm_memory_pool_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="young"} 0 # HELP elasticsearch_jvm_memory_pool_peak_max_bytes JVM memory peak max by pool # TYPE elasticsearch_jvm_memory_pool_peak_max_bytes counter elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="old"} 7.88529152e+08 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="survivor"} 0 elasticsearch_jvm_memory_pool_peak_max_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="young"} 0 # HELP elasticsearch_jvm_memory_pool_peak_used_bytes JVM memory peak used by pool # TYPE elasticsearch_jvm_memory_pool_peak_used_bytes counter elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="old"} 7.1059968e+07 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="survivor"} 5.4525952e+07 elasticsearch_jvm_memory_pool_peak_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="young"} 4.65567744e+08 # HELP elasticsearch_jvm_memory_pool_used_bytes JVM memory currently used by pool # TYPE elasticsearch_jvm_memory_pool_used_bytes gauge elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="old"} 7.1059968e+07 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="survivor"} 3.0608512e+07 elasticsearch_jvm_memory_pool_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",pool="young"} 5.4525952e+07 # HELP elasticsearch_jvm_memory_used_bytes JVM memory currently used by area # TYPE elasticsearch_jvm_memory_used_bytes gauge elasticsearch_jvm_memory_used_bytes{area="heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.56194432e+08 elasticsearch_jvm_memory_used_bytes{area="non-heap",cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.39526472e+08 # HELP elasticsearch_jvm_uptime_seconds JVM process uptime in seconds # TYPE elasticsearch_jvm_uptime_seconds gauge elasticsearch_jvm_uptime_seconds{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="mapped"} 21.844 # HELP elasticsearch_nodes_roles Node roles # TYPE elasticsearch_nodes_roles gauge elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="client"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data_cold"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data_content"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data_frozen"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data_hot"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="data_warm"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="ingest"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="master"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="ml"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="remote_cluster_client"} 1 elasticsearch_nodes_roles{cluster="elasticsearch",host="172.17.0.2",name="aaf5a8a0bceb",role="transform"} 1 # HELP elasticsearch_os_cpu_percent Percent CPU used by OS # TYPE elasticsearch_os_cpu_percent gauge elasticsearch_os_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 37 # HELP elasticsearch_os_load1 Shortterm load average # TYPE elasticsearch_os_load1 gauge elasticsearch_os_load1{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 2.74 # HELP elasticsearch_os_load15 Longterm load average # TYPE elasticsearch_os_load15 gauge elasticsearch_os_load15{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 70.55 # HELP elasticsearch_os_load5 Midterm load average # TYPE elasticsearch_os_load5 gauge elasticsearch_os_load5{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 44.07 # HELP elasticsearch_os_mem_actual_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_actual_free_bytes gauge elasticsearch_os_mem_actual_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_os_mem_actual_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_actual_used_bytes gauge elasticsearch_os_mem_actual_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_os_mem_free_bytes Amount of free physical memory in bytes # TYPE elasticsearch_os_mem_free_bytes gauge elasticsearch_os_mem_free_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.24007424e+10 # HELP elasticsearch_os_mem_used_bytes Amount of used physical memory in bytes # TYPE elasticsearch_os_mem_used_bytes gauge elasticsearch_os_mem_used_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 2.1222490112e+10 # HELP elasticsearch_process_cpu_percent Percent CPU used by process # TYPE elasticsearch_process_cpu_percent gauge elasticsearch_process_cpu_percent{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 19 # HELP elasticsearch_process_cpu_seconds_total Process CPU time in seconds # TYPE elasticsearch_process_cpu_seconds_total counter elasticsearch_process_cpu_seconds_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 50.16 # HELP elasticsearch_process_max_files_descriptors Max file descriptors # TYPE elasticsearch_process_max_files_descriptors gauge elasticsearch_process_max_files_descriptors{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 1.048576e+06 # HELP elasticsearch_process_mem_resident_size_bytes Resident memory in use by process in bytes # TYPE elasticsearch_process_mem_resident_size_bytes gauge elasticsearch_process_mem_resident_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_process_mem_share_size_bytes Shared memory in use by process in bytes # TYPE elasticsearch_process_mem_share_size_bytes gauge elasticsearch_process_mem_share_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_process_mem_virtual_size_bytes Total virtual memory used in bytes # TYPE elasticsearch_process_mem_virtual_size_bytes gauge elasticsearch_process_mem_virtual_size_bytes{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 6.819479552e+09 # HELP elasticsearch_process_open_files_count Open file descriptors # TYPE elasticsearch_process_open_files_count gauge elasticsearch_process_open_files_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 314 # HELP elasticsearch_thread_pool_active_count Thread Pool threads active # TYPE elasticsearch_thread_pool_active_count gauge elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 1 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_active_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 0 # HELP elasticsearch_thread_pool_completed_count Thread Pool operations completed # TYPE elasticsearch_thread_pool_completed_count counter elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 406 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 9 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 12 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 36 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_completed_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 9 # HELP elasticsearch_thread_pool_largest_count Thread Pool largest threads count # TYPE elasticsearch_thread_pool_largest_count gauge elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 7 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 2 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 1 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_largest_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 8 # HELP elasticsearch_thread_pool_queue_count Thread Pool operations queued # TYPE elasticsearch_thread_pool_queue_count gauge elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_queue_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 0 # HELP elasticsearch_thread_pool_rejected_count Thread Pool operations rejected # TYPE elasticsearch_thread_pool_rejected_count counter elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_rejected_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 0 # HELP elasticsearch_thread_pool_threads_count Thread Pool current threads count # TYPE elasticsearch_thread_pool_threads_count gauge elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="analyze"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ccr"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_started"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="fetch_shard_store"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="flush"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="force_merge"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="generic"} 7 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="get"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="listener"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="management"} 2 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_datafeed"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_job_comms"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="ml_utility"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="refresh"} 1 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="rollup_indexing"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="search_throttled"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_fetch_async"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="searchable_snapshots_cache_prewarming"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-crypto"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="security-token-key"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="snapshot"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_read"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="system_write"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="transform_indexing"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="warmer"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="watcher"} 0 elasticsearch_thread_pool_threads_count{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb",type="write"} 8 # HELP elasticsearch_transport_rx_packets_total Count of packets received # TYPE elasticsearch_transport_rx_packets_total counter elasticsearch_transport_rx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_transport_rx_size_bytes_total Total number of bytes received # TYPE elasticsearch_transport_rx_size_bytes_total counter elasticsearch_transport_rx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_transport_tx_packets_total Count of packets sent # TYPE elasticsearch_transport_tx_packets_total counter elasticsearch_transport_tx_packets_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 # HELP elasticsearch_transport_tx_size_bytes_total Total number of bytes sent # TYPE elasticsearch_transport_tx_size_bytes_total counter elasticsearch_transport_tx_size_bytes_total{cluster="elasticsearch",es_client_node="true",es_data_node="true",es_ingest_node="true",es_master_node="true",host="172.17.0.2",name="aaf5a8a0bceb"} 0 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c := NewNodes(promslog.NewNopLogger(), http.DefaultClient, u, true, "_local") if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(c, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/shards.go000066400000000000000000000140471511562765300242640ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "encoding/json" "fmt" "log/slog" "net/http" "net/url" "path" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus-community/elasticsearch_exporter/pkg/clusterinfo" ) // ShardResponse has shard's node and index info type ShardResponse struct { Index string `json:"index"` Shard string `json:"shard"` State string `json:"state"` Node string `json:"node"` } // Shards information struct type Shards struct { logger *slog.Logger client *http.Client url *url.URL clusterInfoCh chan *clusterinfo.Response lastClusterInfo *clusterinfo.Response nodeShardMetrics []*nodeShardMetric jsonParseFailures prometheus.Counter } // ClusterLabelUpdates returns a pointer to a channel to receive cluster info updates. It implements the // (not exported) clusterinfo.consumer interface func (s *Shards) ClusterLabelUpdates() *chan *clusterinfo.Response { return &s.clusterInfoCh } // String implements the stringer interface. It is part of the clusterinfo.consumer interface func (s *Shards) String() string { return namespace + "shards" } type nodeShardMetric struct { Type prometheus.ValueType Desc *prometheus.Desc Value func(shards float64) float64 Labels labels } // fetchClusterNameOnce performs a single request to the root endpoint to obtain the cluster name. func fetchClusterNameOnce(s *Shards) string { if s.lastClusterInfo != nil && s.lastClusterInfo.ClusterName != "unknown_cluster" { return s.lastClusterInfo.ClusterName } u := *s.url u.Path = path.Join(u.Path, "/") resp, err := s.client.Get(u.String()) if err == nil { defer resp.Body.Close() if resp.StatusCode == http.StatusOK { var root struct { ClusterName string `json:"cluster_name"` } if err := json.NewDecoder(resp.Body).Decode(&root); err == nil && root.ClusterName != "" { s.lastClusterInfo = &clusterinfo.Response{ClusterName: root.ClusterName} return root.ClusterName } } } return "unknown_cluster" } // NewShards defines Shards Prometheus metrics func NewShards(logger *slog.Logger, client *http.Client, url *url.URL) *Shards { var shardPtr *Shards nodeLabels := labels{ keys: func(...string) []string { return []string{"node", "cluster"} }, values: func(lastClusterinfo *clusterinfo.Response, base ...string) []string { if lastClusterinfo != nil { return append(base, lastClusterinfo.ClusterName) } if shardPtr != nil { return append(base, fetchClusterNameOnce(shardPtr)) } return append(base, "unknown_cluster") }, } shards := &Shards{ // will assign later logger: logger, client: client, url: url, clusterInfoCh: make(chan *clusterinfo.Response), lastClusterInfo: &clusterinfo.Response{ ClusterName: "unknown_cluster", }, nodeShardMetrics: []*nodeShardMetric{ { Type: prometheus.GaugeValue, Desc: prometheus.NewDesc( prometheus.BuildFQName(namespace, "node_shards", "total"), "Total shards per node", nodeLabels.keys(), nil, ), Value: func(shards float64) float64 { return shards }, Labels: nodeLabels, }, }, jsonParseFailures: prometheus.NewCounter(prometheus.CounterOpts{ Name: prometheus.BuildFQName(namespace, "node_shards", "json_parse_failures"), Help: "Number of errors while parsing JSON.", }), } // start go routine to fetch clusterinfo updates and save them to lastClusterinfo go func() { logger.Debug("starting cluster info receive loop") for ci := range shards.clusterInfoCh { if ci != nil { logger.Debug("received cluster info update", "cluster", ci.ClusterName) shards.lastClusterInfo = ci } } logger.Debug("exiting cluster info receive loop") }() shardPtr = shards return shards } // Describe Shards func (s *Shards) Describe(ch chan<- *prometheus.Desc) { ch <- s.jsonParseFailures.Desc() for _, metric := range s.nodeShardMetrics { ch <- metric.Desc } } func (s *Shards) getAndParseURL(u *url.URL) ([]ShardResponse, error) { res, err := s.client.Get(u.String()) if err != nil { return nil, fmt.Errorf("failed to get from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } defer func() { err = res.Body.Close() if err != nil { s.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return nil, fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } var sfr []ShardResponse if err := json.NewDecoder(res.Body).Decode(&sfr); err != nil { s.jsonParseFailures.Inc() return nil, err } return sfr, nil } func (s *Shards) fetchAndDecodeShards() ([]ShardResponse, error) { u := *s.url u.Path = path.Join(u.Path, "/_cat/shards") q := u.Query() q.Set("format", "json") u.RawQuery = q.Encode() sfr, err := s.getAndParseURL(&u) if err != nil { return sfr, err } return sfr, err } // Collect number of shards on each node func (s *Shards) Collect(ch chan<- prometheus.Metric) { defer func() { ch <- s.jsonParseFailures }() sr, err := s.fetchAndDecodeShards() if err != nil { s.logger.Warn( "failed to fetch and decode node shards stats", "err", err, ) return } nodeShards := make(map[string]float64) for _, shard := range sr { if shard.State == "STARTED" { nodeShards[shard.Node]++ } } for node, shards := range nodeShards { for _, metric := range s.nodeShardMetrics { ch <- prometheus.MustNewConstMetric( metric.Desc, metric.Type, metric.Value(shards), metric.Labels.values(s.lastClusterInfo, node)..., ) } } } prometheus-elasticsearch-exporter-1.10.0/collector/shards_test.go000066400000000000000000000045661511562765300253300ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "path" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestShards(t *testing.T) { // Testcases created using: // docker run --rm -d -p 9200:9200 -e "discovery.type=single-node" docker.elastic.co/elasticsearch/elasticsearch:$VERSION // curl -XPUT http://localhost:9200/testindex // curl -XPUT http://localhost:9200/otherindex // curl http://localhost:9200/_cat/shards?format=json > fixtures/shards/$VERSION.json tests := []struct { name string file string want string }{ { name: "7.15.0", file: "7.15.0.json", want: `# HELP elasticsearch_node_shards_json_parse_failures Number of errors while parsing JSON. # TYPE elasticsearch_node_shards_json_parse_failures counter elasticsearch_node_shards_json_parse_failures 0 # HELP elasticsearch_node_shards_total Total shards per node # TYPE elasticsearch_node_shards_total gauge elasticsearch_node_shards_total{cluster="unknown_cluster",node="35dfca79831a"} 3 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(path.Join("../fixtures/shards/", tt.file)) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatalf("Failed to parse URL: %s", err) } s := NewShards(promslog.NewNopLogger(), http.DefaultClient, u) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(s, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/slm.go000066400000000000000000000165611511562765300235760ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "log/slog" "net/http" "net/url" "github.com/prometheus/client_golang/prometheus" ) var statuses = []string{"RUNNING", "STOPPING", "STOPPED"} var ( slmRetentionRunsTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "retention_runs_total"), "Total retention runs", nil, nil, ) slmRetentionFailedTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "retention_failed_total"), "Total failed retention runs", nil, nil, ) slmRetentionTimedOutTotal = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "retention_timed_out_total"), "Total timed out retention runs", nil, nil, ) slmRetentionDeletionTimeSeconds = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "retention_deletion_time_seconds"), "Retention run deletion time", nil, nil, ) slmTotalSnapshotsTaken = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "total_snapshots_taken_total"), "Total snapshots taken", nil, nil, ) slmTotalSnapshotsFailed = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "total_snapshots_failed_total"), "Total snapshots failed", nil, nil, ) slmTotalSnapshotsDeleted = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "total_snapshots_deleted_total"), "Total snapshots deleted", nil, nil, ) slmTotalSnapshotsDeleteFailed = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "total_snapshot_deletion_failures_total"), "Total snapshot deletion failures", nil, nil, ) slmOperationMode = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "operation_mode"), "Operating status of SLM", []string{"operation_mode"}, nil, ) slmSnapshotsTaken = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "snapshots_taken_total"), "Total snapshots taken", []string{"policy"}, nil, ) slmSnapshotsFailed = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "snapshots_failed_total"), "Total snapshots failed", []string{"policy"}, nil, ) slmSnapshotsDeleted = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "snapshots_deleted_total"), "Total snapshots deleted", []string{"policy"}, nil, ) slmSnapshotsDeletionFailure = prometheus.NewDesc( prometheus.BuildFQName(namespace, "slm_stats", "snapshot_deletion_failures_total"), "Total snapshot deletion failures", []string{"policy"}, nil, ) ) func init() { registerCollector("slm", defaultDisabled, NewSLM) } // SLM information struct type SLM struct { logger *slog.Logger hc *http.Client u *url.URL } // NewSLM defines SLM Prometheus metrics func NewSLM(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &SLM{ logger: logger, hc: hc, u: u, }, nil } // SLMStatsResponse is a representation of the SLM stats type SLMStatsResponse struct { RetentionRuns int64 `json:"retention_runs"` RetentionFailed int64 `json:"retention_failed"` RetentionTimedOut int64 `json:"retention_timed_out"` RetentionDeletionTime string `json:"retention_deletion_time"` RetentionDeletionTimeMillis int64 `json:"retention_deletion_time_millis"` TotalSnapshotsTaken int64 `json:"total_snapshots_taken"` TotalSnapshotsFailed int64 `json:"total_snapshots_failed"` TotalSnapshotsDeleted int64 `json:"total_snapshots_deleted"` TotalSnapshotDeletionFailures int64 `json:"total_snapshot_deletion_failures"` PolicyStats []PolicyStats `json:"policy_stats"` } // PolicyStats is a representation of SLM stats for specific policies type PolicyStats struct { Policy string `json:"policy"` SnapshotsTaken int64 `json:"snapshots_taken"` SnapshotsFailed int64 `json:"snapshots_failed"` SnapshotsDeleted int64 `json:"snapshots_deleted"` SnapshotDeletionFailures int64 `json:"snapshot_deletion_failures"` } // SLMStatusResponse is a representation of the SLM status type SLMStatusResponse struct { OperationMode string `json:"operation_mode"` } func (s *SLM) Update(ctx context.Context, ch chan<- prometheus.Metric) error { u := s.u.ResolveReference(&url.URL{Path: "/_slm/status"}) var slmStatusResp SLMStatusResponse resp, err := getURL(ctx, s.hc, s.logger, u.String()) if err != nil { return err } err = json.Unmarshal(resp, &slmStatusResp) if err != nil { return err } u = s.u.ResolveReference(&url.URL{Path: "/_slm/stats"}) var slmStatsResp SLMStatsResponse resp, err = getURL(ctx, s.hc, s.logger, u.String()) if err != nil { return err } err = json.Unmarshal(resp, &slmStatsResp) if err != nil { return err } for _, status := range statuses { var value float64 if slmStatusResp.OperationMode == status { value = 1 } ch <- prometheus.MustNewConstMetric( slmOperationMode, prometheus.GaugeValue, value, status, ) } ch <- prometheus.MustNewConstMetric( slmRetentionRunsTotal, prometheus.CounterValue, float64(slmStatsResp.RetentionRuns), ) ch <- prometheus.MustNewConstMetric( slmRetentionFailedTotal, prometheus.CounterValue, float64(slmStatsResp.RetentionFailed), ) ch <- prometheus.MustNewConstMetric( slmRetentionTimedOutTotal, prometheus.CounterValue, float64(slmStatsResp.RetentionTimedOut), ) ch <- prometheus.MustNewConstMetric( slmRetentionDeletionTimeSeconds, prometheus.GaugeValue, float64(slmStatsResp.RetentionDeletionTimeMillis)/1000, ) ch <- prometheus.MustNewConstMetric( slmTotalSnapshotsTaken, prometheus.CounterValue, float64(slmStatsResp.TotalSnapshotsTaken), ) ch <- prometheus.MustNewConstMetric( slmTotalSnapshotsFailed, prometheus.CounterValue, float64(slmStatsResp.TotalSnapshotsFailed), ) ch <- prometheus.MustNewConstMetric( slmTotalSnapshotsDeleted, prometheus.CounterValue, float64(slmStatsResp.TotalSnapshotsDeleted), ) ch <- prometheus.MustNewConstMetric( slmTotalSnapshotsDeleteFailed, prometheus.CounterValue, float64(slmStatsResp.TotalSnapshotDeletionFailures), ) for _, policy := range slmStatsResp.PolicyStats { ch <- prometheus.MustNewConstMetric( slmSnapshotsTaken, prometheus.CounterValue, float64(policy.SnapshotsTaken), policy.Policy, ) ch <- prometheus.MustNewConstMetric( slmSnapshotsFailed, prometheus.CounterValue, float64(policy.SnapshotsFailed), policy.Policy, ) ch <- prometheus.MustNewConstMetric( slmSnapshotsDeleted, prometheus.CounterValue, float64(policy.SnapshotsDeleted), policy.Policy, ) ch <- prometheus.MustNewConstMetric( slmSnapshotsDeletionFailure, prometheus.CounterValue, float64(policy.SnapshotDeletionFailures), policy.Policy, ) } return nil } prometheus-elasticsearch-exporter-1.10.0/collector/slm_test.go000066400000000000000000000137361511562765300246360ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "io" "net/http" "net/http/httptest" "net/url" "os" "path" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestSLM(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 -e discovery.type=single-node -e path.repo=/tmp/backups docker.elastic.co/elasticsearch/elasticsearch:7.15.0-arm64 // curl -XPUT http://127.0.0.1:9200/_snapshot/my_repository -H 'Content-Type: application/json' -d '{"type":"url","settings":{"url":"file:/tmp/backups"}}' // curl -XPUT http://127.0.0.1:9200/_slm/policy/everything -H 'Content-Type: application/json' -d '{"schedule":"0 */15 * * * ?","name":"","repository":"my_repository","config":{"indices":".*","include_global_state":true,"ignore_unavailable":true},"retention":{"expire_after":"7d"}}' // curl http://127.0.0.1:9200/_slm/stats (Numbers manually tweaked) tests := []struct { name string file string want string }{ { name: "7.15.0", file: "7.15.0.json", want: `# HELP elasticsearch_slm_stats_operation_mode Operating status of SLM # TYPE elasticsearch_slm_stats_operation_mode gauge elasticsearch_slm_stats_operation_mode{operation_mode="RUNNING"} 0 elasticsearch_slm_stats_operation_mode{operation_mode="STOPPED"} 0 elasticsearch_slm_stats_operation_mode{operation_mode="STOPPING"} 0 # HELP elasticsearch_slm_stats_retention_deletion_time_seconds Retention run deletion time # TYPE elasticsearch_slm_stats_retention_deletion_time_seconds gauge elasticsearch_slm_stats_retention_deletion_time_seconds 72.491 # HELP elasticsearch_slm_stats_retention_failed_total Total failed retention runs # TYPE elasticsearch_slm_stats_retention_failed_total counter elasticsearch_slm_stats_retention_failed_total 0 # HELP elasticsearch_slm_stats_retention_runs_total Total retention runs # TYPE elasticsearch_slm_stats_retention_runs_total counter elasticsearch_slm_stats_retention_runs_total 9 # HELP elasticsearch_slm_stats_retention_timed_out_total Total timed out retention runs # TYPE elasticsearch_slm_stats_retention_timed_out_total counter elasticsearch_slm_stats_retention_timed_out_total 0 # HELP elasticsearch_slm_stats_snapshot_deletion_failures_total Total snapshot deletion failures # TYPE elasticsearch_slm_stats_snapshot_deletion_failures_total counter elasticsearch_slm_stats_snapshot_deletion_failures_total{policy="everything"} 0 # HELP elasticsearch_slm_stats_snapshots_deleted_total Total snapshots deleted # TYPE elasticsearch_slm_stats_snapshots_deleted_total counter elasticsearch_slm_stats_snapshots_deleted_total{policy="everything"} 20 # HELP elasticsearch_slm_stats_snapshots_failed_total Total snapshots failed # TYPE elasticsearch_slm_stats_snapshots_failed_total counter elasticsearch_slm_stats_snapshots_failed_total{policy="everything"} 2 # HELP elasticsearch_slm_stats_snapshots_taken_total Total snapshots taken # TYPE elasticsearch_slm_stats_snapshots_taken_total counter elasticsearch_slm_stats_snapshots_taken_total{policy="everything"} 50 # HELP elasticsearch_slm_stats_total_snapshot_deletion_failures_total Total snapshot deletion failures # TYPE elasticsearch_slm_stats_total_snapshot_deletion_failures_total counter elasticsearch_slm_stats_total_snapshot_deletion_failures_total 0 # HELP elasticsearch_slm_stats_total_snapshots_deleted_total Total snapshots deleted # TYPE elasticsearch_slm_stats_total_snapshots_deleted_total counter elasticsearch_slm_stats_total_snapshots_deleted_total 20 # HELP elasticsearch_slm_stats_total_snapshots_failed_total Total snapshots failed # TYPE elasticsearch_slm_stats_total_snapshots_failed_total counter elasticsearch_slm_stats_total_snapshots_failed_total 2 # HELP elasticsearch_slm_stats_total_snapshots_taken_total Total snapshots taken # TYPE elasticsearch_slm_stats_total_snapshots_taken_total counter elasticsearch_slm_stats_total_snapshots_taken_total 103 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { fStatsPath := path.Join("../fixtures/slm/stats/", tt.file) fStats, err := os.Open(fStatsPath) if err != nil { t.Fatal(err) } defer fStats.Close() fStatusPath := path.Join("../fixtures/slm/status/", tt.file) fStatus, err := os.Open(fStatusPath) if err != nil { t.Fatal(err) } defer fStatus.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.RequestURI { case "/_slm/stats": io.Copy(w, fStats) return case "/_slm/status": io.Copy(w, fStatus) return } http.Error(w, "Not Found", http.StatusNotFound) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatalf("Failed to parse URL: %s", err) } s, err := NewSLM(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{s}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/snapshots.go000066400000000000000000000156421511562765300250240ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "fmt" "log/slog" "net/http" "net/url" "path" "github.com/prometheus/client_golang/prometheus" ) var ( defaultSnapshotLabels = []string{"repository", "state", "version"} defaultSnapshotLabelValues = func(repositoryName string, snapshotStats SnapshotStatDataResponse) []string { return []string{repositoryName, snapshotStats.State, snapshotStats.Version} } defaultSnapshotRepositoryLabels = []string{"repository"} defaultSnapshotRepositoryLabelValues = func(repositoryName string) []string { return []string{repositoryName} } ) var ( numIndices = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_number_of_indices"), "Number of indices in the last snapshot", defaultSnapshotLabels, nil, ) snapshotStartTimestamp = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_start_time_timestamp"), "Last snapshot start timestamp", defaultSnapshotLabels, nil, ) snapshotEndTimestamp = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_end_time_timestamp"), "Last snapshot end timestamp", defaultSnapshotLabels, nil, ) snapshotNumFailures = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_number_of_failures"), "Last snapshot number of failures", defaultSnapshotLabels, nil, ) snapshotNumShards = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_total_shards"), "Last snapshot total shards", defaultSnapshotLabels, nil, ) snapshotFailedShards = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_failed_shards"), "Last snapshot failed shards", defaultSnapshotLabels, nil, ) snapshotSuccessfulShards = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "snapshot_successful_shards"), "Last snapshot successful shards", defaultSnapshotLabels, nil, ) numSnapshots = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "number_of_snapshots"), "Number of snapshots in a repository", defaultSnapshotRepositoryLabels, nil, ) oldestSnapshotTimestamp = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "oldest_snapshot_timestamp"), "Timestamp of the oldest snapshot", defaultSnapshotRepositoryLabels, nil, ) latestSnapshotTimestamp = prometheus.NewDesc( prometheus.BuildFQName(namespace, "snapshot_stats", "latest_snapshot_timestamp_seconds"), "Timestamp of the latest SUCCESS or PARTIAL snapshot", defaultSnapshotRepositoryLabels, nil, ) ) func init() { registerCollector("snapshots", defaultDisabled, NewSnapshots) } // Snapshots information struct type Snapshots struct { logger *slog.Logger hc *http.Client u *url.URL } // NewSnapshots defines Snapshots Prometheus metrics func NewSnapshots(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { return &Snapshots{ logger: logger, u: u, hc: hc, }, nil } func (c *Snapshots) Update(ctx context.Context, ch chan<- prometheus.Metric) error { // indices snapshotsStatsResp := make(map[string]SnapshotStatsResponse) u := c.u.ResolveReference(&url.URL{Path: "/_snapshot"}) var srr SnapshotRepositoriesResponse resp, err := getURL(ctx, c.hc, c.logger, u.String()) if err != nil { return err } err = json.Unmarshal(resp, &srr) if err != nil { return fmt.Errorf("failed to unmarshal JSON: %v", err) } for repository := range srr { pathPart := path.Join("/_snapshot", repository, "/_all") u := c.u.ResolveReference(&url.URL{Path: pathPart}) var ssr SnapshotStatsResponse resp, err := getURL(ctx, c.hc, c.logger, u.String()) if err != nil { continue } err = json.Unmarshal(resp, &ssr) if err != nil { return fmt.Errorf("failed to unmarshal JSON: %v", err) } snapshotsStatsResp[repository] = ssr } // Snapshots stats for repositoryName, snapshotStats := range snapshotsStatsResp { ch <- prometheus.MustNewConstMetric( numSnapshots, prometheus.GaugeValue, float64(len(snapshotStats.Snapshots)), defaultSnapshotRepositoryLabelValues(repositoryName)..., ) oldest := float64(0) if len(snapshotStats.Snapshots) > 0 { oldest = float64(snapshotStats.Snapshots[0].StartTimeInMillis / 1000) } ch <- prometheus.MustNewConstMetric( oldestSnapshotTimestamp, prometheus.GaugeValue, oldest, defaultSnapshotRepositoryLabelValues(repositoryName)..., ) latest := float64(0) for i := len(snapshotStats.Snapshots) - 1; i >= 0; i-- { snap := snapshotStats.Snapshots[i] if snap.State == "SUCCESS" || snap.State == "PARTIAL" { latest = float64(snap.StartTimeInMillis / 1000) break } } ch <- prometheus.MustNewConstMetric( latestSnapshotTimestamp, prometheus.GaugeValue, latest, defaultSnapshotRepositoryLabelValues(repositoryName)..., ) if len(snapshotStats.Snapshots) == 0 { continue } lastSnapshot := snapshotStats.Snapshots[len(snapshotStats.Snapshots)-1] ch <- prometheus.MustNewConstMetric( numIndices, prometheus.GaugeValue, float64(len(lastSnapshot.Indices)), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotStartTimestamp, prometheus.GaugeValue, float64(lastSnapshot.StartTimeInMillis/1000), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotEndTimestamp, prometheus.GaugeValue, float64(lastSnapshot.EndTimeInMillis/1000), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotNumFailures, prometheus.GaugeValue, float64(len(lastSnapshot.Failures)), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotNumShards, prometheus.GaugeValue, float64(lastSnapshot.Shards.Total), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotFailedShards, prometheus.GaugeValue, float64(lastSnapshot.Shards.Failed), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) ch <- prometheus.MustNewConstMetric( snapshotSuccessfulShards, prometheus.GaugeValue, float64(lastSnapshot.Shards.Successful), defaultSnapshotLabelValues(repositoryName, lastSnapshot)..., ) } return nil } prometheus-elasticsearch-exporter-1.10.0/collector/snapshots_reponse.go000066400000000000000000000035001511562765300265450ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import "time" // SnapshotStatsResponse is a representation of the snapshots stats type SnapshotStatsResponse struct { Snapshots []SnapshotStatDataResponse `json:"snapshots"` } // SnapshotStatDataResponse is a representation of the single snapshot stat type SnapshotStatDataResponse struct { Snapshot string `json:"snapshot"` UUID string `json:"uuid"` VersionID int64 `json:"version_id"` Version string `json:"version"` Indices []string `json:"indices"` State string `json:"state"` StartTime time.Time `json:"start_time"` StartTimeInMillis int64 `json:"start_time_in_millis"` EndTime time.Time `json:"end_time"` EndTimeInMillis int64 `json:"end_time_in_millis"` DurationInMillis int64 `json:"duration_in_millis"` Failures []interface{} `json:"failures"` Shards struct { Total int64 `json:"total"` Failed int64 `json:"failed"` Successful int64 `json:"successful"` } `json:"shards"` } // SnapshotRepositoriesResponse is a representation snapshots repositories type SnapshotRepositoriesResponse map[string]struct { Type string `json:"type"` } prometheus-elasticsearch-exporter-1.10.0/collector/snapshots_test.go000066400000000000000000000343221511562765300260570ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "fmt" "io" "net/http" "net/http/httptest" "net/url" "os" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestSnapshots(t *testing.T) { // Testcases created using: // docker run -d -p 9200:9200 elasticsearch:VERSION-alpine -Des.path.repo="/tmp" (1.7.6, 2.4.5) // docker run -d -p 9200:9200 elasticsearch:VERSION-alpine -E path.repo="/tmp" (5.4.2) // curl -XPUT http://localhost:9200/foo_1/type1/1 -d '{"title":"abc","content":"hello"}' // curl -XPUT http://localhost:9200/foo_1/type1/2 -d '{"title":"def","content":"world"}' // curl -XPUT http://localhost:9200/foo_2/type1/1 -d '{"title":"abc001","content":"hello001"}' // curl -XPUT http://localhost:9200/foo_2/type1/2 -d '{"title":"def002","content":"world002"}' // curl -XPUT http://localhost:9200/foo_2/type1/3 -d '{"title":"def003","content":"world003"}' // curl -XPUT http://localhost:9200/_snapshot/test1 -d '{"type": "fs","settings":{"location": "/tmp/test1"}}' // curl -XPUT "http://localhost:9200/_snapshot/test1/snapshot_1?wait_for_completion=true" // curl http://localhost:9200/_snapshot/ // curl http://localhost:9200/_snapshot/test1/_all tests := []struct { name string file string want string }{ { name: "1.7.6", file: "../fixtures/snapshots/1.7.6.json", want: `# HELP elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds Timestamp of the latest SUCCESS or PARTIAL snapshot # TYPE elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds gauge elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds{repository="test1"} 1.536052142e+09 # HELP elasticsearch_snapshot_stats_number_of_snapshots Number of snapshots in a repository # TYPE elasticsearch_snapshot_stats_number_of_snapshots gauge elasticsearch_snapshot_stats_number_of_snapshots{repository="test1"} 1 # HELP elasticsearch_snapshot_stats_oldest_snapshot_timestamp Timestamp of the oldest snapshot # TYPE elasticsearch_snapshot_stats_oldest_snapshot_timestamp gauge elasticsearch_snapshot_stats_oldest_snapshot_timestamp{repository="test1"} 1.536052142e+09 # HELP elasticsearch_snapshot_stats_snapshot_end_time_timestamp Last snapshot end timestamp # TYPE elasticsearch_snapshot_stats_snapshot_end_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_end_time_timestamp{repository="test1",state="SUCCESS",version="1.7.6"} 1.536052142e+09 # HELP elasticsearch_snapshot_stats_snapshot_failed_shards Last snapshot failed shards # TYPE elasticsearch_snapshot_stats_snapshot_failed_shards gauge elasticsearch_snapshot_stats_snapshot_failed_shards{repository="test1",state="SUCCESS",version="1.7.6"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_failures Last snapshot number of failures # TYPE elasticsearch_snapshot_stats_snapshot_number_of_failures gauge elasticsearch_snapshot_stats_snapshot_number_of_failures{repository="test1",state="SUCCESS",version="1.7.6"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_indices Number of indices in the last snapshot # TYPE elasticsearch_snapshot_stats_snapshot_number_of_indices gauge elasticsearch_snapshot_stats_snapshot_number_of_indices{repository="test1",state="SUCCESS",version="1.7.6"} 2 # HELP elasticsearch_snapshot_stats_snapshot_start_time_timestamp Last snapshot start timestamp # TYPE elasticsearch_snapshot_stats_snapshot_start_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_start_time_timestamp{repository="test1",state="SUCCESS",version="1.7.6"} 1.536052142e+09 # HELP elasticsearch_snapshot_stats_snapshot_successful_shards Last snapshot successful shards # TYPE elasticsearch_snapshot_stats_snapshot_successful_shards gauge elasticsearch_snapshot_stats_snapshot_successful_shards{repository="test1",state="SUCCESS",version="1.7.6"} 10 # HELP elasticsearch_snapshot_stats_snapshot_total_shards Last snapshot total shards # TYPE elasticsearch_snapshot_stats_snapshot_total_shards gauge elasticsearch_snapshot_stats_snapshot_total_shards{repository="test1",state="SUCCESS",version="1.7.6"} 10 `, }, { name: "2.4.5", file: "../fixtures/snapshots/2.4.5.json", want: `# HELP elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds Timestamp of the latest SUCCESS or PARTIAL snapshot # TYPE elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds gauge elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds{repository="test1"} 1.536053125e+09 # HELP elasticsearch_snapshot_stats_number_of_snapshots Number of snapshots in a repository # TYPE elasticsearch_snapshot_stats_number_of_snapshots gauge elasticsearch_snapshot_stats_number_of_snapshots{repository="test1"} 1 # HELP elasticsearch_snapshot_stats_oldest_snapshot_timestamp Timestamp of the oldest snapshot # TYPE elasticsearch_snapshot_stats_oldest_snapshot_timestamp gauge elasticsearch_snapshot_stats_oldest_snapshot_timestamp{repository="test1"} 1.536053125e+09 # HELP elasticsearch_snapshot_stats_snapshot_end_time_timestamp Last snapshot end timestamp # TYPE elasticsearch_snapshot_stats_snapshot_end_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_end_time_timestamp{repository="test1",state="SUCCESS",version="2.4.5"} 1.536053126e+09 # HELP elasticsearch_snapshot_stats_snapshot_failed_shards Last snapshot failed shards # TYPE elasticsearch_snapshot_stats_snapshot_failed_shards gauge elasticsearch_snapshot_stats_snapshot_failed_shards{repository="test1",state="SUCCESS",version="2.4.5"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_failures Last snapshot number of failures # TYPE elasticsearch_snapshot_stats_snapshot_number_of_failures gauge elasticsearch_snapshot_stats_snapshot_number_of_failures{repository="test1",state="SUCCESS",version="2.4.5"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_indices Number of indices in the last snapshot # TYPE elasticsearch_snapshot_stats_snapshot_number_of_indices gauge elasticsearch_snapshot_stats_snapshot_number_of_indices{repository="test1",state="SUCCESS",version="2.4.5"} 2 # HELP elasticsearch_snapshot_stats_snapshot_start_time_timestamp Last snapshot start timestamp # TYPE elasticsearch_snapshot_stats_snapshot_start_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_start_time_timestamp{repository="test1",state="SUCCESS",version="2.4.5"} 1.536053125e+09 # HELP elasticsearch_snapshot_stats_snapshot_successful_shards Last snapshot successful shards # TYPE elasticsearch_snapshot_stats_snapshot_successful_shards gauge elasticsearch_snapshot_stats_snapshot_successful_shards{repository="test1",state="SUCCESS",version="2.4.5"} 10 # HELP elasticsearch_snapshot_stats_snapshot_total_shards Last snapshot total shards # TYPE elasticsearch_snapshot_stats_snapshot_total_shards gauge elasticsearch_snapshot_stats_snapshot_total_shards{repository="test1",state="SUCCESS",version="2.4.5"} 10 `, }, { name: "5.4.2", file: "../fixtures/snapshots/5.4.2.json", want: `# HELP elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds Timestamp of the latest SUCCESS or PARTIAL snapshot # TYPE elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds gauge elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds{repository="test1"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_number_of_snapshots Number of snapshots in a repository # TYPE elasticsearch_snapshot_stats_number_of_snapshots gauge elasticsearch_snapshot_stats_number_of_snapshots{repository="test1"} 1 # HELP elasticsearch_snapshot_stats_oldest_snapshot_timestamp Timestamp of the oldest snapshot # TYPE elasticsearch_snapshot_stats_oldest_snapshot_timestamp gauge elasticsearch_snapshot_stats_oldest_snapshot_timestamp{repository="test1"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_snapshot_end_time_timestamp Last snapshot end timestamp # TYPE elasticsearch_snapshot_stats_snapshot_end_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_end_time_timestamp{repository="test1",state="SUCCESS",version="5.4.2"} 1.536053354e+09 # HELP elasticsearch_snapshot_stats_snapshot_failed_shards Last snapshot failed shards # TYPE elasticsearch_snapshot_stats_snapshot_failed_shards gauge elasticsearch_snapshot_stats_snapshot_failed_shards{repository="test1",state="SUCCESS",version="5.4.2"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_failures Last snapshot number of failures # TYPE elasticsearch_snapshot_stats_snapshot_number_of_failures gauge elasticsearch_snapshot_stats_snapshot_number_of_failures{repository="test1",state="SUCCESS",version="5.4.2"} 0 # HELP elasticsearch_snapshot_stats_snapshot_number_of_indices Number of indices in the last snapshot # TYPE elasticsearch_snapshot_stats_snapshot_number_of_indices gauge elasticsearch_snapshot_stats_snapshot_number_of_indices{repository="test1",state="SUCCESS",version="5.4.2"} 2 # HELP elasticsearch_snapshot_stats_snapshot_start_time_timestamp Last snapshot start timestamp # TYPE elasticsearch_snapshot_stats_snapshot_start_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_start_time_timestamp{repository="test1",state="SUCCESS",version="5.4.2"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_snapshot_successful_shards Last snapshot successful shards # TYPE elasticsearch_snapshot_stats_snapshot_successful_shards gauge elasticsearch_snapshot_stats_snapshot_successful_shards{repository="test1",state="SUCCESS",version="5.4.2"} 10 # HELP elasticsearch_snapshot_stats_snapshot_total_shards Last snapshot total shards # TYPE elasticsearch_snapshot_stats_snapshot_total_shards gauge elasticsearch_snapshot_stats_snapshot_total_shards{repository="test1",state="SUCCESS",version="5.4.2"} 10 `, }, { name: "5.4.2-failure", file: "../fixtures/snapshots/5.4.2-failed.json", want: `# HELP elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds Timestamp of the latest SUCCESS or PARTIAL snapshot # TYPE elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds gauge elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds{repository="test1"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_number_of_snapshots Number of snapshots in a repository # TYPE elasticsearch_snapshot_stats_number_of_snapshots gauge elasticsearch_snapshot_stats_number_of_snapshots{repository="test1"} 1 # HELP elasticsearch_snapshot_stats_oldest_snapshot_timestamp Timestamp of the oldest snapshot # TYPE elasticsearch_snapshot_stats_oldest_snapshot_timestamp gauge elasticsearch_snapshot_stats_oldest_snapshot_timestamp{repository="test1"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_snapshot_end_time_timestamp Last snapshot end timestamp # TYPE elasticsearch_snapshot_stats_snapshot_end_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_end_time_timestamp{repository="test1",state="SUCCESS",version="5.4.2"} 1.536053354e+09 # HELP elasticsearch_snapshot_stats_snapshot_failed_shards Last snapshot failed shards # TYPE elasticsearch_snapshot_stats_snapshot_failed_shards gauge elasticsearch_snapshot_stats_snapshot_failed_shards{repository="test1",state="SUCCESS",version="5.4.2"} 1 # HELP elasticsearch_snapshot_stats_snapshot_number_of_failures Last snapshot number of failures # TYPE elasticsearch_snapshot_stats_snapshot_number_of_failures gauge elasticsearch_snapshot_stats_snapshot_number_of_failures{repository="test1",state="SUCCESS",version="5.4.2"} 1 # HELP elasticsearch_snapshot_stats_snapshot_number_of_indices Number of indices in the last snapshot # TYPE elasticsearch_snapshot_stats_snapshot_number_of_indices gauge elasticsearch_snapshot_stats_snapshot_number_of_indices{repository="test1",state="SUCCESS",version="5.4.2"} 2 # HELP elasticsearch_snapshot_stats_snapshot_start_time_timestamp Last snapshot start timestamp # TYPE elasticsearch_snapshot_stats_snapshot_start_time_timestamp gauge elasticsearch_snapshot_stats_snapshot_start_time_timestamp{repository="test1",state="SUCCESS",version="5.4.2"} 1.536053353e+09 # HELP elasticsearch_snapshot_stats_snapshot_successful_shards Last snapshot successful shards # TYPE elasticsearch_snapshot_stats_snapshot_successful_shards gauge elasticsearch_snapshot_stats_snapshot_successful_shards{repository="test1",state="SUCCESS",version="5.4.2"} 10 # HELP elasticsearch_snapshot_stats_snapshot_total_shards Last snapshot total shards # TYPE elasticsearch_snapshot_stats_snapshot_total_shards gauge elasticsearch_snapshot_stats_snapshot_total_shards{repository="test1",state="SUCCESS",version="5.4.2"} 10 `, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { f, err := os.Open(tt.file) if err != nil { t.Fatal(err) } defer f.Close() ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { if r.RequestURI == "/_snapshot" { fmt.Fprint(w, `{"test1":{"type":"fs","settings":{"location":"/tmp/test1"}}}`) return } io.Copy(w, f) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatal(err) } c, err := NewSnapshots(promslog.NewNopLogger(), u, http.DefaultClient) if err != nil { t.Fatal(err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(tt.want)); err != nil { t.Fatal(err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/tasks.go000066400000000000000000000071111511562765300241170ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "encoding/json" "fmt" "io" "log/slog" "net/http" "net/url" "github.com/alecthomas/kingpin/v2" "github.com/prometheus/client_golang/prometheus" ) // filterByTask global required because collector interface doesn't expose any way to take // constructor args. var actionFilter string var taskActionDesc = prometheus.NewDesc( prometheus.BuildFQName(namespace, "task_stats", "action"), "Number of tasks of a certain action", []string{"action"}, nil) func init() { kingpin.Flag("tasks.actions", "Filter on task actions. Used in same way as Task API actions param"). Default("indices:*").StringVar(&actionFilter) registerCollector("tasks", defaultDisabled, NewTaskCollector) } // Task Information Struct type TaskCollector struct { logger *slog.Logger hc *http.Client u *url.URL } // NewTaskCollector defines Task Prometheus metrics func NewTaskCollector(logger *slog.Logger, u *url.URL, hc *http.Client) (Collector, error) { logger.Info("task collector created", "actionFilter", actionFilter, ) return &TaskCollector{ logger: logger, hc: hc, u: u, }, nil } func (t *TaskCollector) Update(ctx context.Context, ch chan<- prometheus.Metric) error { tasks, err := t.fetchTasks(ctx) if err != nil { return fmt.Errorf("failed to fetch and decode task stats: %w", err) } stats := AggregateTasks(tasks) for action, count := range stats.CountByAction { ch <- prometheus.MustNewConstMetric( taskActionDesc, prometheus.GaugeValue, float64(count), action, ) } return nil } func (t *TaskCollector) fetchTasks(_ context.Context) (tasksResponse, error) { u := t.u.ResolveReference(&url.URL{Path: "_tasks"}) q := u.Query() q.Set("group_by", "none") q.Set("actions", actionFilter) u.RawQuery = q.Encode() var tr tasksResponse res, err := t.hc.Get(u.String()) if err != nil { return tr, fmt.Errorf("failed to get data stream stats health from %s://%s:%s%s: %s", u.Scheme, u.Hostname(), u.Port(), u.Path, err) } defer func() { err = res.Body.Close() if err != nil { t.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return tr, fmt.Errorf("HTTP Request to %v failed with code %d", u.String(), res.StatusCode) } bts, err := io.ReadAll(res.Body) if err != nil { return tr, err } err = json.Unmarshal(bts, &tr) return tr, err } // tasksResponse is a representation of the Task management API. type tasksResponse struct { Tasks []taskResponse `json:"tasks"` } // taskResponse is a representation of the individual task item returned by task API endpoint. // // We only parse a very limited amount of this API for use in aggregation. type taskResponse struct { Action string `json:"action"` } type aggregatedTaskStats struct { CountByAction map[string]int64 } func AggregateTasks(t tasksResponse) aggregatedTaskStats { actions := map[string]int64{} for _, task := range t.Tasks { actions[task.Action]++ } return aggregatedTaskStats{CountByAction: actions} } prometheus-elasticsearch-exporter-1.10.0/collector/tasks_test.go000066400000000000000000000075701511562765300251670ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "fmt" "net/http" "net/http/httptest" "net/url" "strings" "testing" "github.com/prometheus/client_golang/prometheus/testutil" "github.com/prometheus/common/promslog" ) func TestTasks(t *testing.T) { // Test data was collected by running the following: // # create container // docker run -d --name elasticsearch -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" elasticsearch:7.17.11 // sleep 15 // # start some busy work in background // for i in $(seq 1 500) // do // curl -o /dev/null -sX POST "localhost:9200/a1/_doc" -H 'Content-Type: application/json' -d'{"a1": "'"$i"'"}' // sleep .01 // curl -o /dev/null -sX POST "localhost:9200/a1/_doc" -H 'Content-Type: application/json' -d'{"a2": "'"$i"'"}' // sleep .01 // curl -o /dev/null -sX POST "localhost:9200/a1/_doc" -H 'Content-Type: application/json' -d'{"a3": "'"$i"'"}' // sleep .01 // done & // # try and collect a good sample // curl -X GET 'localhost:9200/_tasks?group_by=none&actions=indices:*' // # cleanup // docker rm --force elasticsearch tcs := map[string]string{ "7.17": `{"tasks":[{"node":"9lWCm1y_QkujaAg75bVx7A","id":70,"type":"transport","action":"indices:admin/index_template/put","start_time_in_millis":1695900464655,"running_time_in_nanos":308640039,"cancellable":false,"headers":{}},{"node":"9lWCm1y_QkujaAg75bVx7A","id":73,"type":"transport","action":"indices:admin/index_template/put","start_time_in_millis":1695900464683,"running_time_in_nanos":280672000,"cancellable":false,"headers":{}},{"node":"9lWCm1y_QkujaAg75bVx7A","id":76,"type":"transport","action":"indices:admin/index_template/put","start_time_in_millis":1695900464711,"running_time_in_nanos":253247906,"cancellable":false,"headers":{}},{"node":"9lWCm1y_QkujaAg75bVx7A","id":93,"type":"transport","action":"indices:admin/index_template/put","start_time_in_millis":1695900464904,"running_time_in_nanos":60230460,"cancellable":false,"headers":{}},{"node":"9lWCm1y_QkujaAg75bVx7A","id":50,"type":"transport","action":"indices:data/write/index","start_time_in_millis":1695900464229,"running_time_in_nanos":734480468,"cancellable":false,"headers":{}},{"node":"9lWCm1y_QkujaAg75bVx7A","id":51,"type":"transport","action":"indices:admin/auto_create","start_time_in_millis":1695900464235,"running_time_in_nanos":729223933,"cancellable":false,"headers":{}}]}`, } want := `# HELP elasticsearch_task_stats_action Number of tasks of a certain action # TYPE elasticsearch_task_stats_action gauge elasticsearch_task_stats_action{action="indices:admin/auto_create"} 1 elasticsearch_task_stats_action{action="indices:admin/index_template/put"} 4 elasticsearch_task_stats_action{action="indices:data/write/index"} 1 ` for ver, out := range tcs { t.Run(ver, func(t *testing.T) { ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { fmt.Fprintln(w, out) })) defer ts.Close() u, err := url.Parse(ts.URL) if err != nil { t.Fatalf("Failed to parse URL: %s", err) } c, err := NewTaskCollector(promslog.NewNopLogger(), u, ts.Client()) if err != nil { t.Fatalf("Failed to create collector: %v", err) } if err := testutil.CollectAndCompare(wrapCollector{c}, strings.NewReader(want)); err != nil { t.Fatalf("Metrics did not match: %v", err) } }) } } prometheus-elasticsearch-exporter-1.10.0/collector/util.go000066400000000000000000000026321511562765300237520ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package collector import ( "context" "fmt" "io" "log/slog" "net/http" ) func getURL(ctx context.Context, hc *http.Client, log *slog.Logger, u string) ([]byte, error) { req, err := http.NewRequestWithContext(ctx, http.MethodGet, u, nil) if err != nil { return nil, err } resp, err := hc.Do(req) if err != nil { return nil, err } defer func() { err = resp.Body.Close() if err != nil { log.Warn( "failed to close response body", "err", err, ) } }() if resp.StatusCode != http.StatusOK { return nil, fmt.Errorf("HTTP Request failed with code %d", resp.StatusCode) } b, err := io.ReadAll(resp.Body) if err != nil { return nil, err } return b, nil } // bool2Float converts a bool to a float64. True is 1, false is 0. func bool2Float(managed bool) float64 { if managed { return 1 } return 0 } prometheus-elasticsearch-exporter-1.10.0/config/000077500000000000000000000000001511562765300217225ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/config/config.go000066400000000000000000000110121511562765300235110ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package config import ( "fmt" "os" "strings" "go.yaml.in/yaml/v3" ) // Config represents the YAML configuration file structure. type Config struct { AuthModules map[string]AuthModule `yaml:"auth_modules"` } type AuthModule struct { Type string `yaml:"type"` UserPass *UserPassConfig `yaml:"userpass,omitempty"` APIKey string `yaml:"apikey,omitempty"` AWS *AWSConfig `yaml:"aws,omitempty"` TLS *TLSConfig `yaml:"tls,omitempty"` Options map[string]string `yaml:"options,omitempty"` } // AWSConfig contains settings for SigV4 authentication. type AWSConfig struct { Region string `yaml:"region,omitempty"` RoleARN string `yaml:"role_arn,omitempty"` } // TLSConfig allows per-target TLS options. type TLSConfig struct { CAFile string `yaml:"ca_file,omitempty"` CertFile string `yaml:"cert_file,omitempty"` KeyFile string `yaml:"key_file,omitempty"` InsecureSkipVerify bool `yaml:"insecure_skip_verify,omitempty"` } type UserPassConfig struct { Username string `yaml:"username"` Password string `yaml:"password"` } // validate ensures every auth module has the required fields according to its type. func (c *Config) validate() error { for name, am := range c.AuthModules { // Validate fields based on auth type switch strings.ToLower(am.Type) { case "userpass": if am.UserPass == nil || am.UserPass.Username == "" || am.UserPass.Password == "" { return fmt.Errorf("auth_module %s type userpass requires username and password", name) } case "apikey": if am.APIKey == "" { return fmt.Errorf("auth_module %s type apikey requires apikey", name) } case "aws": // No strict validation: region can come from environment/defaults; role_arn is optional. case "tls": // TLS auth type means client certificate authentication only (no other auth) if am.TLS == nil { return fmt.Errorf("auth_module %s type tls requires tls configuration section", name) } if am.TLS.CertFile == "" || am.TLS.KeyFile == "" { return fmt.Errorf("auth_module %s type tls requires cert_file and key_file for client certificate authentication", name) } // Validate that other auth fields are not set when using TLS auth type if am.UserPass != nil { return fmt.Errorf("auth_module %s type tls cannot have userpass configuration", name) } if am.APIKey != "" { return fmt.Errorf("auth_module %s type tls cannot have apikey", name) } if am.AWS != nil { return fmt.Errorf("auth_module %s type tls cannot have aws configuration", name) } default: return fmt.Errorf("auth_module %s has unsupported type %s", name, am.Type) } // Validate TLS configuration (optional for all auth types, provides transport security) if am.TLS != nil { // For cert-based auth (type: tls), cert and key are required // For other auth types, TLS config is optional and used for transport security if strings.ToLower(am.Type) != "tls" { // For non-TLS auth types, if cert/key are provided, both must be present if (am.TLS.CertFile != "") != (am.TLS.KeyFile != "") { return fmt.Errorf("auth_module %s: if providing client certificate, both cert_file and key_file must be specified", name) } } // Validate file accessibility for fileType, path := range map[string]string{ "ca_file": am.TLS.CAFile, "cert_file": am.TLS.CertFile, "key_file": am.TLS.KeyFile, } { if path == "" { continue } if _, err := os.Stat(path); err != nil { return fmt.Errorf("auth_module %s: %s '%s' not accessible: %w", name, fileType, path, err) } } } } return nil } // LoadConfig reads, parses, and validates the YAML config file. func LoadConfig(path string) (*Config, error) { data, err := os.ReadFile(path) if err != nil { return nil, err } var cfg Config if err := yaml.Unmarshal(data, &cfg); err != nil { return nil, err } if err := cfg.validate(); err != nil { return nil, err } return &cfg, nil } prometheus-elasticsearch-exporter-1.10.0/config/config_test.go000066400000000000000000000076111511562765300245620ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package config import ( "os" "testing" ) func mustTempFile(t *testing.T) string { f, err := os.CreateTemp(t.TempDir(), "pem-*.crt") if err != nil { t.Fatalf("temp file: %v", err) } f.Close() // Ensure temp file is removed even if created outside of test's TempDir semantics change path := f.Name() t.Cleanup(func() { _ = os.Remove(path) }) return path } // ---------------------------- Positive cases ---------------------------- func TestLoadConfigPositiveVariants(t *testing.T) { ca := mustTempFile(t) cert := mustTempFile(t) key := mustTempFile(t) positive := []struct { name string yaml string }{{ "userpass", `auth_modules: basic: type: userpass userpass: username: u password: p`, }, { "userpass-with-tls", `auth_modules: basic: type: userpass userpass: username: u password: p tls: ca_file: ` + ca + ` insecure_skip_verify: true`, }, { "apikey", `auth_modules: key: type: apikey apikey: ZXhhbXBsZQ==`, }, { "apikey-with-tls", `auth_modules: key: type: apikey apikey: ZXhhbXBsZQ== tls: ca_file: ` + ca + ` cert_file: ` + cert + ` key_file: ` + key + ``, }, { "aws-with-tls", `auth_modules: awsmod: type: aws aws: region: us-east-1 tls: insecure_skip_verify: true`, }, { "tls-only", `auth_modules: pki: type: tls tls: ca_file: ` + ca + ` cert_file: ` + cert + ` key_file: ` + key + ``, }} for _, c := range positive { tmp, _ := os.CreateTemp(t.TempDir(), "cfg-*.yml") _, _ = tmp.WriteString(c.yaml) _ = tmp.Close() t.Cleanup(func() { _ = os.Remove(tmp.Name()) }) if _, err := LoadConfig(tmp.Name()); err != nil { t.Fatalf("%s: expected success, got %v", c.name, err) } } } // ---------------------------- Negative cases ---------------------------- func TestLoadConfigNegativeVariants(t *testing.T) { cert := mustTempFile(t) key := mustTempFile(t) negative := []struct { name string yaml string }{{ "userpassMissingPassword", `auth_modules: bad: type: userpass userpass: {username: u}`, }, { "tlsMissingCert", `auth_modules: bad: type: tls tls: {key_file: ` + key + `}`, }, { "tlsMissingKey", `auth_modules: bad: type: tls tls: {cert_file: ` + cert + `}`, }, { "tlsMissingConfig", `auth_modules: bad: type: tls`, }, { "tlsWithUserpass", `auth_modules: bad: type: tls tls: {cert_file: ` + cert + `, key_file: ` + key + `} userpass: {username: u, password: p}`, }, { "tlsWithAPIKey", `auth_modules: bad: type: tls tls: {cert_file: ` + cert + `, key_file: ` + key + `} apikey: ZXhhbXBsZQ==`, }, { "tlsWithAWS", `auth_modules: bad: type: tls tls: {cert_file: ` + cert + `, key_file: ` + key + `} aws: {region: us-east-1}`, }, { "tlsIncompleteCert", `auth_modules: bad: type: apikey apikey: ZXhhbXBsZQ== tls: {cert_file: ` + cert + `}`, }, { "unsupportedType", `auth_modules: bad: type: foobar`, }} for _, c := range negative { tmp, _ := os.CreateTemp(t.TempDir(), "cfg-*.yml") _, _ = tmp.WriteString(c.yaml) _ = tmp.Close() t.Cleanup(func() { _ = os.Remove(tmp.Name()) }) if _, err := LoadConfig(tmp.Name()); err == nil { t.Fatalf("%s: expected validation error, got none", c.name) } } } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/000077500000000000000000000000001511562765300244115ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/README.md000066400000000000000000000014331511562765300256710ustar00rootroot00000000000000# Elasticsearch Exporter Mixin This is a mixin for the elasticsearch_exporter to define dashboards, alerts, and monitoring queries for use with this exporter. Good example of upstream mixin for reference: https://github.com/kubernetes-monitoring/kubernetes-mixin ## Development ### JSONNET https://jsonnet.org/ ```go install github.com/google/go-jsonnet/cmd/jsonnet@latest``` ### JSONNET BUNDLER jsonnet bundler is a package manager for jsonnet https://github.com/jsonnet-bundler/jsonnet-bundler ```go install -a github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb@latest``` ### Grafonnet Grafana libraries for jsonnet: https://grafana.github.io/grafonnet/ ```jb install github.com/grafana/grafonnet/gen/grafonnet-latest@main``` ### Run the build ```bash ./scripts/compile-mixin.sh ``` prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/compiled/000077500000000000000000000000001511562765300262055ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/compiled/alerts.yaml000066400000000000000000000000031511562765300303540ustar00rootroot00000000000000{} prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/compiled/dashboards/000077500000000000000000000000001511562765300303175ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/compiled/dashboards/cluster.json000066400000000000000000000460501511562765300327000ustar00rootroot00000000000000{ "graphTooltip": 1, "panels": [ { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 }, "id": 1, "panels": [ ], "title": "Overview", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 8, "x": 0, "y": 1 }, "id": 2, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_number_of_nodes{cluster=~\"$cluster\"}\n)\n" } ], "title": "Nodes", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 8, "x": 8, "y": 1 }, "id": 3, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_number_of_data_nodes{cluster=~\"$cluster\"}\n)\n" } ], "title": "Data Nodes", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 8, "x": 16, "y": 1 }, "id": 4, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_number_of_pending_tasks{cluster=~\"$cluster\"}\n)\n" } ], "title": "Pending Tasks", "type": "stat" }, { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 5 }, "id": 5, "panels": [ ], "title": "Shards", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 0, "y": 6 }, "id": 6, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_active_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "Active", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 4, "y": 6 }, "id": 7, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_active_primary_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "Active Primary", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 8, "y": 6 }, "id": 8, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_initializing_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "Initializing", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 12, "y": 6 }, "id": 9, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_reloacting_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "Relocating", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 16, "y": 6 }, "id": 10, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_unassigned_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "Unassigned", "type": "stat" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 20, "y": 6 }, "id": 11, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(\n elasticsearch_cluster_health_delayed_unassigned_shards{cluster=~\"$cluster\"}\n)\n" } ], "title": "DelayedUnassigned", "type": "stat" }, { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 10 }, "id": 12, "panels": [ ], "title": "Documents", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 0, "y": 11 }, "id": 13, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_indices_docs{cluster=~\"$cluster\"}\n" } ], "title": "Indexed Documents", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "unit": "bytes" } }, "gridPos": { "h": 4, "w": 4, "x": 4, "y": 11 }, "id": 14, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_indices_store_size_bytes{cluster=~\"$cluster\"}\n" } ], "title": "Index Size", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 8, "y": 11 }, "id": 15, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "rate(elasticsearch_indices_indexing_index_total{cluster=~\"$cluster\"}[$__rate_interval])\n", "legendFormat": "{{name}}" } ], "title": "Index Rate", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 12, "y": 11 }, "id": 16, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "rate(elasticsearch_indices_search_query_total{cluster=~\"$cluster\"}[$__rate_interval])\n", "legendFormat": "{{name}}" } ], "title": "Query Rate", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 4, "x": 16, "y": 11 }, "id": 17, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "sum(elasticsearch_thread_pool_queue_count{cluster=~\"$cluster\",type!=\"management\"}) by (type)\n", "legendFormat": "{{type}}" } ], "title": "Queue Count", "type": "timeseries" }, { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 15 }, "id": 18, "panels": [ ], "title": "Memory", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "unit": "bytes" } }, "gridPos": { "h": 4, "w": 6, "x": 0, "y": 16 }, "id": 19, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_jvm_memory_used_bytes{cluster=~\"$cluster\"}\n", "legendFormat": "{{name}} {{area}}" } ], "title": "Memory Usage", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "max": 1, "min": 0, "unit": "percentunit" } }, "gridPos": { "h": 4, "w": 6, "x": 6, "y": 16 }, "id": 20, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "avg_over_time(\n elasticsearch_jvm_memory_used_bytes{cluster=~\"$cluster\"}[15m]\n) /\nelasticsearch_jvm_memory_max_bytes{cluster=~\"$cluster\"}\n", "legendFormat": "{{name}} {{area}}" } ], "title": "Memory 15m Avg", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "unit": "bytes" } }, "gridPos": { "h": 4, "w": 6, "x": 12, "y": 16 }, "id": 21, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_jvm_memory_max_bytes{cluster=~\"$cluster\"}\n", "legendFormat": "{{name}} {{area}}" } ], "title": "Memory Max", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "unit": "s" } }, "gridPos": { "h": 4, "w": 6, "x": 18, "y": 16 }, "id": 22, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "rate(\n elasticsearch_jvm_gc_collection_seconds_sum{cluster=~\"$cluster\"}[$__rate_interval]\n)\n", "legendFormat": "{{name}} {{gc}}" } ], "title": "GC Rate", "type": "timeseries" }, { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 20 }, "id": 23, "panels": [ ], "title": "Threads", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 12, "x": 0, "y": 21 }, "id": 24, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_thread_pool_active_count{cluster=~\"$cluster\"}\n", "legendFormat": "{{type}}" } ], "title": "Thread Pools", "type": "timeseries" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "gridPos": { "h": 4, "w": 12, "x": 12, "y": 21 }, "id": 25, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "elasticsearch_thread_pool_rejected_count{cluster=~\"$cluster\"}\n", "legendFormat": "{{name}} {{type}}" } ], "title": "Thread Pool Rejections", "type": "timeseries" }, { "collapsed": false, "gridPos": { "h": 1, "w": 24, "x": 0, "y": 25 }, "id": 26, "panels": [ ], "title": "Network", "type": "row" }, { "datasource": { "type": "datasource", "uid": "-- Mixed --" }, "fieldConfig": { "defaults": { "unit": "bytes" } }, "gridPos": { "h": 4, "w": 24, "x": 0, "y": 26 }, "id": 27, "pluginVersion": "v10.4.0", "targets": [ { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "rate(\n elasticsearch_transport_rx_size_bytes_total{cluster=~\"$cluster\"}[$__rate_interval]\n)\n", "legendFormat": "{{name}} TX" }, { "datasource": { "type": "prometheus", "uid": "$datasource" }, "expr": "rate(\n elasticsearch_transport_tx_size_bytes_total{cluster=~\"$cluster\"}[$__rate_interval]\n)\n", "legendFormat": "{{name}} RX" } ], "title": "Transport Rate", "type": "timeseries" } ], "refresh": "1m", "schemaVersion": 36, "tags": [ "elasticsearch-exporter-mixin" ], "templating": { "list": [ { "name": "datasource", "query": "prometheus", "type": "datasource" }, { "datasource": { "type": "prometheus", "uid": "${datasource}" }, "name": "cluster", "query": "label_values(elasticsearch_cluster_health_status, cluster)", "type": "query" } ] }, "time": { "from": "now-1h", "to": "now" }, "timezone": "utc", "title": "Elasticsearch Exporter / Cluster" }prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/compiled/rules.yaml000066400000000000000000000000031511562765300302140ustar00rootroot00000000000000{} prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/config.libsonnet000066400000000000000000000002031511562765300275700ustar00rootroot00000000000000{ _config+:: { dashboardNamePrefix: 'Elasticsearch Exporter / ', dashboardTags: ['elasticsearch-exporter-mixin'], }, } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards.jsonnet000066400000000000000000000002101511562765300301160ustar00rootroot00000000000000local dashboards = (import 'mixin.libsonnet').grafanaDashboards; { [name]: dashboards[name] for name in std.objectFields(dashboards) } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/000077500000000000000000000000001511562765300265235ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/cluster.libsonnet000066400000000000000000000053201511562765300321230ustar00rootroot00000000000000local g = import 'g.libsonnet'; local dashboard = g.dashboard; local row = g.panel.row; local panels = import './panels.libsonnet'; local queries = import './queries.libsonnet'; local variables = import './variables.libsonnet'; local util = import './util.libsonnet'; { grafanaDashboards+:: { 'cluster.json': dashboard.new('%s Cluster' % $._config.dashboardNamePrefix) + dashboard.withTags($._config.dashboardTags) + dashboard.withRefresh('1m') + dashboard.time.withFrom(value='now-1h') + dashboard.graphTooltip.withSharedCrosshair() + dashboard.withVariables([ variables.datasource, variables.cluster, ]) + dashboard.withPanels( util.makeGrid([ row.new('Overview') + row.withPanels([ panels.stat.nodes('Nodes', queries.runningNodes), panels.stat.nodes('Data Nodes', queries.dataNodes), panels.stat.nodes('Pending Tasks', queries.pendingTasks), ]), row.new('Shards') + row.withPanels([ panels.stat.nodes('Active', queries.activeShards), panels.stat.nodes('Active Primary', queries.activePrimaryShards), panels.stat.nodes('Initializing', queries.initializingShards), panels.stat.nodes('Relocating', queries.reloactingShards), panels.stat.nodes('Unassigned', queries.unassignedShards), panels.stat.nodes('DelayedUnassigned', queries.delayedUnassignedShards), ]), row.new('Documents') + row.withPanels([ panels.timeSeries.base('Indexed Documents', queries.indexedDocuments), panels.timeSeries.bytes('Index Size', queries.indexSize), panels.timeSeries.base('Index Rate', queries.indexRate), panels.timeSeries.base('Query Rate', queries.queryRate), panels.timeSeries.base('Queue Count', queries.queueCount), ]), row.new('Memory') + row.withPanels([ panels.timeSeries.bytes('Memory Usage', queries.memoryUsage), panels.timeSeries.ratioMax1('Memory 15m Avg', queries.memoryUsageAverage15), panels.timeSeries.bytes('Memory Max', queries.memoryMax), panels.timeSeries.seconds('GC Rate', queries.gcSeconds), ]), row.new('Threads') + row.withPanels([ panels.timeSeries.base('Thread Pools', queries.threadPoolActive), panels.timeSeries.base('Thread Pool Rejections', queries.threadPoolRejections), ]), row.new('Network') + row.withPanels([ panels.timeSeries.bytes('Transport Rate', [queries.transportTXRate, queries.transportRXRate]), ]), ]), ), }, } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/dashboards.libsonnet000066400000000000000000000000351511562765300325520ustar00rootroot00000000000000(import 'cluster.libsonnet') prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/g.libsonnet000066400000000000000000000001121511562765300306620ustar00rootroot00000000000000import 'github.com/grafana/grafonnet/gen/grafonnet-latest/main.libsonnet' prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/panels.libsonnet000066400000000000000000000015611511562765300317270ustar00rootroot00000000000000local g = import 'g.libsonnet'; { stat: { local stat = g.panel.stat, base(title, targets): stat.new(title) + stat.queryOptions.withTargets(targets), nodes: self.base, }, timeSeries: { local timeSeries = g.panel.timeSeries, base(title, targets): timeSeries.new(title) + timeSeries.queryOptions.withTargets(targets), ratio(title, targets): self.base(title, targets) + timeSeries.standardOptions.withUnit('percentunit'), ratioMax1(title, targets): self.ratio(title, targets) + timeSeries.standardOptions.withMax(1) + timeSeries.standardOptions.withMin(0), bytes(title, targets): self.base(title, targets) + timeSeries.standardOptions.withUnit('bytes'), seconds(title, targets): self.base(title, targets) + timeSeries.standardOptions.withUnit('s'), }, } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries.libsonnet000066400000000000000000000005641511562765300321240ustar00rootroot00000000000000local g = import './g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import './variables.libsonnet'; (import './queries/general.libsonnet') + (import './queries/shard.libsonnet') + (import './queries/document.libsonnet') + (import './queries/memory.libsonnet') + (import './queries/threads.libsonnet') + (import './queries/network.libsonnet') prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/000077500000000000000000000000001511562765300302005ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/document.libsonnet000066400000000000000000000023251511562765300337370ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { indexedDocuments: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_indices_docs{cluster=~"$cluster"} ||| ), indexSize: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_indices_store_size_bytes{cluster=~"$cluster"} ||| ), indexRate: prometheusQuery.new( '$' + variables.datasource.name, ||| rate(elasticsearch_indices_indexing_index_total{cluster=~"$cluster"}[$__rate_interval]) ||| ) + prometheusQuery.withLegendFormat('{{name}}'), queryRate: prometheusQuery.new( '$' + variables.datasource.name, ||| rate(elasticsearch_indices_search_query_total{cluster=~"$cluster"}[$__rate_interval]) ||| ) + prometheusQuery.withLegendFormat('{{name}}'), queueCount: prometheusQuery.new( '$' + variables.datasource.name, ||| sum(elasticsearch_thread_pool_queue_count{cluster=~"$cluster",type!="management"}) by (type) ||| ) + prometheusQuery.withLegendFormat('{{type}}'), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/general.libsonnet000066400000000000000000000013751511562765300335420ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { runningNodes: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_number_of_nodes{cluster=~"$cluster"} ) ||| ), dataNodes: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_number_of_data_nodes{cluster=~"$cluster"} ) ||| ), pendingTasks: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_number_of_pending_tasks{cluster=~"$cluster"} ) ||| ), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/memory.libsonnet000066400000000000000000000023071511562765300334310ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { memoryUsage: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_jvm_memory_used_bytes{cluster=~"$cluster"} ||| ) + prometheusQuery.withLegendFormat('{{name}} {{area}}'), memoryUsageAverage15: prometheusQuery.new( '$' + variables.datasource.name, ||| avg_over_time( elasticsearch_jvm_memory_used_bytes{cluster=~"$cluster"}[15m] ) / elasticsearch_jvm_memory_max_bytes{cluster=~"$cluster"} ||| ) + prometheusQuery.withLegendFormat('{{name}} {{area}}'), memoryMax: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_jvm_memory_max_bytes{cluster=~"$cluster"} ||| ) + prometheusQuery.withLegendFormat('{{name}} {{area}}'), gcSeconds: prometheusQuery.new( '$' + variables.datasource.name, ||| rate( elasticsearch_jvm_gc_collection_seconds_sum{cluster=~"$cluster"}[$__rate_interval] ) ||| ) + prometheusQuery.withLegendFormat('{{name}} {{gc}}'), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/network.libsonnet000066400000000000000000000012731511562765300336130ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { transportTXRate: prometheusQuery.new( '$' + variables.datasource.name, ||| rate( elasticsearch_transport_rx_size_bytes_total{cluster=~"$cluster"}[$__rate_interval] ) ||| ) + prometheusQuery.withLegendFormat('{{name}} TX'), transportRXRate: prometheusQuery.new( '$' + variables.datasource.name, ||| rate( elasticsearch_transport_tx_size_bytes_total{cluster=~"$cluster"}[$__rate_interval] ) ||| ) + prometheusQuery.withLegendFormat('{{name}} RX'), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/shard.libsonnet000066400000000000000000000026271511562765300332270ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { activeShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_active_shards{cluster=~"$cluster"} ) ||| ), activePrimaryShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_active_primary_shards{cluster=~"$cluster"} ) ||| ), initializingShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_initializing_shards{cluster=~"$cluster"} ) ||| ), reloactingShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_reloacting_shards{cluster=~"$cluster"} ) ||| ), unassignedShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_unassigned_shards{cluster=~"$cluster"} ) ||| ), delayedUnassignedShards: prometheusQuery.new( '$' + variables.datasource.name, ||| sum( elasticsearch_cluster_health_delayed_unassigned_shards{cluster=~"$cluster"} ) ||| ), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/queries/threads.libsonnet000066400000000000000000000011441511562765300335510ustar00rootroot00000000000000local g = import '../g.libsonnet'; local prometheusQuery = g.query.prometheus; local variables = import '../variables.libsonnet'; { threadPoolActive: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_thread_pool_active_count{cluster=~"$cluster"} ||| ) + prometheusQuery.withLegendFormat('{{type}}'), threadPoolRejections: prometheusQuery.new( '$' + variables.datasource.name, ||| elasticsearch_thread_pool_rejected_count{cluster=~"$cluster"} ||| ) + prometheusQuery.withLegendFormat('{{name}} {{type}}'), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/util.libsonnet000066400000000000000000000037761511562765300314340ustar00rootroot00000000000000local g = import 'g.libsonnet'; local panelUtil = g.util.panel; { local gridWidth = 24, // makeGrid returns an array of panels organized into a grid layout. // This is a modified version of the grafonnet makeGrid function to // calculate the width of each panel based on the number of panels. makeGrid(panels, panelHeight=4, startY=0): local sanitizePanels(ps) = // Figure out the number of panels and the width of each panel local numPanels = std.length(ps); local panelWidth = std.floor(gridWidth / numPanels); // Sanitize the panels, this ensures tht the panels have the valid gridPos std.map( function(p) local sanePanel = panelUtil.sanitizePanel(p, defaultHeight=panelHeight); ( if p.type == 'row' then sanePanel { panels: sanitizePanels(sanePanel.panels), } else sanePanel { gridPos+: { w: panelWidth, }, } ), ps ); local sanitizedPanels = sanitizePanels(panels); local grouped = panelUtil.groupPanelsInRows(sanitizedPanels); local panelsBeforeRows = panelUtil.getPanelsBeforeNextRow(grouped); local rowPanels = std.filter( function(p) p.type == 'row', grouped ); local CalculateXforPanel(index, panel) = local panelsPerRow = std.floor(gridWidth / panel.gridPos.w); local col = std.mod(index, panelsPerRow); panel { gridPos+: { x: panel.gridPos.w * col } }; local panelsBeforeRowsWithX = std.mapWithIndex(CalculateXforPanel, panelsBeforeRows); local rowPanelsWithX = std.map( function(row) row { panels: std.mapWithIndex(CalculateXforPanel, row.panels) }, rowPanels ); local uncollapsed = panelUtil.resolveCollapsedFlagOnRows(panelsBeforeRowsWithX + rowPanelsWithX); local normalized = panelUtil.normalizeY(uncollapsed); std.map(function(p) p { gridPos+: { y+: startY } }, normalized), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/dashboards/variables.libsonnet000066400000000000000000000005411511562765300324120ustar00rootroot00000000000000local g = import './g.libsonnet'; local var = g.dashboard.variable; { datasource: var.datasource.new('datasource', 'prometheus'), cluster: var.query.new('cluster') + var.query.withDatasourceFromVariable(self.datasource) + var.query.queryTypes.withLabelValues( 'cluster', 'elasticsearch_cluster_health_status', ), } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/jsonnetfile.json000066400000000000000000000004121511562765300276210ustar00rootroot00000000000000{ "version": 1, "dependencies": [ { "source": { "git": { "remote": "https://github.com/grafana/grafonnet.git", "subdir": "gen/grafonnet-latest" } }, "version": "main" } ], "legacyImports": true } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/jsonnetfile.lock.json000066400000000000000000000023061511562765300305540ustar00rootroot00000000000000{ "version": 1, "dependencies": [ { "source": { "git": { "remote": "https://github.com/grafana/grafonnet.git", "subdir": "gen/grafonnet-latest" } }, "version": "1c56af39815c4903e47c27194444456f005f65df", "sum": "GxEO83uxgsDclLp/fmlUJZDbSGpeUZY6Ap3G2cgdL1g=" }, { "source": { "git": { "remote": "https://github.com/grafana/grafonnet.git", "subdir": "gen/grafonnet-v10.4.0" } }, "version": "1c56af39815c4903e47c27194444456f005f65df", "sum": "DKj+Sn+rlI48g/aoJpzkfPge46ya0jLk5kcZoiZ2X/I=" }, { "source": { "git": { "remote": "https://github.com/jsonnet-libs/docsonnet.git", "subdir": "doc-util" } }, "version": "6ac6c69685b8c29c54515448eaca583da2d88150", "sum": "BrAL/k23jq+xy9oA7TWIhUx07dsA/QLm3g7ktCwe//U=" }, { "source": { "git": { "remote": "https://github.com/jsonnet-libs/xtd.git", "subdir": "" } }, "version": "63d430b69a95741061c2f7fc9d84b1a778511d9c", "sum": "qiZi3axUSXCVzKUF83zSAxklwrnitMmrDK4XAfjPMdE=" } ], "legacyImports": false } prometheus-elasticsearch-exporter-1.10.0/elasticsearch-mixin/mixin.libsonnet000066400000000000000000000001611511562765300274520ustar00rootroot00000000000000// (import 'alerts/alerts.libsonnet') + (import 'dashboards/dashboards.libsonnet') + (import 'config.libsonnet') prometheus-elasticsearch-exporter-1.10.0/examples/000077500000000000000000000000001511562765300222735ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/examples/auth_modules.yml000066400000000000000000000044431511562765300255140ustar00rootroot00000000000000# Example exporter-config.yml demonstrating multiple auth modules # Each module can be referenced with ?auth_module= in /probe requests. auth_modules: ########################################################################### # 1. Simple basic-auth over HTTPS # ########################################################################### prod_basic: type: userpass userpass: username: metrics password: s3cr3t # extra URL query parameters are appended to the target DSN options: sslmode: disable # becomes ?sslmode=disable ########################################################################### # 2. Read-only account for staging cluster # ########################################################################### staging_ro: type: userpass userpass: username: readonly password: changeme ########################################################################### # 3. API-Key authentication # ########################################################################### prod_key: type: apikey apikey: BASE64-ENCODED-KEY== ########################################################################### # 5. AWS SigV4 signing with optional TLS settings # ########################################################################### aws_sigv4: type: aws aws: region: us-east-1 # role_arn is optional # Optional TLS configuration for transport security tls: ca_file: /etc/ssl/ca.pem insecure_skip_verify: false ########################################################################### # 6. Client certificate authentication only (no username/password) # ########################################################################### pki_mtls: type: tls # This auth type uses ONLY client certificates for authentication tls: ca_file: /etc/ssl/pki/ca.pem # Optional: CA for server verification cert_file: /etc/ssl/pki/client.pem # Required: Client certificate for auth key_file: /etc/ssl/pki/client-key.pem # Required: Client private key for auth insecure_skip_verify: false # Optional: Skip server cert validation prometheus-elasticsearch-exporter-1.10.0/examples/example-prometheus.yml000066400000000000000000000024541511562765300266470ustar00rootroot00000000000000scrape_configs: - job_name: es-multi metrics_path: /probe # Default parameters for all scrapes in this job. # Can be overridden by labels on a per-target basis. params: auth_module: [prod_key] static_configs: # This is a target group. All targets here will use the default 'prod_key' auth_module. - targets: - https://es-prod-1:9200 - https://es-prod-2:9200 # This is another target group. - targets: - https://es-stage:9200 # The __param_ prefix on a label causes it to be added as a URL parameter. # This will override the default auth_module for this target. labels: __param_auth_module: staging_basic relabel_configs: # The following relabeling rules are applied to every target. # 1. The special label __address__ (the target address) is saved as the 'target' URL parameter. - source_labels: [__address__] target_label: __param_target # 2. The 'target' parameter is used as the 'instance' label for the scraped metrics. - source_labels: [__param_target] target_label: instance # 3. The scrape address is rewritten to point to the exporter. - target_label: __address__ replacement: exporter:9114 # host:port of the single exporter prometheus-elasticsearch-exporter-1.10.0/examples/kubernetes/000077500000000000000000000000001511562765300244425ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/examples/kubernetes/deployment.yml000066400000000000000000000034151511562765300273500ustar00rootroot00000000000000--- apiVersion: apps/v1 kind: Deployment metadata: name: elastic-exporter spec: replicas: 1 strategy: rollingUpdate: maxSurge: 1 maxUnavailable: 0 type: RollingUpdate selector: matchLabels: app: elastic-exporter template: metadata: labels: app: elastic-exporter spec: containers: - command: - /bin/elasticsearch_exporter - --es.uri=http://elasticsearch:9200 - --es.all image: quay.io/prometheuscommunity/elasticsearch-exporter:latest securityContext: capabilities: drop: - SETPCAP - MKNOD - AUDIT_WRITE - CHOWN - NET_RAW - DAC_OVERRIDE - FOWNER - FSETID - KILL - SETGID - SETUID - NET_BIND_SERVICE - SYS_CHROOT - SETFCAP readOnlyRootFilesystem: true livenessProbe: httpGet: path: /healthz port: 9114 initialDelaySeconds: 30 timeoutSeconds: 10 name: elastic-exporter ports: - containerPort: 9114 name: http readinessProbe: httpGet: path: /healthz port: 9114 initialDelaySeconds: 10 timeoutSeconds: 10 resources: limits: cpu: 100m memory: 128Mi requests: cpu: 25m memory: 64Mi restartPolicy: Always securityContext: runAsNonRoot: true runAsGroup: 10000 runAsUser: 10000 fsGroup: 10000 prometheus-elasticsearch-exporter-1.10.0/examples/prometheus/000077500000000000000000000000001511562765300244665ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/examples/prometheus/elasticsearch.rules000066400000000000000000000017231511562765300303570ustar00rootroot00000000000000# calculate filesystem used and free percent elasticsearch_filesystem_data_used_percent = 100 * (elasticsearch_filesystem_data_size_bytes - elasticsearch_filesystem_data_free_bytes) / elasticsearch_filesystem_data_size_bytes elasticsearch_filesystem_data_free_percent = 100 - elasticsearch_filesystem_data_used_percent # alert if too few nodes are running ALERT ElasticsearchTooFewNodesRunning IF elasticsearch_cluster_health_number_of_nodes < 3 FOR 5m LABELS {severity="critical"} ANNOTATIONS {description="There are only {{$value}} < 3 Elasticsearch nodes running", summary="Elasticsearch running on less than 3 nodes"} # alert if heap usage is over 90% ALERT ElasticsearchHeapTooHigh IF elasticsearch_jvm_memory_used_bytes{area="heap"} / elasticsearch_jvm_memory_max_bytes{area="heap"} > 0.9 FOR 15m LABELS {severity="critical"} ANNOTATIONS {description="The heap usage is over 90% for 15m", summary="Elasticsearch node {{$labels.node}} heap usage is high"} prometheus-elasticsearch-exporter-1.10.0/examples/prometheus/elasticsearch.rules.yml000066400000000000000000000021161511562765300311540ustar00rootroot00000000000000groups: - name: elasticsearch rules: - record: elasticsearch_filesystem_data_used_percent expr: 100 * (elasticsearch_filesystem_data_size_bytes - elasticsearch_filesystem_data_free_bytes) / elasticsearch_filesystem_data_size_bytes - record: elasticsearch_filesystem_data_free_percent expr: 100 - elasticsearch_filesystem_data_used_percent - alert: ElasticsearchTooFewNodesRunning expr: elasticsearch_cluster_health_number_of_nodes < 3 for: 5m labels: severity: critical annotations: description: There are only {{$value}} < 3 Elasticsearch nodes running summary: Elasticsearch running on less than 3 nodes - alert: ElasticsearchHeapTooHigh expr: elasticsearch_jvm_memory_used_bytes{area="heap"} / elasticsearch_jvm_memory_max_bytes{area="heap"} > 0.9 for: 15m labels: severity: critical annotations: description: The heap usage is over 90% for 15m summary: Elasticsearch node {{$labels.node}} heap usage is high prometheus-elasticsearch-exporter-1.10.0/fixtures/000077500000000000000000000000001511562765300223265ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterhealth/000077500000000000000000000000001511562765300251755ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterhealth/1.7.6.json000066400000000000000000000005571511562765300265500ustar00rootroot00000000000000{ "cluster_name": "elasticsearch", "status": "yellow", "timed_out": false, "number_of_nodes": 1, "number_of_data_nodes": 1, "active_primary_shards": 5, "active_shards": 5, "relocating_shards": 0, "initializing_shards": 0, "unassigned_shards": 5, "delayed_unassigned_shards": 0, "number_of_pending_tasks": 0, "number_of_in_flight_fetch": 0 } prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterhealth/2.4.5.json000066400000000000000000000007041511562765300265370ustar00rootroot00000000000000{ "cluster_name": "elasticsearch", "status": "yellow", "timed_out": false, "number_of_nodes": 1, "number_of_data_nodes": 1, "active_primary_shards": 5, "active_shards": 5, "relocating_shards": 0, "initializing_shards": 0, "unassigned_shards": 5, "delayed_unassigned_shards": 0, "number_of_pending_tasks": 0, "number_of_in_flight_fetch": 0, "task_max_waiting_in_queue_millis": 12, "active_shards_percent_as_number": 50.0 } prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterhealth/5.4.2.json000066400000000000000000000007041511562765300265370ustar00rootroot00000000000000{ "cluster_name": "elasticsearch", "status": "yellow", "timed_out": false, "number_of_nodes": 1, "number_of_data_nodes": 1, "active_primary_shards": 5, "active_shards": 5, "relocating_shards": 0, "initializing_shards": 0, "unassigned_shards": 5, "delayed_unassigned_shards": 0, "number_of_pending_tasks": 0, "number_of_in_flight_fetch": 0, "task_max_waiting_in_queue_millis": 12, "active_shards_percent_as_number": 50.0 } prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterinfo/000077500000000000000000000000001511562765300246635ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterinfo/2.4.5.json000066400000000000000000000005521511562765300262260ustar00rootroot00000000000000{ "name" : "Mys-Tech", "cluster_name" : "elasticsearch", "cluster_uuid" : "3qps7bcWTqyzV49ApmPVfw", "version" : { "number" : "2.4.5", "build_hash" : "c849dd13904f53e63e88efc33b2ceeda0b6a1276", "build_timestamp" : "2017-04-24T16:18:17Z", "build_snapshot" : false, "lucene_version" : "5.5.4" }, "tagline" : "You Know, for Search" } prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterinfo/5.4.2.json000066400000000000000000000005071511562765300262260ustar00rootroot00000000000000{ "name" : "gOHPUga", "cluster_name" : "elasticsearch", "cluster_uuid" : "kbqi7yhQT-WlPdGL2m0xJg", "version" : { "number" : "5.4.2", "build_hash" : "929b078", "build_date" : "2017-06-15T02:29:28.122Z", "build_snapshot" : false, "lucene_version" : "6.5.1" }, "tagline" : "You Know, for Search" } prometheus-elasticsearch-exporter-1.10.0/fixtures/clusterinfo/7.13.1.json000066400000000000000000000010411511562765300263010ustar00rootroot00000000000000{ "name" : "e0630cfd8e1e", "cluster_name" : "docker-cluster", "cluster_uuid" : "aCMrCY1VQpqJ6U4Sw_xdiw", "version" : { "number" : "7.13.1", "build_flavor" : "default", "build_type" : "docker", "build_hash" : "9a7758028e4ea59bcab41c12004603c5a7dd84a9", "build_date" : "2021-05-28T17:40:59.346932922Z", "build_snapshot" : false, "lucene_version" : "8.8.2", "minimum_wire_compatibility_version" : "6.8.0", "minimum_index_compatibility_version" : "6.0.0-beta1" }, "tagline" : "You Know, for Search" } prometheus-elasticsearch-exporter-1.10.0/fixtures/datastream/000077500000000000000000000000001511562765300244535ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/datastream/7.15.0.json000066400000000000000000000007461511562765300261050ustar00rootroot00000000000000{ "_shards": { "total": 30, "successful": 30, "failed": 0 }, "data_stream_count": 2, "backing_indices": 7, "total_store_size_bytes": 1103028116, "data_streams": [ { "data_stream": "foo", "backing_indices": 5, "store_size_bytes": 429205396, "maximum_timestamp": 1656079894000 }, { "data_stream": "bar", "backing_indices": 2, "store_size_bytes": 673822720, "maximum_timestamp": 1656028796000 } ] } prometheus-elasticsearch-exporter-1.10.0/fixtures/healthreport/000077500000000000000000000000001511562765300250275ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/healthreport/8.7.0.json000066400000000000000000000065621511562765300264050ustar00rootroot00000000000000{ "status": "green", "cluster_name": "docker-cluster", "indicators": { "master_is_stable": { "status": "green", "symptom": "The cluster has a stable master node", "details": { "current_master": { "node_id": "X8BAj1mfQ3qgcSoAlG3HHw", "name": "5da1610e99a7" }, "recent_masters": [ { "node_id": "X8BAj1mfQ3qgcSoAlG3HHw", "name": "5da1610e99a7" } ] } }, "repository_integrity": { "status": "green", "symptom": "All repositories are healthy.", "details": { "total_repositories": 1 } }, "shards_capacity": { "status": "green", "symptom": "The cluster has enough room to add new shards.", "details": { "data": { "max_shards_in_cluster": 13500 }, "frozen": { "max_shards_in_cluster": 9000 } } }, "shards_availability": { "status": "green", "symptom": "This cluster has all shards available.", "details": { "restarting_replicas": 0, "creating_primaries": 0, "initializing_replicas": 0, "unassigned_replicas": 0, "started_primaries": 11703, "restarting_primaries": 0, "initializing_primaries": 0, "creating_replicas": 0, "started_replicas": 1701, "unassigned_primaries": 0 }, "impacts": [ { "id": "elasticsearch:health:shards_availability:impact:replica_unassigned", "severity": 2, "description": "Searches might be slower than usual. Fewer redundant copies of the data exist on 1 index [twitter].", "impact_areas": [ "search" ] } ], "diagnosis": [ { "id": "elasticsearch:health:shards_availability:diagnosis:increase_tier_capacity_for_allocations:tier:data_content", "cause": "Elasticsearch isn't allowed to allocate some shards from these indices to any of the nodes in the desired data tier because there are not enough nodes in the [data_content] tier to allocate each shard copy on a different node.", "action": "Increase the number of nodes in this tier or decrease the number of replica shards in the affected indices.", "help_url": "https://ela.st/tier-capacity", "affected_resources": { "indices": [ "twitter" ] } } ] }, "disk": { "status": "green", "symptom": "The cluster has enough available disk space.", "details": { "indices_with_readonly_block": 0, "nodes_with_enough_disk_space": 1, "nodes_with_unknown_disk_status": 0, "nodes_over_high_watermark": 0, "nodes_over_flood_stage_watermark": 0 } }, "data_stream_lifecycle": { "status": "green", "symptom": "No data stream lifecycle health data available yet. Health information will be reported after the first run." }, "ilm": { "status": "green", "symptom": "Index Lifecycle Management is running", "details": { "policies": 17, "ilm_status": "RUNNING" } }, "slm": { "status": "green", "symptom": "No Snapshot Lifecycle Management policies configured", "details": { "slm_status": "RUNNING", "policies": 0 } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/ilm_indices/000077500000000000000000000000001511562765300246055ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/ilm_indices/6.6.0.json000066400000000000000000000006761511562765300261600ustar00rootroot00000000000000{ "indices": { "twitter": { "index": "twitter", "managed": false }, "facebook": { "index": "facebook", "managed": true, "policy": "my_policy", "lifecycle_date_millis": 1660799138565, "phase": "new", "phase_time_millis": 1660799138651, "action": "complete", "action_time_millis": 1660799138651, "step": "complete", "step_time_millis": 1660799138651 } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/ilm_status/000077500000000000000000000000001511562765300245125ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/ilm_status/6.6.0.json000066400000000000000000000000421511562765300260500ustar00rootroot00000000000000{ "operation_mode": "RUNNING" } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/000077500000000000000000000000001511562765300237445ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/1.7.6.json000066400000000000000000000410171511562765300253130ustar00rootroot00000000000000{ "_shards": { "total": 20, "successful": 10, "failed": 0 }, "_all": { "primaries": { "docs": { "count": 5, "deleted": 0 }, "store": { "size_in_bytes": 13798, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 5, "index_time_in_millis": 52, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 5, "total_time_in_millis": 163 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 30, "total_time_in_millis": 42 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 18410, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 671088640, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 5, "size_in_bytes": 102 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 5, "deleted": 0 }, "store": { "size_in_bytes": 13798, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 5, "index_time_in_millis": 52, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 5, "total_time_in_millis": 163 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 30, "total_time_in_millis": 42 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 18410, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 671088640, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 5, "size_in_bytes": 102 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "indices": { "foo_2": { "primaries": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 8207, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 6, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 3, "total_time_in_millis": 38 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 16, "total_time_in_millis": 0 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 11046, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 335544320, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 3, "size_in_bytes": 102 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 8207, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 6, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 3, "total_time_in_millis": 38 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 16, "total_time_in_millis": 0 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 11046, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 335544320, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 3, "size_in_bytes": 102 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_1": { "primaries": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 5591, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 46, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 2, "total_time_in_millis": 125 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 42 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 7364, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 335544320, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 2, "size_in_bytes": 17 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 5591, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 46, "index_current": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0 }, "refresh": { "total": 2, "total_time_in_millis": 125 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 42 }, "filter_cache": { "memory_size_in_bytes": 0, "evictions": 0 }, "id_cache": { "memory_size_in_bytes": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 7364, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 335544320, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 2, "size_in_bytes": 17 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "query_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/2.4.5.json000066400000000000000000000473531511562765300253210ustar00rootroot00000000000000{ "_shards": { "total": 20, "successful": 10, "failed": 0 }, "_all": { "primaries": { "docs": { "count": 5, "deleted": 0 }, "store": { "size_in_bytes": 3610, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 5, "index_time_in_millis": 40, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 209715200 }, "refresh": { "total": 5, "total_time_in_millis": 171 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 30, "total_time_in_millis": 12 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 10530, "terms_memory_in_bytes": 7550, "stored_fields_memory_in_bytes": 1560, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 960, "doc_values_memory_in_bytes": 460, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 103887660, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 5, "size_in_bytes": 843 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 5, "deleted": 0 }, "store": { "size_in_bytes": 3610, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 5, "index_time_in_millis": 40, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 209715200 }, "refresh": { "total": 5, "total_time_in_millis": 171 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 30, "total_time_in_millis": 12 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 10530, "terms_memory_in_bytes": 7550, "stored_fields_memory_in_bytes": 1560, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 960, "doc_values_memory_in_bytes": 460, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 103887660, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 5, "size_in_bytes": 843 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "indices": { "foo_2": { "primaries": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 3350, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 6, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 3, "total_time_in_millis": 34 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 16, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 6318, "terms_memory_in_bytes": 4530, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 576, "doc_values_memory_in_bytes": 276, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 51943830, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 3, "size_in_bytes": 470 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 3350, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 6, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 3, "total_time_in_millis": 34 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 16, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 6318, "terms_memory_in_bytes": 4530, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 576, "doc_values_memory_in_bytes": 276, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 51943830, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 3, "size_in_bytes": 470 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_1": { "primaries": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 260, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 34, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 2, "total_time_in_millis": 137 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 12 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 4212, "terms_memory_in_bytes": 3020, "stored_fields_memory_in_bytes": 624, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "doc_values_memory_in_bytes": 184, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 51943830, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 2, "size_in_bytes": 373 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 260, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 34, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 2, "total_time_in_millis": 137 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 12 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "percolate": { "total": 0, "time_in_millis": 0, "current": 0, "memory_size_in_bytes": -1, "memory_size": "-1b", "queries": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 4212, "terms_memory_in_bytes": 3020, "stored_fields_memory_in_bytes": 624, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "doc_values_memory_in_bytes": 184, "index_writer_memory_in_bytes": 0, "index_writer_max_memory_in_bytes": 51943830, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0 }, "translog": { "operations": 2, "size_in_bytes": 373 }, "suggest": { "total": 0, "time_in_millis": 0, "current": 0 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/5.4.2.json000066400000000000000000001147501511562765300253150ustar00rootroot00000000000000{ "_shards": { "total": 26, "successful": 13, "failed": 0 }, "_all": { "primaries": { "docs": { "count": 76, "deleted": 0 }, "store": { "size_in_bytes": 128534, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 78, "index_time_in_millis": 1598, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 272629760 }, "refresh": { "total": 15, "total_time_in_millis": 1361, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 26, "total_time_in_millis": 124 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 13, "memory_in_bytes": 56523, "terms_memory_in_bytes": 44419, "stored_fields_memory_in_bytes": 4056, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 2880, "points_memory_in_bytes": 652, "doc_values_memory_in_bytes": 4516, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 78, "size_in_bytes": 56679 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 76, "deleted": 0 }, "store": { "size_in_bytes": 128534, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 78, "index_time_in_millis": 1598, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 272629760 }, "refresh": { "total": 15, "total_time_in_millis": 1361, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 26, "total_time_in_millis": 124 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 13, "memory_in_bytes": 56523, "terms_memory_in_bytes": 44419, "stored_fields_memory_in_bytes": 4056, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 2880, "points_memory_in_bytes": 652, "doc_values_memory_in_bytes": 4516, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 78, "size_in_bytes": 56679 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "indices": { ".monitoring-es-2-2017.08.23": { "primaries": { "docs": { "count": 65, "deleted": 0 }, "store": { "size_in_bytes": 68917, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 65, "index_time_in_millis": 106, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 390, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 15 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 23830, "terms_memory_in_bytes": 18474, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 320, "points_memory_in_bytes": 648, "doc_values_memory_in_bytes": 3452, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 65, "size_in_bytes": 37990 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 65, "deleted": 0 }, "store": { "size_in_bytes": 68917, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 65, "index_time_in_millis": 106, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 390, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 15 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 23830, "terms_memory_in_bytes": 18474, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 320, "points_memory_in_bytes": 648, "doc_values_memory_in_bytes": 3452, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 65, "size_in_bytes": 37990 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, ".monitoring-data-2": { "primaries": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 4226, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 4, "index_time_in_millis": 13, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 2, "total_time_in_millis": 74, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 3, "total_time_in_millis": 2 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1335, "terms_memory_in_bytes": 787, "stored_fields_memory_in_bytes": 312, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 236, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 4, "size_in_bytes": 6738 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 4226, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 4, "index_time_in_millis": 13, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 2, "total_time_in_millis": 74, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 3, "total_time_in_millis": 2 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1335, "terms_memory_in_bytes": 787, "stored_fields_memory_in_bytes": 312, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 236, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 4, "size_in_bytes": 6738 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_2": { "primaries": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 11909, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 12, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 3, "total_time_in_millis": 42, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 8, "total_time_in_millis": 4 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 7764, "terms_memory_in_bytes": 5976, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 576, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 276, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 494 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 3, "deleted": 0 }, "store": { "size_in_bytes": 11909, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 12, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 3, "total_time_in_millis": 42, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 8, "total_time_in_millis": 4 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 7764, "terms_memory_in_bytes": 5976, "stored_fields_memory_in_bytes": 936, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 576, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 276, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 494 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_1": { "primaries": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 8038, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 46, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 2, "total_time_in_millis": 84, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 7, "total_time_in_millis": 94 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 5176, "terms_memory_in_bytes": 3984, "stored_fields_memory_in_bytes": 624, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 184, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 2, "size_in_bytes": 389 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 2, "deleted": 0 }, "store": { "size_in_bytes": 8038, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 46, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 104857600 }, "refresh": { "total": 2, "total_time_in_millis": 84, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 7, "total_time_in_millis": 94 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 5176, "terms_memory_in_bytes": 3984, "stored_fields_memory_in_bytes": 624, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 184, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 2, "size_in_bytes": 389 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, ".watches": { "primaries": { "docs": { "count": 4, "deleted": 0 }, "store": { "size_in_bytes": 35444, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 4, "index_time_in_millis": 1421, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 5, "total_time_in_millis": 771, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 9 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 4, "memory_in_bytes": 18418, "terms_memory_in_bytes": 15198, "stored_fields_memory_in_bytes": 1248, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 1600, "points_memory_in_bytes": 4, "doc_values_memory_in_bytes": 368, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 4, "size_in_bytes": 11068 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 4, "deleted": 0 }, "store": { "size_in_bytes": 35444, "throttle_time_in_millis": 0 }, "indexing": { "index_total": 4, "index_time_in_millis": 1421, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 5, "total_time_in_millis": 771, "listeners": 0 }, "flush": { "total": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 9 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 4, "memory_in_bytes": 18418, "terms_memory_in_bytes": 15198, "stored_fields_memory_in_bytes": 1248, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 1600, "points_memory_in_bytes": 4, "doc_values_memory_in_bytes": 368, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 4, "size_in_bytes": 11068 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/7.17.3.json000066400000000000000000001065741511562765300254110ustar00rootroot00000000000000{ "_shards": { "total": 7, "successful": 4, "failed": 0 }, "_all": { "primaries": { "docs": { "count": 43, "deleted": 0 }, "shard_stats": { "total_count": 4 }, "store": { "size_in_bytes": 39917364, "total_data_set_size_in_bytes": 39917364, "reserved_in_bytes": 0 }, "indexing": { "index_total": 43, "index_time_in_millis": 741, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 43, "query_time_in_millis": 71, "query_current": 0, "fetch_total": 43, "fetch_time_in_millis": 96, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 60, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 83886080 }, "refresh": { "total": 18, "total_time_in_millis": 76, "external_total": 15, "external_total_time_in_millis": 73, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 150 }, "warmer": { "current": 0, "total": 11, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 7, "memory_in_bytes": 9996, "terms_memory_in_bytes": 5600, "stored_fields_memory_in_bytes": 3480, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 532, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 487, "uncommitted_operations": 3, "uncommitted_size_in_bytes": 487, "earliest_last_modified_age": 35855 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 43, "deleted": 0 }, "shard_stats": { "total_count": 4 }, "store": { "size_in_bytes": 39917364, "total_data_set_size_in_bytes": 39917364, "reserved_in_bytes": 0 }, "indexing": { "index_total": 43, "index_time_in_millis": 741, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 43, "query_time_in_millis": 71, "query_current": 0, "fetch_total": 43, "fetch_time_in_millis": 96, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 60, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 83886080 }, "refresh": { "total": 18, "total_time_in_millis": 76, "external_total": 15, "external_total_time_in_millis": 73, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 150 }, "warmer": { "current": 0, "total": 11, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 7, "memory_in_bytes": 9996, "terms_memory_in_bytes": 5600, "stored_fields_memory_in_bytes": 3480, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 532, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 487, "uncommitted_operations": 3, "uncommitted_size_in_bytes": 487, "earliest_last_modified_age": 35855 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "indices": { ".geoip_databases": { "uuid": "AbBfA8RRRLGfbIPGIAQs7A", "primaries": { "docs": { "count": 40, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 39904033, "total_data_set_size_in_bytes": 39904033, "reserved_in_bytes": 0 }, "indexing": { "index_total": 40, "index_time_in_millis": 738, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 43, "query_time_in_millis": 71, "query_current": 0, "fetch_total": 43, "fetch_time_in_millis": 96, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 60, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 9, "total_time_in_millis": 50, "external_total": 6, "external_total_time_in_millis": 45, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 150 }, "warmer": { "current": 0, "total": 5, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 4, "memory_in_bytes": 4368, "terms_memory_in_bytes": 2048, "stored_fields_memory_in_bytes": 2016, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 304, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 406186 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 40, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 39904033, "total_data_set_size_in_bytes": 39904033, "reserved_in_bytes": 0 }, "indexing": { "index_total": 40, "index_time_in_millis": 738, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 43, "query_time_in_millis": 71, "query_current": 0, "fetch_total": 43, "fetch_time_in_millis": 96, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 60, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 9, "total_time_in_millis": 50, "external_total": 6, "external_total_time_in_millis": 45, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 150 }, "warmer": { "current": 0, "total": 5, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 4, "memory_in_bytes": 4368, "terms_memory_in_bytes": 2048, "stored_fields_memory_in_bytes": 2016, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 304, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 406186 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_2": { "uuid": "JnYmxu4DStKroXSy6BHYcQ", "primaries": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4459, "total_data_set_size_in_bytes": 4459, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 9, "external_total": 3, "external_total_time_in_millis": 10, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 146, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 146, "earliest_last_modified_age": 36079 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4459, "total_data_set_size_in_bytes": 4459, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 9, "external_total": 3, "external_total_time_in_millis": 10, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 146, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 146, "earliest_last_modified_age": 36079 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_1": { "uuid": "9itiRXMuQym8eTdKygV3Kw", "primaries": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4413, "total_data_set_size_in_bytes": 4413, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 8, "external_total": 3, "external_total_time_in_millis": 8, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 140, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 140, "earliest_last_modified_age": 36364 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4413, "total_data_set_size_in_bytes": 4413, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 8, "external_total": 3, "external_total_time_in_millis": 8, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 140, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 140, "earliest_last_modified_age": 36364 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "foo_3": { "uuid": "a2-lU19tRuKUPgarKpqoCg", "primaries": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4459, "total_data_set_size_in_bytes": 4459, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 9, "external_total": 3, "external_total_time_in_millis": 10, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 146, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 146, "earliest_last_modified_age": 35855 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 1, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 4459, "total_data_set_size_in_bytes": 4459, "reserved_in_bytes": 0 }, "indexing": { "index_total": 1, "index_time_in_millis": 1, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 3, "total_time_in_millis": 9, "external_total": 3, "external_total_time_in_millis": 10, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 2, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 1, "memory_in_bytes": 1876, "terms_memory_in_bytes": 1184, "stored_fields_memory_in_bytes": 488, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 128, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 76, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 1, "size_in_bytes": 146, "uncommitted_operations": 1, "uncommitted_size_in_bytes": 146, "earliest_last_modified_age": 35855 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/alias/000077500000000000000000000000001511562765300250355ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/alias/1.7.6.json000066400000000000000000000004631511562765300264040ustar00rootroot00000000000000{ "foo_1": { "aliases": {} }, "foo_2": { "aliases": { "foo_alias_2_1": {} } }, "foo_3": { "aliases": { "foo_alias_3_1": { "index_routing": "title", "search_routing": "title", "is_write_index": true }, "foo_alias_3_2": {} } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/alias/2.4.5.json000066400000000000000000000004631511562765300264010ustar00rootroot00000000000000{ "foo_1": { "aliases": {} }, "foo_2": { "aliases": { "foo_alias_2_1": {} } }, "foo_3": { "aliases": { "foo_alias_3_1": { "index_routing": "title", "search_routing": "title", "is_write_index": true }, "foo_alias_3_2": {} } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/alias/5.4.2.json000066400000000000000000000004631511562765300264010ustar00rootroot00000000000000{ "foo_1": { "aliases": {} }, "foo_2": { "aliases": { "foo_alias_2_1": {} } }, "foo_3": { "aliases": { "foo_alias_3_1": { "index_routing": "title", "search_routing": "title", "is_write_index": true }, "foo_alias_3_2": {} } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/alias/7.17.3.json000066400000000000000000000004631511562765300264700ustar00rootroot00000000000000{ "foo_1": { "aliases": {} }, "foo_2": { "aliases": { "foo_alias_2_1": {} } }, "foo_3": { "aliases": { "foo_alias_3_1": { "index_routing": "title", "search_routing": "title", "is_write_index": true }, "foo_alias_3_2": {} } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/shards/000077500000000000000000000000001511562765300252305ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/shards/1.7.6.json000066400000000000000000000000001511562765300265620ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/shards/2.4.5.json000066400000000000000000000000001511562765300265570ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/shards/5.4.2.json000066400000000000000000000000001511562765300265570ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices/shards/7.17.3.json000066400000000000000000001625041511562765300266700ustar00rootroot00000000000000{ "_shards": { "total": 7, "successful": 4, "failed": 0 }, "_all": { "primaries": { "docs": { "count": 42, "deleted": 0 }, "shard_stats": { "total_count": 4 }, "store": { "size_in_bytes": 37307787, "total_data_set_size_in_bytes": 37307787, "reserved_in_bytes": 0 }, "indexing": { "index_total": 42, "index_time_in_millis": 871, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 40, "query_time_in_millis": 57, "query_current": 0, "fetch_total": 40, "fetch_time_in_millis": 69, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 48, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 83886080 }, "refresh": { "total": 21, "total_time_in_millis": 117, "external_total": 18, "external_total_time_in_millis": 108, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 310 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 10, "memory_in_bytes": 14824, "terms_memory_in_bytes": 8480, "stored_fields_memory_in_bytes": 4944, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 640, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 760, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 5, "size_in_bytes": 663, "uncommitted_operations": 5, "uncommitted_size_in_bytes": 663, "earliest_last_modified_age": 113316 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 42, "deleted": 0 }, "shard_stats": { "total_count": 4 }, "store": { "size_in_bytes": 37307787, "total_data_set_size_in_bytes": 37307787, "reserved_in_bytes": 0 }, "indexing": { "index_total": 42, "index_time_in_millis": 871, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 40, "query_time_in_millis": 57, "query_current": 0, "fetch_total": 40, "fetch_time_in_millis": 69, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 48, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 83886080 }, "refresh": { "total": 21, "total_time_in_millis": 117, "external_total": 18, "external_total_time_in_millis": 108, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 310 }, "warmer": { "current": 0, "total": 14, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 10, "memory_in_bytes": 14824, "terms_memory_in_bytes": 8480, "stored_fields_memory_in_bytes": 4944, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 640, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 760, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 5, "size_in_bytes": 663, "uncommitted_operations": 5, "uncommitted_size_in_bytes": 663, "earliest_last_modified_age": 113316 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } } }, "indices": { ".geoip_databases": { "uuid": "IsOzig1JQMCfZuc7g8SOAg", "primaries": { "docs": { "count": 37, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 37286036, "total_data_set_size_in_bytes": 37286036, "reserved_in_bytes": 0 }, "indexing": { "index_total": 37, "index_time_in_millis": 866, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 40, "query_time_in_millis": 57, "query_current": 0, "fetch_total": 40, "fetch_time_in_millis": 69, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 48, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 10, "total_time_in_millis": 83, "external_total": 7, "external_total_time_in_millis": 74, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 310 }, "warmer": { "current": 0, "total": 6, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 5444, "terms_memory_in_bytes": 2560, "stored_fields_memory_in_bytes": 2504, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 380, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 368771 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 37, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 37286036, "total_data_set_size_in_bytes": 37286036, "reserved_in_bytes": 0 }, "indexing": { "index_total": 37, "index_time_in_millis": 866, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 40, "query_time_in_millis": 57, "query_current": 0, "fetch_total": 40, "fetch_time_in_millis": 69, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 48, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 10, "total_time_in_millis": 83, "external_total": 7, "external_total_time_in_millis": 74, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 310 }, "warmer": { "current": 0, "total": 6, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 5444, "terms_memory_in_bytes": 2560, "stored_fields_memory_in_bytes": 2504, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 380, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 368771 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "shards": { "0": [ { "routing": { "state": "STARTED", "primary": true, "node": "49nZYKtiQdGg7Nl_sVsI1A", "relocating_node": null }, "docs": { "count": 37, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 37286036, "total_data_set_size_in_bytes": 37286036, "reserved_in_bytes": 0 }, "indexing": { "index_total": 37, "index_time_in_millis": 866, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 40, "query_time_in_millis": 57, "query_current": 0, "fetch_total": 40, "fetch_time_in_millis": 69, "fetch_current": 0, "scroll_total": 3, "scroll_time_in_millis": 48, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 10, "total_time_in_millis": 83, "external_total": 7, "external_total_time_in_millis": 74, "listeners": 0 }, "flush": { "total": 4, "periodic": 0, "total_time_in_millis": 310 }, "warmer": { "current": 0, "total": 6, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 5, "memory_in_bytes": 5444, "terms_memory_in_bytes": 2560, "stored_fields_memory_in_bytes": 2504, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 380, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 368771 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 }, "commit": { "id": "ayutyc88HNkuMxrlQx+QJQ==", "generation": 5, "user_data": { "local_checkpoint": "36", "max_unsafe_auto_id_timestamp": "-1", "min_retained_seq_no": "0", "translog_uuid": "uHHipeYSRWagBp9SvdugxQ", "es_version": "7.17.3", "history_uuid": "pKm7Fyd5SM2Vk0p70nUFxQ", "max_seq_no": "36" }, "num_docs": 37 }, "seq_no": { "max_seq_no": 36, "local_checkpoint": 36, "global_checkpoint": 36 }, "retention_leases": { "primary_term": 1, "version": 2, "leases": [ { "id": "peer_recovery/49nZYKtiQdGg7Nl_sVsI1A", "retaining_seq_no": 37, "timestamp": 1740539414034, "source": "peer recovery" } ] }, "shard_path": { "state_path": "/usr/share/elasticsearch/data/nodes/0", "data_path": "/usr/share/elasticsearch/data/nodes/0", "is_custom_data_path": false } } ] } }, "foo_2": { "uuid": "MZ5nKNufSKW166LJZwViOA", "primaries": { "docs": { "count": 3, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 12925, "total_data_set_size_in_bytes": 12925, "reserved_in_bytes": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 3, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 5, "total_time_in_millis": 20, "external_total": 5, "external_total_time_in_millis": 20, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 5628, "terms_memory_in_bytes": 3552, "stored_fields_memory_in_bytes": 1464, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 228, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 328, "uncommitted_operations": 3, "uncommitted_size_in_bytes": 328, "earliest_last_modified_age": 216554 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 3, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 12925, "total_data_set_size_in_bytes": 12925, "reserved_in_bytes": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 3, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 5, "total_time_in_millis": 20, "external_total": 5, "external_total_time_in_millis": 20, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 5628, "terms_memory_in_bytes": 3552, "stored_fields_memory_in_bytes": 1464, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 228, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 328, "uncommitted_operations": 3, "uncommitted_size_in_bytes": 328, "earliest_last_modified_age": 216554 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "shards": { "0": [ { "routing": { "state": "STARTED", "primary": true, "node": "49nZYKtiQdGg7Nl_sVsI1A", "relocating_node": null }, "docs": { "count": 3, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 12925, "total_data_set_size_in_bytes": 12925, "reserved_in_bytes": 0 }, "indexing": { "index_total": 3, "index_time_in_millis": 3, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 5, "total_time_in_millis": 20, "external_total": 5, "external_total_time_in_millis": 20, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 4, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 3, "memory_in_bytes": 5628, "terms_memory_in_bytes": 3552, "stored_fields_memory_in_bytes": 1464, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 384, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 228, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 3, "size_in_bytes": 328, "uncommitted_operations": 3, "uncommitted_size_in_bytes": 328, "earliest_last_modified_age": 216554 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 }, "commit": { "id": "ayutyc88HNkuMxrlQx+QYQ==", "generation": 2, "user_data": { "local_checkpoint": "-1", "max_unsafe_auto_id_timestamp": "-1", "translog_uuid": "QIAvj1xfQhmQLxHTu3WGPg", "es_version": "7.17.3", "history_uuid": "Nix01i4nRCK_2kf1L9wvEQ", "max_seq_no": "-1" }, "num_docs": 0 }, "seq_no": { "max_seq_no": 2, "local_checkpoint": 2, "global_checkpoint": 2 }, "retention_leases": { "primary_term": 1, "version": 2, "leases": [ { "id": "peer_recovery/49nZYKtiQdGg7Nl_sVsI1A", "retaining_seq_no": 3, "timestamp": 1740539559101, "source": "peer recovery" } ] }, "shard_path": { "state_path": "/usr/share/elasticsearch/data/nodes/0", "data_path": "/usr/share/elasticsearch/data/nodes/0", "is_custom_data_path": false } } ] } }, "foo_1": { "uuid": "YLfhQzgdQjSXzTRY3SbmvQ", "primaries": { "docs": { "count": 2, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 8600, "total_data_set_size_in_bytes": 8600, "reserved_in_bytes": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 2, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 4, "total_time_in_millis": 14, "external_total": 4, "external_total_time_in_millis": 14, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 3, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 3752, "terms_memory_in_bytes": 2368, "stored_fields_memory_in_bytes": 976, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 256, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 152, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 2, "size_in_bytes": 225, "uncommitted_operations": 2, "uncommitted_size_in_bytes": 225, "earliest_last_modified_age": 231434 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 2, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 8600, "total_data_set_size_in_bytes": 8600, "reserved_in_bytes": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 2, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 4, "total_time_in_millis": 14, "external_total": 4, "external_total_time_in_millis": 14, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 3, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 3752, "terms_memory_in_bytes": 2368, "stored_fields_memory_in_bytes": 976, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 256, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 152, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 2, "size_in_bytes": 225, "uncommitted_operations": 2, "uncommitted_size_in_bytes": 225, "earliest_last_modified_age": 231434 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "shards": { "0": [ { "routing": { "state": "STARTED", "primary": true, "node": "49nZYKtiQdGg7Nl_sVsI1A", "relocating_node": null }, "docs": { "count": 2, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 8600, "total_data_set_size_in_bytes": 8600, "reserved_in_bytes": 0 }, "indexing": { "index_total": 2, "index_time_in_millis": 2, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 4, "total_time_in_millis": 14, "external_total": 4, "external_total_time_in_millis": 14, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 3, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 2, "memory_in_bytes": 3752, "terms_memory_in_bytes": 2368, "stored_fields_memory_in_bytes": 976, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 256, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 152, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 2, "size_in_bytes": 225, "uncommitted_operations": 2, "uncommitted_size_in_bytes": 225, "earliest_last_modified_age": 231434 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 }, "commit": { "id": "ayutyc88HNkuMxrlQx+QTA==", "generation": 2, "user_data": { "local_checkpoint": "-1", "max_unsafe_auto_id_timestamp": "-1", "translog_uuid": "51Z-lHIBTniDwpVm8I6whg", "es_version": "7.17.3", "history_uuid": "Usf7yScRQ2yUV8IqOg4Hew", "max_seq_no": "-1" }, "num_docs": 0 }, "seq_no": { "max_seq_no": 1, "local_checkpoint": 1, "global_checkpoint": 1 }, "retention_leases": { "primary_term": 1, "version": 2, "leases": [ { "id": "peer_recovery/49nZYKtiQdGg7Nl_sVsI1A", "retaining_seq_no": 2, "timestamp": 1740539530087, "source": "peer recovery" } ] }, "shard_path": { "state_path": "/usr/share/elasticsearch/data/nodes/0", "data_path": "/usr/share/elasticsearch/data/nodes/0", "is_custom_data_path": false } } ] } }, "foo_3": { "uuid": "vZ_oz414QQuoBXUVCD_Dew", "primaries": { "docs": { "count": 0, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 226, "total_data_set_size_in_bytes": 226, "reserved_in_bytes": 0 }, "indexing": { "index_total": 0, "index_time_in_millis": 0, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 2, "total_time_in_millis": 0, "external_total": 2, "external_total_time_in_millis": 0, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 1, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 0, "memory_in_bytes": 0, "terms_memory_in_bytes": 0, "stored_fields_memory_in_bytes": 0, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 0, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 113316 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "total": { "docs": { "count": 0, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 226, "total_data_set_size_in_bytes": 226, "reserved_in_bytes": 0 }, "indexing": { "index_total": 0, "index_time_in_millis": 0, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 2, "total_time_in_millis": 0, "external_total": 2, "external_total_time_in_millis": 0, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 1, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 0, "memory_in_bytes": 0, "terms_memory_in_bytes": 0, "stored_fields_memory_in_bytes": 0, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 0, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 113316 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 } }, "shards": { "0": [ { "routing": { "state": "STARTED", "primary": true, "node": "49nZYKtiQdGg7Nl_sVsI1A", "relocating_node": null }, "docs": { "count": 0, "deleted": 0 }, "shard_stats": { "total_count": 1 }, "store": { "size_in_bytes": 226, "total_data_set_size_in_bytes": 226, "reserved_in_bytes": 0 }, "indexing": { "index_total": 0, "index_time_in_millis": 0, "index_current": 0, "index_failed": 0, "delete_total": 0, "delete_time_in_millis": 0, "delete_current": 0, "noop_update_total": 0, "is_throttled": false, "throttle_time_in_millis": 0 }, "get": { "total": 0, "time_in_millis": 0, "exists_total": 0, "exists_time_in_millis": 0, "missing_total": 0, "missing_time_in_millis": 0, "current": 0 }, "search": { "open_contexts": 0, "query_total": 0, "query_time_in_millis": 0, "query_current": 0, "fetch_total": 0, "fetch_time_in_millis": 0, "fetch_current": 0, "scroll_total": 0, "scroll_time_in_millis": 0, "scroll_current": 0, "suggest_total": 0, "suggest_time_in_millis": 0, "suggest_current": 0 }, "merges": { "current": 0, "current_docs": 0, "current_size_in_bytes": 0, "total": 0, "total_time_in_millis": 0, "total_docs": 0, "total_size_in_bytes": 0, "total_stopped_time_in_millis": 0, "total_throttled_time_in_millis": 0, "total_auto_throttle_in_bytes": 20971520 }, "refresh": { "total": 2, "total_time_in_millis": 0, "external_total": 2, "external_total_time_in_millis": 0, "listeners": 0 }, "flush": { "total": 0, "periodic": 0, "total_time_in_millis": 0 }, "warmer": { "current": 0, "total": 1, "total_time_in_millis": 0 }, "query_cache": { "memory_size_in_bytes": 0, "total_count": 0, "hit_count": 0, "miss_count": 0, "cache_size": 0, "cache_count": 0, "evictions": 0 }, "fielddata": { "memory_size_in_bytes": 0, "evictions": 0 }, "completion": { "size_in_bytes": 0 }, "segments": { "count": 0, "memory_in_bytes": 0, "terms_memory_in_bytes": 0, "stored_fields_memory_in_bytes": 0, "term_vectors_memory_in_bytes": 0, "norms_memory_in_bytes": 0, "points_memory_in_bytes": 0, "doc_values_memory_in_bytes": 0, "index_writer_memory_in_bytes": 0, "version_map_memory_in_bytes": 0, "fixed_bit_set_memory_in_bytes": 0, "max_unsafe_auto_id_timestamp": -1, "file_sizes": {} }, "translog": { "operations": 0, "size_in_bytes": 55, "uncommitted_operations": 0, "uncommitted_size_in_bytes": 55, "earliest_last_modified_age": 113316 }, "request_cache": { "memory_size_in_bytes": 0, "evictions": 0, "hit_count": 0, "miss_count": 0 }, "recovery": { "current_as_source": 0, "current_as_target": 0, "throttle_time_in_millis": 0 }, "commit": { "id": "ayutyc88HNkuMxrlQx+QfA==", "generation": 2, "user_data": { "local_checkpoint": "-1", "max_unsafe_auto_id_timestamp": "-1", "translog_uuid": "SUtrptGpQbyon3pd9E9NgQ", "es_version": "7.17.3", "history_uuid": "TTAmsH-lTyWmq5G0-sqPfA", "max_seq_no": "-1" }, "num_docs": 0 }, "seq_no": { "max_seq_no": -1, "local_checkpoint": -1, "global_checkpoint": -1 }, "retention_leases": { "primary_term": 1, "version": 1, "leases": [ { "id": "peer_recovery/49nZYKtiQdGg7Nl_sVsI1A", "retaining_seq_no": 0, "timestamp": 1740539642139, "source": "peer recovery" } ] }, "shard_path": { "state_path": "/usr/share/elasticsearch/data/nodes/0", "data_path": "/usr/share/elasticsearch/data/nodes/0", "is_custom_data_path": false } } ] } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices_mappings/000077500000000000000000000000001511562765300256425ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices_mappings/7.8.0.json000066400000000000000000000013531511562765300272110ustar00rootroot00000000000000{ "facebook": { "mappings": { "properties": { "contact": { "properties": { "email": { "type": "text", "fields": { "raw": { "type": "keyword" } } }, "phone": { "type": "text" } } }, "name": { "type": "text", "fields": { "raw": { "type": "keyword" } } } } } }, "twitter": { "mappings": { "properties": { "email": { "type": "keyword" }, "phone": { "type": "keyword" } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices_mappings/counts.json000066400000000000000000000110671511562765300300550ustar00rootroot00000000000000{ "test-data-2023.01.20": { "mappings": { "properties": { "data": { "type": "object", "properties": { "field1": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field10": { "type": "long" }, "field2": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field3": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field4": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field5": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field6": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field7": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field8": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field9": { "type": "long" } } }, "data2": { "properties": { "field1": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field2": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field3": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field4": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field5": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "nested_field6": { "properties": { "field1": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field2": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field3": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field4": { "type": "text", "fields": { "keyword": { "type": "keyword", "ignore_above": 256 } } }, "field5": { "type": "long" } } } } } } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/indices_settings/000077500000000000000000000000001511562765300256645ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/indices_settings/6.5.4.json000066400000000000000000000027721511562765300272410ustar00rootroot00000000000000{ "viber": { "settings": { "index": { "creation_date": "1618593207186", "number_of_shards": "5", "number_of_replicas": "1", "uuid": "lWg86KTARzO3r7lELytT1Q", "version": { "created": "6050499" }, "provided_name": "viber" } } }, "instagram": { "settings": { "index": { "mapping": { "total_fields": { "limit": "10000" } }, "number_of_shards": "5", "blocks": { "read_only_allow_delete": "true" }, "provided_name": "instagram", "creation_date": "1618593203353", "number_of_replicas": "1", "uuid": "msb6eG7aT8GmNe-a4oyVtQ", "version": { "created": "6050499" } } } }, "twitter": { "settings": { "index": { "number_of_shards": "5", "blocks": { "read_only_allow_delete": "true" }, "provided_name": "twitter", "creation_date": "1618593193641", "number_of_replicas": "1", "uuid": "YRUT8t4aSkKsNmGl7K3y4Q", "version": { "created": "6050499" } } } }, "facebook": { "settings": { "index": { "creation_date": "1618593199101", "number_of_shards": "5", "number_of_replicas": "1", "uuid": "trZhb_YOTV-RWKitTYw81A", "version": { "created": "6050499" }, "provided_name": "facebook" } } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/nodestats/000077500000000000000000000000001511562765300243325ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/nodestats/5.6.16.json000066400000000000000000000150211511562765300257610ustar00rootroot00000000000000{"_nodes":{"total":1,"successful":1,"failed":0},"cluster_name":"elasticsearch","nodes":{"bVrN1HxvQLy795ZLNg2XNw":{"timestamp":1622148141237,"name":"bVrN1Hx","transport_address":"127.0.0.1:9300","host":"127.0.0.1","ip":"127.0.0.1:9300","roles":["master","data","ingest"],"indices":{"docs":{"count":5,"deleted":0},"store":{"size_in_bytes":5721,"throttle_time_in_millis":0},"indexing":{"index_total":5,"index_time_in_millis":39,"index_current":0,"index_failed":0,"delete_total":0,"delete_time_in_millis":0,"delete_current":0,"noop_update_total":0,"is_throttled":false,"throttle_time_in_millis":0},"get":{"total":0,"time_in_millis":0,"exists_total":0,"exists_time_in_millis":0,"missing_total":0,"missing_time_in_millis":0,"current":0},"search":{"open_contexts":0,"query_total":0,"query_time_in_millis":0,"query_current":0,"fetch_total":0,"fetch_time_in_millis":0,"fetch_current":0,"scroll_total":0,"scroll_time_in_millis":0,"scroll_current":0,"suggest_total":0,"suggest_time_in_millis":0,"suggest_current":0},"merges":{"current":0,"current_docs":0,"current_size_in_bytes":0,"total":0,"total_time_in_millis":0,"total_docs":0,"total_size_in_bytes":0,"total_stopped_time_in_millis":0,"total_throttled_time_in_millis":0,"total_auto_throttle_in_bytes":629145600},"refresh":{"total":65,"total_time_in_millis":86,"listeners":0},"flush":{"total":0,"total_time_in_millis":0},"warmer":{"current":0,"total":35,"total_time_in_millis":1},"query_cache":{"memory_size_in_bytes":0,"total_count":0,"hit_count":0,"miss_count":0,"cache_size":0,"cache_count":0,"evictions":0},"fielddata":{"memory_size_in_bytes":0,"evictions":0},"completion":{"size_in_bytes":0},"segments":{"count":5,"memory_in_bytes":12940,"terms_memory_in_bytes":9960,"stored_fields_memory_in_bytes":1560,"term_vectors_memory_in_bytes":0,"norms_memory_in_bytes":960,"points_memory_in_bytes":0,"doc_values_memory_in_bytes":460,"index_writer_memory_in_bytes":0,"version_map_memory_in_bytes":0,"fixed_bit_set_memory_in_bytes":0,"max_unsafe_auto_id_timestamp":-1,"file_sizes":{}},"translog":{"operations":5,"size_in_bytes":1743},"request_cache":{"memory_size_in_bytes":0,"evictions":0,"hit_count":0,"miss_count":0},"recovery":{"current_as_source":0,"current_as_target":0,"throttle_time_in_millis":0}},"os":{"timestamp":1622148141242,"cpu":{"percent":23,"load_average":{"1m":45.68,"5m":150.34,"15m":96.01}},"mem":{"total_in_bytes":33623236608,"free_in_bytes":7009173504,"used_in_bytes":26614063104,"free_percent":21,"used_percent":79},"swap":{"total_in_bytes":2147479552,"free_in_bytes":86630400,"used_in_bytes":2060849152}},"process":{"timestamp":1622148141242,"open_file_descriptors":308,"max_file_descriptors":1048576,"cpu":{"percent":8,"total_in_millis":14510},"mem":{"total_virtual_in_bytes":8293711872}},"jvm":{"timestamp":1622148141243,"uptime_in_millis":14845,"mem":{"heap_used_in_bytes":333706928,"heap_used_percent":16,"heap_committed_in_bytes":2077753344,"heap_max_in_bytes":2077753344,"non_heap_used_in_bytes":70212664,"non_heap_committed_in_bytes":75362304,"pools":{"young":{"used_in_bytes":53925336,"max_in_bytes":558432256,"peak_used_in_bytes":558432256,"peak_max_in_bytes":558432256},"survivor":{"used_in_bytes":69730304,"max_in_bytes":69730304,"peak_used_in_bytes":69730304,"peak_max_in_bytes":69730304},"old":{"used_in_bytes":210051288,"max_in_bytes":1449590784,"peak_used_in_bytes":210051288,"peak_max_in_bytes":1449590784}}},"threads":{"count":60,"peak_count":60},"gc":{"collectors":{"young":{"collection_count":2,"collection_time_in_millis":143},"old":{"collection_count":1,"collection_time_in_millis":109}}},"buffer_pools":{"direct":{"count":47,"used_in_bytes":252727869,"total_capacity_in_bytes":252727868},"mapped":{"count":5,"used_in_bytes":15007,"total_capacity_in_bytes":15007}},"classes":{"current_loaded_count":10502,"total_loaded_count":10502,"total_unloaded_count":0}},"thread_pool":{"bulk":{"threads":5,"queue":0,"active":0,"rejected":0,"largest":5,"completed":5},"fetch_shard_started":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"fetch_shard_store":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"flush":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"force_merge":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"generic":{"threads":4,"queue":0,"active":0,"rejected":0,"largest":4,"completed":38},"get":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"index":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"listener":{"threads":4,"queue":0,"active":0,"rejected":0,"largest":4,"completed":5},"management":{"threads":1,"queue":0,"active":1,"rejected":0,"largest":1,"completed":2},"refresh":{"threads":1,"queue":0,"active":0,"rejected":0,"largest":1,"completed":31},"search":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"snapshot":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"warmer":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0}},"fs":{"timestamp":1622148141244,"total":{"total_in_bytes":476630163456,"free_in_bytes":77533405184,"available_in_bytes":77533405184,"spins":"true"},"data":[{"path":"/usr/share/elasticsearch/data/nodes/0","mount":"/usr/share/elasticsearch/data (/dev/mapper/vg0-root)","type":"xfs","total_in_bytes":476630163456,"free_in_bytes":77533405184,"available_in_bytes":77533405184,"spins":"true"}],"io_stats":{"devices":[{"device_name":"dm-2","operations":2517,"read_operations":706,"write_operations":1811,"read_kilobytes":12916,"write_kilobytes":17760}],"total":{"operations":2517,"read_operations":706,"write_operations":1811,"read_kilobytes":12916,"write_kilobytes":17760}}},"transport":{"server_open":0,"rx_count":0,"rx_size_in_bytes":0,"tx_count":0,"tx_size_in_bytes":0},"http":{"current_open":1,"total_opened":16},"breakers":{"request":{"limit_size_in_bytes":1246652006,"limit_size":"1.1gb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"fielddata":{"limit_size_in_bytes":1246652006,"limit_size":"1.1gb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.03,"tripped":0},"in_flight_requests":{"limit_size_in_bytes":2077753344,"limit_size":"1.9gb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"parent":{"limit_size_in_bytes":1454427340,"limit_size":"1.3gb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0}},"script":{"compilations":0,"cache_evictions":0},"discovery":{"cluster_state_queue":{"total":0,"pending":0,"committed":0}},"ingest":{"total":{"count":0,"time_in_millis":0,"current":0,"failed":0},"pipelines":{}}}}}prometheus-elasticsearch-exporter-1.10.0/fixtures/nodestats/6.8.8.json000066400000000000000000000201431511562765300257060ustar00rootroot00000000000000{"_nodes":{"total":1,"successful":1,"failed":0},"cluster_name":"elasticsearch","nodes":{"9_P7yuiySjG7OAN6NRbBRA":{"timestamp":1622148180536,"name":"9_P7yui","transport_address":"172.17.0.2:9300","host":"172.17.0.2","ip":"172.17.0.2:9300","roles":["master","data","ingest"],"attributes":{"ml.machine_memory":"33623236608","xpack.installed":"true","ml.max_open_jobs":"20","ml.enabled":"true"},"indices":{"docs":{"count":5,"deleted":0},"store":{"size_in_bytes":7261},"indexing":{"index_total":5,"index_time_in_millis":38,"index_current":0,"index_failed":0,"delete_total":0,"delete_time_in_millis":0,"delete_current":0,"noop_update_total":0,"is_throttled":false,"throttle_time_in_millis":0},"get":{"total":0,"time_in_millis":0,"exists_total":0,"exists_time_in_millis":0,"missing_total":0,"missing_time_in_millis":0,"current":0},"search":{"open_contexts":0,"query_total":0,"query_time_in_millis":0,"query_current":0,"fetch_total":0,"fetch_time_in_millis":0,"fetch_current":0,"scroll_total":0,"scroll_time_in_millis":0,"scroll_current":0,"suggest_total":0,"suggest_time_in_millis":0,"suggest_current":0},"merges":{"current":0,"current_docs":0,"current_size_in_bytes":0,"total":0,"total_time_in_millis":0,"total_docs":0,"total_size_in_bytes":0,"total_stopped_time_in_millis":0,"total_throttled_time_in_millis":0,"total_auto_throttle_in_bytes":629145600},"refresh":{"total":65,"total_time_in_millis":103,"listeners":0},"flush":{"total":0,"periodic":0,"total_time_in_millis":0},"warmer":{"current":0,"total":35,"total_time_in_millis":0},"query_cache":{"memory_size_in_bytes":0,"total_count":0,"hit_count":0,"miss_count":0,"cache_size":0,"cache_count":0,"evictions":0},"fielddata":{"memory_size_in_bytes":0,"evictions":0},"completion":{"size_in_bytes":0},"segments":{"count":5,"memory_in_bytes":8490,"terms_memory_in_bytes":5945,"stored_fields_memory_in_bytes":1560,"term_vectors_memory_in_bytes":0,"norms_memory_in_bytes":640,"points_memory_in_bytes":5,"doc_values_memory_in_bytes":340,"index_writer_memory_in_bytes":0,"version_map_memory_in_bytes":0,"fixed_bit_set_memory_in_bytes":0,"max_unsafe_auto_id_timestamp":-1,"file_sizes":{}},"translog":{"operations":5,"size_in_bytes":3753,"uncommitted_operations":5,"uncommitted_size_in_bytes":3753,"earliest_last_modified_age":0},"request_cache":{"memory_size_in_bytes":0,"evictions":0,"hit_count":0,"miss_count":0},"recovery":{"current_as_source":0,"current_as_target":0,"throttle_time_in_millis":0}},"os":{"timestamp":1622148180547,"cpu":{"percent":30,"load_average":{"1m":27.55,"5m":134.28,"15m":92.65}},"mem":{"total_in_bytes":33623236608,"free_in_bytes":7651008512,"used_in_bytes":25972228096,"free_percent":23,"used_percent":77},"swap":{"total_in_bytes":2147479552,"free_in_bytes":109174784,"used_in_bytes":2038304768},"cgroup":{"cpuacct":{"control_group":"/","usage_nanos":33206615382},"cpu":{"control_group":"/","cfs_period_micros":100000,"cfs_quota_micros":-1,"stat":{"number_of_elapsed_periods":0,"number_of_times_throttled":0,"time_throttled_nanos":0}},"memory":{"control_group":"/","limit_in_bytes":"9223372036854771712","usage_in_bytes":"1634058240"}}},"process":{"timestamp":1622148180547,"open_file_descriptors":355,"max_file_descriptors":1048576,"cpu":{"percent":17,"total_in_millis":32810},"mem":{"total_virtual_in_bytes":7269961728}},"jvm":{"timestamp":1622148180548,"uptime_in_millis":16456,"mem":{"heap_used_in_bytes":660054016,"heap_used_percent":61,"heap_committed_in_bytes":1073741824,"heap_max_in_bytes":1073741824,"non_heap_used_in_bytes":108594112,"non_heap_committed_in_bytes":117964800,"pools":{"young":{"used_in_bytes":393216000,"max_in_bytes":0,"peak_used_in_bytes":559417344,"peak_max_in_bytes":0},"old":{"used_in_bytes":255827968,"max_in_bytes":1073741824,"peak_used_in_bytes":255827968,"peak_max_in_bytes":1073741824},"survivor":{"used_in_bytes":11010048,"max_in_bytes":0,"peak_used_in_bytes":47668160,"peak_max_in_bytes":0}}},"threads":{"count":54,"peak_count":54},"gc":{"collectors":{"young":{"collection_count":5,"collection_time_in_millis":80},"old":{"collection_count":0,"collection_time_in_millis":0}}},"buffer_pools":{"mapped":{"count":5,"used_in_bytes":15179,"total_capacity_in_bytes":15179},"direct":{"count":42,"used_in_bytes":168849056,"total_capacity_in_bytes":168849055},"mapped - 'non-volatile memory'":{"count":0,"used_in_bytes":0,"total_capacity_in_bytes":0}},"classes":{"current_loaded_count":16278,"total_loaded_count":16278,"total_unloaded_count":0}},"thread_pool":{"analyze":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ccr":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"fetch_shard_started":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"fetch_shard_store":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"flush":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"force_merge":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"generic":{"threads":5,"queue":0,"active":0,"rejected":0,"largest":5,"completed":87},"get":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"index":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"listener":{"threads":4,"queue":0,"active":0,"rejected":0,"largest":4,"completed":5},"management":{"threads":2,"queue":0,"active":1,"rejected":0,"largest":2,"completed":5},"ml_autodetect":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ml_datafeed":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ml_utility":{"threads":1,"queue":0,"active":0,"rejected":0,"largest":1,"completed":1},"refresh":{"threads":1,"queue":0,"active":0,"rejected":0,"largest":1,"completed":32},"rollup_indexing":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"search":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"search_throttled":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"security-token-key":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"snapshot":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"warmer":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"watcher":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"write":{"threads":5,"queue":0,"active":0,"rejected":0,"largest":5,"completed":5}},"fs":{"timestamp":1622148180551,"total":{"total_in_bytes":476630163456,"free_in_bytes":77532815360,"available_in_bytes":77532815360},"data":[{"path":"/usr/share/elasticsearch/data/nodes/0","mount":"/ (overlay)","type":"overlay","total_in_bytes":476630163456,"free_in_bytes":77532815360,"available_in_bytes":77532815360}],"io_stats":{}},"transport":{"server_open":0,"rx_count":0,"rx_size_in_bytes":0,"tx_count":0,"tx_size_in_bytes":0},"http":{"current_open":1,"total_opened":16},"breakers":{"request":{"limit_size_in_bytes":644245094,"limit_size":"614.3mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"fielddata":{"limit_size_in_bytes":644245094,"limit_size":"614.3mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.03,"tripped":0},"in_flight_requests":{"limit_size_in_bytes":1073741824,"limit_size":"1gb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"accounting":{"limit_size_in_bytes":1073741824,"limit_size":"1gb","estimated_size_in_bytes":8490,"estimated_size":"8.2kb","overhead":1.0,"tripped":0},"parent":{"limit_size_in_bytes":751619276,"limit_size":"716.7mb","estimated_size_in_bytes":8490,"estimated_size":"8.2kb","overhead":1.0,"tripped":0}},"script":{"compilations":1,"cache_evictions":0},"discovery":{},"ingest":{"total":{"count":0,"time_in_millis":0,"current":0,"failed":0},"pipelines":{"xpack_monitoring_2":{"count":0,"time_in_millis":0,"current":0,"failed":0,"processors":[{"script":{"count":0,"time_in_millis":0,"current":0,"failed":0}},{"rename":{"count":0,"time_in_millis":0,"current":0,"failed":0}},{"set":{"count":0,"time_in_millis":0,"current":0,"failed":0}},{"gsub":{"count":0,"time_in_millis":0,"current":0,"failed":0}}]},"xpack_monitoring_6":{"count":0,"time_in_millis":0,"current":0,"failed":0,"processors":[]}}},"adaptive_selection":{}}}}prometheus-elasticsearch-exporter-1.10.0/fixtures/nodestats/7.13.1.json000066400000000000000000000427611511562765300257660ustar00rootroot00000000000000{"_nodes":{"total":1,"successful":1,"failed":0},"cluster_name":"elasticsearch","nodes":{"byoDEtBRSRGZyMKaIpmhCQ":{"timestamp":1622732353195,"name":"aaf5a8a0bceb","transport_address":"172.17.0.2:9300","host":"172.17.0.2","ip":"172.17.0.2:9300","roles":["data","data_cold","data_content","data_frozen","data_hot","data_warm","ingest","master","ml","remote_cluster_client","transform"],"attributes":{"ml.machine_memory":"33623232512","xpack.installed":"true","transform.node":"true","ml.max_open_jobs":"512","ml.max_jvm_size":"788529152"},"indices":{"docs":{"count":5,"deleted":0},"store":{"size_in_bytes":22296,"total_data_set_size_in_bytes":22296,"reserved_in_bytes":0},"indexing":{"index_total":5,"index_time_in_millis":14,"index_current":0,"index_failed":0,"delete_total":0,"delete_time_in_millis":0,"delete_current":0,"noop_update_total":0,"is_throttled":false,"throttle_time_in_millis":0},"get":{"total":0,"time_in_millis":0,"exists_total":0,"exists_time_in_millis":0,"missing_total":0,"missing_time_in_millis":0,"current":0},"search":{"open_contexts":0,"query_total":0,"query_time_in_millis":0,"query_current":0,"fetch_total":0,"fetch_time_in_millis":0,"fetch_current":0,"scroll_total":0,"scroll_time_in_millis":0,"scroll_current":0,"suggest_total":0,"suggest_time_in_millis":0,"suggest_current":0},"merges":{"current":0,"current_docs":0,"current_size_in_bytes":0,"total":0,"total_time_in_millis":0,"total_docs":0,"total_size_in_bytes":0,"total_stopped_time_in_millis":0,"total_throttled_time_in_millis":0,"total_auto_throttle_in_bytes":125829120},"refresh":{"total":17,"total_time_in_millis":148,"external_total":17,"external_total_time_in_millis":150,"listeners":0},"flush":{"total":0,"periodic":0,"total_time_in_millis":0},"warmer":{"current":0,"total":11,"total_time_in_millis":0},"query_cache":{"memory_size_in_bytes":0,"total_count":0,"hit_count":0,"miss_count":0,"cache_size":0,"cache_count":0,"evictions":0},"fielddata":{"memory_size_in_bytes":0,"evictions":0},"completion":{"size_in_bytes":0},"segments":{"count":5,"memory_in_bytes":9380,"terms_memory_in_bytes":5920,"stored_fields_memory_in_bytes":2440,"term_vectors_memory_in_bytes":0,"norms_memory_in_bytes":640,"points_memory_in_bytes":0,"doc_values_memory_in_bytes":380,"index_writer_memory_in_bytes":0,"version_map_memory_in_bytes":0,"fixed_bit_set_memory_in_bytes":0,"max_unsafe_auto_id_timestamp":-1,"file_sizes":{}},"translog":{"operations":5,"size_in_bytes":773,"uncommitted_operations":5,"uncommitted_size_in_bytes":773,"earliest_last_modified_age":1118},"request_cache":{"memory_size_in_bytes":0,"evictions":0,"hit_count":0,"miss_count":0},"recovery":{"current_as_source":0,"current_as_target":0,"throttle_time_in_millis":0}},"os":{"timestamp":1622732353199,"cpu":{"percent":37,"load_average":{"1m":2.74,"5m":44.07,"15m":70.55}},"mem":{"total_in_bytes":33623232512,"free_in_bytes":12400742400,"used_in_bytes":21222490112,"free_percent":37,"used_percent":63},"swap":{"total_in_bytes":2147479552,"free_in_bytes":928747520,"used_in_bytes":1218732032},"cgroup":{"cpuacct":{"control_group":"/","usage_nanos":52445263941},"cpu":{"control_group":"/","cfs_period_micros":100000,"cfs_quota_micros":-1,"stat":{"number_of_elapsed_periods":0,"number_of_times_throttled":0,"time_throttled_nanos":0}},"memory":{"control_group":"/","limit_in_bytes":"9223372036854771712","usage_in_bytes":"1110376448"}}},"process":{"timestamp":1622732353199,"open_file_descriptors":314,"max_file_descriptors":1048576,"cpu":{"percent":19,"total_in_millis":50160},"mem":{"total_virtual_in_bytes":6819479552}},"jvm":{"timestamp":1622732353200,"uptime_in_millis":21844,"mem":{"heap_used_in_bytes":156194432,"heap_used_percent":19,"heap_committed_in_bytes":788529152,"heap_max_in_bytes":788529152,"non_heap_used_in_bytes":139526472,"non_heap_committed_in_bytes":142606336,"pools":{"young":{"used_in_bytes":54525952,"max_in_bytes":0,"peak_used_in_bytes":465567744,"peak_max_in_bytes":0},"old":{"used_in_bytes":71059968,"max_in_bytes":788529152,"peak_used_in_bytes":71059968,"peak_max_in_bytes":788529152},"survivor":{"used_in_bytes":30608512,"max_in_bytes":0,"peak_used_in_bytes":54525952,"peak_max_in_bytes":0}}},"threads":{"count":49,"peak_count":49},"gc":{"collectors":{"young":{"collection_count":11,"collection_time_in_millis":113},"old":{"collection_count":0,"collection_time_in_millis":0}}},"buffer_pools":{"mapped":{"count":5,"used_in_bytes":16868,"total_capacity_in_bytes":16868},"direct":{"count":33,"used_in_bytes":8811046,"total_capacity_in_bytes":8811045},"mapped - 'non-volatile memory'":{"count":0,"used_in_bytes":0,"total_capacity_in_bytes":0}},"classes":{"current_loaded_count":21909,"total_loaded_count":21909,"total_unloaded_count":0}},"thread_pool":{"analyze":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ccr":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"fetch_shard_started":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"fetch_shard_store":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"flush":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"force_merge":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"generic":{"threads":7,"queue":0,"active":0,"rejected":0,"largest":7,"completed":406},"get":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"listener":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"management":{"threads":2,"queue":0,"active":1,"rejected":0,"largest":2,"completed":9},"ml_datafeed":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ml_job_comms":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"ml_utility":{"threads":1,"queue":0,"active":0,"rejected":0,"largest":1,"completed":12},"refresh":{"threads":1,"queue":0,"active":0,"rejected":0,"largest":1,"completed":36},"rollup_indexing":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"search":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"search_throttled":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"searchable_snapshots_cache_fetch_async":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"searchable_snapshots_cache_prewarming":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"security-crypto":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"security-token-key":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"snapshot":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"system_read":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"system_write":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"transform_indexing":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"warmer":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"watcher":{"threads":0,"queue":0,"active":0,"rejected":0,"largest":0,"completed":0},"write":{"threads":8,"queue":0,"active":0,"rejected":0,"largest":8,"completed":9}},"fs":{"timestamp":1622732353202,"total":{"total_in_bytes":476630163456,"free_in_bytes":63425642496,"available_in_bytes":63425642496},"data":[{"path":"/usr/share/elasticsearch/data/nodes/0","mount":"/ (overlay)","type":"overlay","total_in_bytes":476630163456,"free_in_bytes":63425642496,"available_in_bytes":63425642496}],"io_stats":{}},"transport":{"server_open":0,"total_outbound_connections":0,"rx_count":0,"rx_size_in_bytes":0,"tx_count":0,"tx_size_in_bytes":0},"http":{"current_open":1,"total_opened":16,"clients":[{"id":789026726,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49438","last_uri":"/foo_2/type1/1?refresh=wait_for","opened_time_millis":1622732349747,"closed_time_millis":1622732350948,"last_request_time_millis":1622732349747,"request_count":1,"request_size_bytes":39},{"id":150912494,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49458","last_uri":"/_all/_stats","opened_time_millis":1622732353149,"closed_time_millis":1622732353149,"last_request_time_millis":1622732353149,"request_count":1,"request_size_bytes":0},{"id":1204144009,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49442","last_uri":"/foo_2/type1/2?refresh=wait_for","opened_time_millis":1622732350948,"closed_time_millis":1622732351948,"last_request_time_millis":1622732350948,"request_count":1,"request_size_bytes":39},{"id":832608635,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49402","last_uri":"/twitter","opened_time_millis":1622732343337,"closed_time_millis":1622732345338,"last_request_time_millis":1622732343337,"request_count":1,"request_size_bytes":0},{"id":1787075320,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49454","last_uri":"/_all/_settings","opened_time_millis":1622732353149,"closed_time_millis":1622732353149,"last_request_time_millis":1622732353149,"request_count":1,"request_size_bytes":0},{"id":1263458828,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49416","last_uri":"/viber","opened_time_millis":1622732346538,"closed_time_millis":1622732347139,"last_request_time_millis":1622732346538,"request_count":1,"request_size_bytes":0},{"id":186367096,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49450","last_uri":"/_cluster/health","opened_time_millis":1622732352949,"closed_time_millis":1622732352949,"last_request_time_millis":1622732352949,"request_count":1,"request_size_bytes":0},{"id":1263584333,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49398","last_uri":"/","opened_time_millis":1622732343337,"closed_time_millis":1622732343337,"last_request_time_millis":1622732343337,"request_count":1,"request_size_bytes":0},{"id":1290037325,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49420","last_uri":"/instagram/_settings","opened_time_millis":1622732347139,"closed_time_millis":1622732347339,"last_request_time_millis":1622732347139,"request_count":1,"request_size_bytes":124},{"id":170704265,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49462","last_uri":"/_nodes/stats","opened_time_millis":1622732353149,"last_request_time_millis":1622732353149,"request_count":1,"request_size_bytes":0},{"id":1002191851,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49428","last_uri":"/foo_1/type1/1?refresh=wait_for","opened_time_millis":1622732347539,"closed_time_millis":1622732348747,"last_request_time_millis":1622732347539,"request_count":1,"request_size_bytes":33},{"id":119489056,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49424","last_uri":"/twitter/_settings","opened_time_millis":1622732347339,"closed_time_millis":1622732347539,"last_request_time_millis":1622732347339,"request_count":1,"request_size_bytes":124},{"id":562495253,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49446","last_uri":"/foo_2/type1/3?refresh=wait_for","opened_time_millis":1622732351948,"closed_time_millis":1622732352949,"last_request_time_millis":1622732351948,"request_count":1,"request_size_bytes":39},{"id":1052374837,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49412","last_uri":"/instagram","opened_time_millis":1622732345938,"closed_time_millis":1622732346538,"last_request_time_millis":1622732345938,"request_count":1,"request_size_bytes":0},{"id":1677987869,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49408","last_uri":"/facebook","opened_time_millis":1622732345338,"closed_time_millis":1622732345938,"last_request_time_millis":1622732345338,"request_count":1,"request_size_bytes":0},{"id":977313322,"agent":"curl/7.68.0","local_address":"172.17.0.2:9200","remote_address":"172.17.0.1:49432","last_uri":"/foo_1/type1/2?refresh=wait_for","opened_time_millis":1622732348747,"closed_time_millis":1622732349747,"last_request_time_millis":1622732348747,"request_count":1,"request_size_bytes":33}]},"breakers":{"request":{"limit_size_in_bytes":473117491,"limit_size":"451.1mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"fielddata":{"limit_size_in_bytes":315411660,"limit_size":"300.7mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.03,"tripped":0},"in_flight_requests":{"limit_size_in_bytes":788529152,"limit_size":"752mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":2.0,"tripped":0},"model_inference":{"limit_size_in_bytes":394264576,"limit_size":"376mb","estimated_size_in_bytes":0,"estimated_size":"0b","overhead":1.0,"tripped":0},"accounting":{"limit_size_in_bytes":788529152,"limit_size":"752mb","estimated_size_in_bytes":9380,"estimated_size":"9.1kb","overhead":1.0,"tripped":0},"parent":{"limit_size_in_bytes":749102694,"limit_size":"714.3mb","estimated_size_in_bytes":156194432,"estimated_size":"148.9mb","overhead":1.0,"tripped":0}},"script":{"compilations":1,"cache_evictions":0,"compilation_limit_triggered":0},"discovery":{"cluster_state_queue":{"total":0,"pending":0,"committed":0},"published_cluster_states":{"full_states":2,"incompatible_diffs":0,"compatible_diffs":49}},"ingest":{"total":{"count":0,"time_in_millis":0,"current":0,"failed":0},"pipelines":{"xpack_monitoring_6":{"count":0,"time_in_millis":0,"current":0,"failed":0,"processors":[{"script":{"type":"script","stats":{"count":0,"time_in_millis":0,"current":0,"failed":0}}},{"gsub":{"type":"gsub","stats":{"count":0,"time_in_millis":0,"current":0,"failed":0}}}]},"xpack_monitoring_7":{"count":0,"time_in_millis":0,"current":0,"failed":0,"processors":[]}}},"adaptive_selection":{},"script_cache":{"sum":{"compilations":1,"cache_evictions":0,"compilation_limit_triggered":0},"contexts":[{"context":"aggregation_selector","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"aggs","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"aggs_combine","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"aggs_init","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"aggs_map","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"aggs_reduce","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"analysis","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"boolean_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"bucket_aggregation","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"date_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"double_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"filter","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"geo_point_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"ingest","compilations":1,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"ingest_template","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"interval","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"ip_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"keyword_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"long_field","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"moving-function","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"number_sort","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"painless_test","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"processor_conditional","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"score","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"script_heuristic","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"similarity","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"similarity_weight","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"string_sort","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"template","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"terms_set","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"update","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"watcher_condition","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"watcher_transform","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0},{"context":"xpack_template","compilations":0,"cache_evictions":0,"compilation_limit_triggered":0}]},"indexing_pressure":{"memory":{"current":{"combined_coordinating_and_primary_in_bytes":0,"coordinating_in_bytes":0,"primary_in_bytes":0,"replica_in_bytes":0,"all_in_bytes":0},"total":{"combined_coordinating_and_primary_in_bytes":1423,"coordinating_in_bytes":1423,"primary_in_bytes":1463,"replica_in_bytes":0,"all_in_bytes":1423,"coordinating_rejections":0,"primary_rejections":0,"replica_rejections":0},"limit_in_bytes":78852915}}}}}prometheus-elasticsearch-exporter-1.10.0/fixtures/settings-5.4.2.json000066400000000000000000000364741511562765300255430ustar00rootroot00000000000000{ "persistent": {}, "transient": {}, "defaults": { "cluster": { "routing": { "rebalance": { "enable": "ALL" }, "allocation": { "node_concurrent_incoming_recoveries": "2", "node_initial_primaries_recoveries": "4", "same_shard": { "host": "false" }, "total_shards_per_node": "-1", "type": "balanced", "disk": { "threshold_enabled": "true", "watermark": { "low": "85%", "high": "90%" }, "include_relocations": "true", "reroute_interval": "60s" }, "awareness": { "attributes": "" }, "balance": { "index": "0.55", "threshold": "1.0", "shard": "0.45" }, "enable": "ALL", "node_concurrent_outgoing_recoveries": "2", "allow_rebalance": "indices_all_active", "cluster_concurrent_rebalance": "2", "node_concurrent_recoveries": "2", "snapshot": { "relocation_enabled": "false" } } }, "indices": { "close": { "enable": "true" } }, "nodes": { "reconnect_interval": "10s" }, "blocks": { "read_only": "false" }, "service": { "slow_task_logging_threshold": "30s" }, "name": "elasticsearch", "info": { "update": { "interval": "30s", "timeout": "15s" } } }, "logger": { "level": "INFO" }, "bootstrap": { "ctrlhandler": "true", "memory_lock": "false", "system_call_filter": "true", "seccomp": "true" }, "processors": "4", "network": { "host": [ "_local_" ], "tcp": { "reuse_address": "true", "connect_timeout": "30s", "blocking": "false", "blocking_server": "false", "no_delay": "true", "blocking_client": "false", "keep_alive": "true", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "bind_host": [ "_local_" ], "server": "true", "breaker": { "inflight_requests": { "limit": "100%", "overhead": "1.0" } }, "publish_host": [ "_local_" ] }, "pidfile": "", "path": { "conf": "", "scripts": "", "logs": "/usr/share/elasticsearch/logs", "shared_data": "", "home": "/usr/share/elasticsearch" }, "default": { "path": { "logs": "", "conf": "" } }, "search": { "default_search_timeout": "-1", "highlight": { "term_vector_multi_value": "true" }, "low_level_cancellation": "false", "keep_alive_interval": "1m", "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "default_keep_alive": "5m" }, "security": { "manager": { "filter_bad_defaults": "true" } }, "repositories": { "fs": { "compress": "false", "chunk_size": "-1b", "location": "" }, "url": { "supported_protocols": [ "http", "https", "ftp", "file", "jar" ], "url": "http:" } }, "action": { "auto_create_index": "true", "search": { "shard_count": { "limit": "9223372036854775807" } }, "destructive_requires_name": "false", "master": { "force_local": "false" } }, "client": { "type": "node", "transport": { "ignore_cluster_name": "false", "nodes_sampler_interval": "5s", "sniff": "false", "ping_timeout": "5s" } }, "rest": { "action": { "multi": { "allow_explicit_index": "true" } } }, "cache": { "recycler": { "page": { "limit": { "heap": "10%" }, "type": "CONCURRENT", "weight": { "longs": "1.0", "ints": "1.0", "bytes": "1.0", "objects": "0.1" } } } }, "resource": { "reload": { "enabled": "true", "interval": { "low": "60s", "high": "5s", "medium": "30s" } } }, "thread_pool": { "force_merge": { "queue_size": "-1", "size": "1" }, "fetch_shard_started": { "core": "1", "max": "8", "keep_alive": "5m" }, "listener": { "queue_size": "-1", "size": "2" }, "index": { "queue_size": "200", "size": "4" }, "refresh": { "core": "1", "max": "2", "keep_alive": "5m" }, "generic": { "core": "4", "max": "128", "keep_alive": "30s" }, "warmer": { "core": "1", "max": "2", "keep_alive": "5m" }, "search": { "queue_size": "1000", "size": "7" }, "fetch_shard_store": { "core": "1", "max": "8", "keep_alive": "5m" }, "flush": { "core": "1", "max": "2", "keep_alive": "5m" }, "management": { "core": "1", "max": "5", "keep_alive": "5m" }, "get": { "queue_size": "1000", "size": "4" }, "bulk": { "queue_size": "200", "size": "4" }, "estimated_time_interval": "200ms", "snapshot": { "core": "1", "max": "2", "keep_alive": "5m" } }, "index": { "codec": "default", "store": { "type": "", "fs": { "fs_lock": "native" } } }, "monitor": { "jvm": { "gc": { "enabled": "true", "overhead": { "warn": "50", "debug": "10", "info": "25" }, "refresh_interval": "1s" }, "refresh_interval": "1s" }, "process": { "refresh_interval": "1s" }, "os": { "refresh_interval": "1s" }, "fs": { "refresh_interval": "1s" } }, "transport": { "tcp": { "reuse_address": "true", "connect_timeout": "30s", "compress": "false", "port": "9300-9400", "blocking_server": "false", "blocking_client": "false", "keep_alive": "true", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "ping_schedule": "-1", "publish_port": "-1", "connections_per_node": { "recovery": "2", "state": "1", "bulk": "3", "reg": "6", "ping": "1" }, "tcp_no_delay": "true", "tracer": { "exclude": [ "internal:discovery/zen/fd*", "cluster:monitor/nodes/liveness" ] }, "type": "", "netty": { "max_composite_buffer_components": "-1", "worker_count": "8", "receive_predictor_size": "512kb", "receive_predictor_max": "512kb", "receive_predictor_min": "512kb", "boss_count": "1", "max_cumulation_buffer_capacity": "-1b" }, "type.default": "netty4" }, "script": { "cache": { "max_size": "100", "expire": "0ms" }, "painless": { "regex": { "enabled": "false" } }, "legacy": { "default_lang": "groovy" }, "max_size_in_bytes": "65535", "update": "false", "max_compilations_per_minute": "15", "ingest": "false", "search": "false", "file": "true", "inline": "false", "auto_reload_enabled": "true", "engine": { "painless": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" }, "expression": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" }, "groovy": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "false", "file": "true", "inline": "false", "inline.update": "false", "stored.search": "false", "inline.aggs": "false", "file.search": "true", "stored": "false", "stored.ingest": "false", "stored.aggs": "false", "stored.update": "false", "inline.search": "false" }, "mustache": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" } }, "stored": "false", "aggs": "false" }, "node": { "data": "true", "enable_lucene_segment_infos_trace": "false", "local_storage": "true", "max_local_storage_nodes": "1", "name": "DK8-2Lc", "id": { "seed": "0" }, "add_lock_id_to_custom_path": "true", "portsfile": "false", "ingest": "true", "master": "true" }, "indices": { "cache": { "cleanup_interval": "1m" }, "mapping": { "dynamic_timeout": "30s" }, "memory": { "interval": "5s", "max_index_buffer_size": "-1b", "shard_inactive_time": "5m", "index_buffer_size": "10%", "min_index_buffer_size": "48mb" }, "breaker": { "request": { "limit": "60%", "type": "memory", "overhead": "1.0" }, "total": { "limit": "70%" }, "fielddata": { "limit": "60%", "type": "memory", "overhead": "1.03" }, "type": "hierarchy" }, "fielddata": { "cache": { "size": "-1b" } }, "query": { "bool": { "max_clause_count": "1024" }, "query_string": { "analyze_wildcard": "false", "allowLeadingWildcard": "true" } }, "recovery": { "recovery_activity_timeout": "1800000ms", "retry_delay_network": "5s", "internal_action_timeout": "15m", "retry_delay_state_sync": "500ms", "internal_action_long_timeout": "1800000ms", "max_bytes_per_sec": "40mb" }, "requests": { "cache": { "size": "1%", "expire": "0ms" } }, "store": { "delete": { "shard": { "timeout": "30s" } }, "throttle": { "type": "NONE", "max_bytes_per_sec": "0b" } }, "analysis": { "hunspell": { "dictionary": { "ignore_case": "false", "lazy": "false" } } }, "queries": { "cache": { "count": "10000", "size": "10%", "all_segments": "false" } }, "ttl": { "interval": "60s" } }, "discovery": { "type": "zen", "zen": { "commit_timeout": "30s", "no_master_block": "write", "join_retry_delay": "100ms", "join_retry_attempts": "3", "ping": { "unicast": { "concurrent_connects": "10", "hosts": { "resolve_timeout": "5s" } } }, "master_election": { "ignore_non_master_pings": "false", "wait_for_joins_timeout": "30000ms" }, "send_leave_request": "true", "ping_timeout": "3s", "join_timeout": "60000ms", "publish_diff": { "enable": "true" }, "minimum_master_nodes": "-1", "hosts_provider": null, "publish_timeout": "30s", "fd": { "connect_on_network_disconnect": "false", "ping_interval": "1s", "ping_retries": "3", "register_connection_listener": "true", "ping_timeout": "30s" }, "max_pings_from_another_master": "3" }, "initial_state_timeout": "30s" }, "tribe": { "name": "", "on_conflict": "any", "blocks": { "write": "false", "metadata": "false" } }, "http": { "tcp": { "reuse_address": "true", "keep_alive": "true", "blocking_server": "false", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "bind_host": [ "0.0.0.0" ], "cors": { "max-age": "1728000", "allow-origin": "", "allow-headers": "X-Requested-With,Content-Type,Content-Length", "allow-credentials": "false", "allow-methods": "OPTIONS,HEAD,GET,POST,PUT,DELETE", "enabled": "false" }, "max_chunk_size": "8kb", "compression_level": "3", "reset_cookies": "false", "max_initial_line_length": "4kb", "type": "", "pipelining": "true", "enabled": "true", "type.default": "netty4", "detailed_errors": { "enabled": "true" }, "content_type": { "required": "false" }, "port": "9200-9300", "host": [ "0.0.0.0" ], "publish_port": "-1", "max_header_size": "8kb", "pipelining.max_events": "10000", "tcp_no_delay": "true", "compression": "true", "publish_host": [ "0.0.0.0" ], "max_content_length": "100mb", "netty": { "receive_predictor_size": "64kb", "max_composite_buffer_components": "-1", "receive_predictor_max": "64kb", "worker_count": "8", "receive_predictor_min": "64kb", "max_cumulation_buffer_capacity": "-1b" } }, "gateway": { "recover_after_master_nodes": "0", "expected_nodes": "-1", "recover_after_data_nodes": "-1", "initial_shards": "quorum", "expected_data_nodes": "-1", "recover_after_time": "0ms", "expected_master_nodes": "-1", "recover_after_nodes": "-1" } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/settings-7.3.0.json000066400000000000000000000617201511562765300255320ustar00rootroot00000000000000{ "persistent": {}, "transient": {}, "defaults": { "cluster": { "max_voting_config_exclusions": "10", "auto_shrink_voting_configuration": "true", "election": { "duration": "500ms", "initial_timeout": "100ms", "max_timeout": "10s", "back_off_time": "100ms", "strategy": "supports_voting_only" }, "no_master_block": "write", "persistent_tasks": { "allocation": { "enable": "all", "recheck_interval": "30s" } }, "blocks": { "read_only_allow_delete": "false", "read_only": "false" }, "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "follower_lag": { "timeout": "90000ms" }, "routing": { "use_adaptive_replica_selection": "true", "rebalance": { "enable": "all" }, "allocation": { "node_concurrent_incoming_recoveries": "2", "node_initial_primaries_recoveries": "4", "same_shard": { "host": "false" }, "total_shards_per_node": "-1", "type": "balanced", "disk": { "threshold_enabled": "false", "watermark": { "low": "0.85", "flood_stage": "0.95", "high": "0.9" }, "include_relocations": "true", "reroute_interval": "60s" }, "awareness": { "attributes": [] }, "balance": { "index": "0.55", "threshold": "1.0", "shard": "0.45" }, "enable": "all", "node_concurrent_outgoing_recoveries": "2", "allow_rebalance": "indices_all_active", "cluster_concurrent_rebalance": "2", "node_concurrent_recoveries": "2" } }, "indices": { "tombstones": { "size": "500" }, "close": { "enable": "true" } }, "nodes": { "reconnect_interval": "10s" }, "service": { "slow_task_logging_threshold": "30s" }, "publish": { "timeout": "30000ms" }, "name": "docker-cluster", "fault_detection": { "leader_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" }, "follower_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" } }, "join": { "timeout": "60000ms" }, "max_shards_per_node": "1000", "initial_master_nodes": [], "info": { "update": { "interval": "30s", "timeout": "15s" } } }, "no": { "model": { "state": { "persist": "false" } } }, "logger": { "level": "INFO" }, "data_frame": { "task_thread_pool": { "queue_size": "4", "size": "4" } }, "bootstrap": { "memory_lock": "false", "system_call_filter": "true", "ctrlhandler": "true" }, "processors": "8", "ingest": { "geoip": { "cache_size": "1000" }, "grok": { "watchdog": { "max_execution_time": "1s", "interval": "1s" } } }, "network": { "host": [ "0.0.0.0" ], "tcp": { "reuse_address": "true", "keep_alive": "true", "connect_timeout": "30s", "receive_buffer_size": "-1b", "no_delay": "true", "send_buffer_size": "-1b" }, "bind_host": [ "0.0.0.0" ], "server": "true", "breaker": { "inflight_requests": { "limit": "100%", "overhead": "2.0" } }, "publish_host": [ "0.0.0.0" ] }, "pidfile": "", "path": { "data": [], "logs": "/usr/share/elasticsearch/logs", "shared_data": "", "home": "/usr/share/elasticsearch", "repo": [] }, "search": { "default_search_timeout": "-1", "highlight": { "term_vector_multi_value": "true" }, "default_allow_partial_results": "true", "max_open_scroll_context": "500", "max_buckets": "10000", "low_level_cancellation": "true", "keep_alive_interval": "1m", "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "default_keep_alive": "5m", "max_keep_alive": "24h" }, "security": { "manager": { "filter_bad_defaults": "true" } }, "ccr": { "wait_for_metadata_timeout": "60s", "indices": { "recovery": { "recovery_activity_timeout": "60s", "chunk_size": "1mb", "internal_action_timeout": "60s", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "5" } }, "auto_follow": { "wait_for_metadata_timeout": "60s" } }, "repositories": { "fs": { "compress": "false", "chunk_size": "9223372036854775807b", "location": "" }, "url": { "supported_protocols": [ "http", "https", "ftp", "file", "jar" ], "allowed_urls": [], "url": "http:" } }, "action": { "auto_create_index": "true", "search": { "shard_count": { "limit": "9223372036854775807" } }, "destructive_requires_name": "false" }, "client": { "type": "node", "transport": { "ignore_cluster_name": "false", "nodes_sampler_interval": "5s", "sniff": "false", "ping_timeout": "5s" } }, "xpack": { "flattened": { "enabled": "true" }, "watcher": { "execution": { "scroll": { "size": "0", "timeout": "" }, "default_throttle_period": "5s" }, "internal": { "ops": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" }, "search": { "default_timeout": "" } } }, "thread_pool": { "queue_size": "1000", "size": "40" }, "index": { "rest": { "direct_access": "" } }, "history": { "cleaner_service": { "enabled": "true" } }, "trigger": { "schedule": { "ticker": { "tick_interval": "500ms" } } }, "enabled": "true", "input": { "search": { "default_timeout": "" } }, "encrypt_sensitive_data": "false", "transform": { "search": { "default_timeout": "" } }, "stop": { "timeout": "30s" }, "watch": { "scroll": { "size": "0" } }, "bulk": { "concurrent_requests": "0", "flush_interval": "1s", "size": "1mb", "actions": "1" }, "actions": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" } } }, "data_frame": { "enabled": "true" }, "ilm": { "enabled": "true" }, "monitoring": { "collection": { "cluster": { "stats": { "timeout": "10s" } }, "node": { "stats": { "timeout": "10s" } }, "indices": [], "ccr": { "stats": { "timeout": "10s" } }, "index": { "stats": { "timeout": "10s" }, "recovery": { "active_only": "false", "timeout": "10s" } }, "interval": "10s", "enabled": "false", "ml": { "job": { "stats": { "timeout": "10s" } } } }, "history": { "duration": "168h" }, "elasticsearch": { "collection": { "enabled": "true" } }, "enabled": "true" }, "graph": { "enabled": "true" }, "rollup": { "enabled": "true", "task_thread_pool": { "queue_size": "4", "size": "4" } }, "sql": { "enabled": "true" }, "license": { "self_generated": { "type": "basic" } }, "logstash": { "enabled": "true" }, "notification": { "pagerduty": { "default_account": "" }, "email": { "default_account": "", "html": { "sanitization": { "allow": [ "body", "head", "_tables", "_links", "_blocks", "_formatting", "img:embedded" ], "disallow": [], "enabled": "true" } } }, "reporting": { "retries": "40", "interval": "15s" }, "jira": { "default_account": "" }, "slack": { "default_account": "" } }, "security": { "dls_fls": { "enabled": "true" }, "dls": { "bitset": { "cache": { "size": "50mb", "ttl": "168h" } } }, "transport": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "enabled": "true", "filter": { "always_allow_bound_address": "true" }, "encryption": { "algorithm": "AES/CTR/NoPadding" }, "audit": { "enabled": "false", "logfile": { "emit_node_id": "true", "emit_node_host_name": "false", "emit_node_name": "false", "events": { "emit_request_body": "false", "include": [ "ACCESS_DENIED", "ACCESS_GRANTED", "ANONYMOUS_ACCESS_DENIED", "AUTHENTICATION_FAILED", "CONNECTION_DENIED", "TAMPERED_REQUEST", "RUN_AS_DENIED", "RUN_AS_GRANTED" ], "exclude": [] }, "emit_node_host_address": "false" } }, "authc": { "password_hashing": { "algorithm": "bcrypt" }, "success_cache": { "size": "10000", "enabled": "true", "expire_after_access": "1h" }, "api_key": { "cache": { "hash_algo": "ssha256", "max_keys": "10000", "ttl": "24h" }, "delete": { "interval": "24h", "timeout": "-1" }, "enabled": "false", "hashing": { "algorithm": "pbkdf2" } }, "anonymous": { "authz_exception": "true", "roles": [], "username": "_anonymous" }, "run_as": { "enabled": "true" }, "reserved_realm": { "enabled": "true" }, "token": { "delete": { "interval": "30m", "timeout": "-1" }, "enabled": "false", "thread_pool": { "queue_size": "1000", "size": "1" }, "timeout": "20m" } }, "fips_mode": { "enabled": "false" }, "encryption_key": { "length": "128", "algorithm": "AES" }, "http": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "automata": { "max_determinized_states": "100000", "cache": { "size": "10000", "ttl": "48h", "enabled": "true" } }, "user": null, "authz": { "store": { "roles": { "index": { "cache": { "ttl": "20m", "max_size": "10000" } }, "cache": { "max_size": "10000" }, "negative_lookup_cache": { "max_size": "10000" }, "field_permissions": { "cache": { "max_size_in_bytes": "104857600" } } } } } }, "vectors": { "enabled": "true" }, "ccr": { "enabled": "true", "ccr_thread_pool": { "queue_size": "100", "size": "32" } }, "http": { "default_connection_timeout": "10s", "proxy": { "host": "", "scheme": "", "port": "0" }, "whitelist": [ "*" ], "default_read_timeout": "10s", "max_response_size": "10mb" }, "ml": { "utility_thread_pool": { "core": "1", "max": "2048", "keep_alive": "10m" }, "max_anomaly_records": "500", "enable_config_migration": "true", "max_open_jobs": "20", "min_disk_space_off_heap": "5gb", "node_concurrent_job_allocations": "2", "max_model_memory_limit": "0b", "enabled": "true", "max_lazy_ml_nodes": "0", "max_machine_memory_percent": "30", "autodetect_process": "true", "datafeed_thread_pool": { "core": "1", "max": "512", "keep_alive": "1m" }, "process_connect_timeout": "10s", "job_comms_thread_pool": { "core": "4", "max": "2048", "keep_alive": "1m" } } }, "rest": { "action": { "multi": { "allow_explicit_index": "true" } } }, "cache": { "recycler": { "page": { "limit": { "heap": "10%" }, "type": "CONCURRENT", "weight": { "longs": "1.0", "ints": "1.0", "bytes": "1.0", "objects": "0.1" } } } }, "reindex": { "remote": { "whitelist": [] } }, "resource": { "reload": { "enabled": "true", "interval": { "low": "60s", "high": "5s", "medium": "30s" } } }, "thread_pool": { "force_merge": { "queue_size": "-1", "size": "1" }, "fetch_shard_started": { "core": "1", "max": "16", "keep_alive": "5m" }, "listener": { "queue_size": "-1", "size": "4" }, "refresh": { "core": "1", "max": "4", "keep_alive": "5m" }, "generic": { "core": "4", "max": "128", "keep_alive": "30s" }, "warmer": { "core": "1", "max": "4", "keep_alive": "5m" }, "search": { "max_queue_size": "1000", "queue_size": "1000", "size": "13", "auto_queue_frame_size": "2000", "target_response_time": "1s", "min_queue_size": "1000" }, "fetch_shard_store": { "core": "1", "max": "16", "keep_alive": "5m" }, "flush": { "core": "1", "max": "4", "keep_alive": "5m" }, "management": { "core": "1", "max": "5", "keep_alive": "5m" }, "analyze": { "queue_size": "16", "size": "1" }, "get": { "queue_size": "1000", "size": "8" }, "estimated_time_interval": "200ms", "write": { "queue_size": "200", "size": "8" }, "snapshot": { "core": "1", "max": "4", "keep_alive": "5m" }, "search_throttled": { "max_queue_size": "100", "queue_size": "100", "size": "1", "auto_queue_frame_size": "200", "target_response_time": "1s", "min_queue_size": "100" } }, "index": { "codec": "default", "store": { "type": "", "fs": { "fs_lock": "native" }, "preload": [] } }, "monitor": { "jvm": { "gc": { "enabled": "true", "overhead": { "warn": "50", "debug": "10", "info": "25" }, "refresh_interval": "1s" }, "refresh_interval": "1s" }, "process": { "refresh_interval": "1s" }, "os": { "refresh_interval": "1s" }, "fs": { "refresh_interval": "1s" } }, "transport": { "tcp": { "reuse_address": "true", "connect_timeout": "30s", "compress": "false", "port": "9300-9400", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "bind_host": [], "connect_timeout": "30s", "compress": "false", "ping_schedule": "-1", "connections_per_node": { "recovery": "2", "state": "1", "bulk": "3", "reg": "6", "ping": "1" }, "tracer": { "include": [], "exclude": [ "internal:discovery/zen/fd*", "internal:coordination/fault_detection/*", "cluster:monitor/nodes/liveness" ] }, "type": "security4", "type.default": "netty4", "features": { "x-pack": "true" }, "port": "9300-9400", "host": [], "publish_port": "-1", "tcp_no_delay": "true", "publish_host": [], "netty": { "receive_predictor_size": "64kb", "receive_predictor_max": "64kb", "worker_count": "16", "receive_predictor_min": "64kb", "boss_count": "1" } }, "script": { "allowed_contexts": [], "max_compilations_rate": "75/5m", "cache": { "max_size": "100", "expire": "0ms" }, "painless": { "regex": { "enabled": "false" } }, "max_size_in_bytes": "65535", "allowed_types": [] }, "node": { "data": "true", "max_local_storage_nodes": "1", "store": { "allow_mmap": "true" }, "ingest": "true", "master": "true", "enable_lucene_segment_infos_trace": "false", "local_storage": "true", "name": "2c26cd7c415b", "id": { "seed": "0" }, "voting_only": "false", "attr": { "xpack": { "installed": "true" }, "ml": { "machine_memory": "8255340544", "max_open_jobs": "20" } }, "portsfile": "false", "ml": "true" }, "indices": { "lifecycle": { "poll_interval": "10m" }, "cache": { "cleanup_interval": "1m" }, "mapping": { "dynamic_timeout": "30s" }, "memory": { "interval": "5s", "max_index_buffer_size": "-1", "shard_inactive_time": "5m", "index_buffer_size": "10%", "min_index_buffer_size": "48mb" }, "breaker": { "request": { "limit": "60%", "type": "memory", "overhead": "1.0" }, "total": { "limit": "95%", "use_real_memory": "true" }, "accounting": { "limit": "100%", "overhead": "1.0" }, "fielddata": { "limit": "40%", "type": "memory", "overhead": "1.03" }, "type": "hierarchy" }, "fielddata": { "cache": { "size": "-1b" } }, "query": { "bool": { "max_clause_count": "1024" }, "query_string": { "analyze_wildcard": "false", "allowLeadingWildcard": "true" } }, "recovery": { "recovery_activity_timeout": "1800000ms", "retry_delay_network": "5s", "internal_action_timeout": "15m", "retry_delay_state_sync": "500ms", "internal_action_long_timeout": "1800000ms", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "2" }, "requests": { "cache": { "size": "1%", "expire": "0ms" } }, "store": { "delete": { "shard": { "timeout": "30s" } } }, "analysis": { "hunspell": { "dictionary": { "ignore_case": "false", "lazy": "false" } } }, "queries": { "cache": { "count": "10000", "size": "10%", "all_segments": "false" } } }, "plugin": { "mandatory": [] }, "discovery": { "seed_hosts": [], "unconfigured_bootstrap_timeout": "3s", "request_peers_timeout": "3000ms", "zen": { "commit_timeout": "30s", "no_master_block": "write", "join_retry_delay": "100ms", "join_retry_attempts": "3", "ping": { "unicast": { "concurrent_connects": "10", "hosts": [], "hosts.resolve_timeout": "5s" } }, "master_election": { "ignore_non_master_pings": "false", "wait_for_joins_timeout": "30000ms" }, "send_leave_request": "true", "ping_timeout": "3s", "bwc_ping_timeout": "3s", "join_timeout": "60000ms", "publish_diff": { "enable": "true" }, "publish": { "max_pending_cluster_states": "25" }, "minimum_master_nodes": "-1", "unsafe_rolling_upgrades_enabled": "true", "hosts_provider": [], "publish_timeout": "30s", "fd": { "connect_on_network_disconnect": "false", "ping_interval": "1s", "ping_retries": "3", "register_connection_listener": "true", "ping_timeout": "30s" }, "max_pings_from_another_master": "3" }, "initial_state_timeout": "30s", "cluster_formation_warning_timeout": "10000ms", "seed_providers": [], "type": "single-node", "seed_resolver": { "max_concurrent_resolvers": "10", "timeout": "5s" }, "find_peers_interval": "1000ms" }, "http": { "tcp": { "reuse_address": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "no_delay": "true", "send_buffer_size": "-1b" }, "bind_host": [], "cors": { "max-age": "1728000", "allow-origin": "", "allow-headers": "X-Requested-With,Content-Type,Content-Length", "allow-credentials": "false", "allow-methods": "OPTIONS,HEAD,GET,POST,PUT,DELETE", "enabled": "false" }, "max_chunk_size": "8kb", "compression_level": "3", "reset_cookies": "false", "max_initial_line_length": "4kb", "max_warning_header_count": "-1", "type": "security4", "pipelining": { "max_events": "10000" }, "max_warning_header_size": "-1b", "type.default": "netty4", "detailed_errors": { "enabled": "true" }, "content_type": { "required": "true" }, "port": "9200-9300", "host": [], "publish_port": "-1", "max_header_size": "8kb", "tcp_no_delay": "true", "compression": "true", "read_timeout": "0ms", "publish_host": [], "max_content_length": "100mb", "netty": { "receive_predictor_size": "64kb", "max_composite_buffer_components": "69905", "worker_count": "16" } }, "gateway": { "recover_after_master_nodes": "0", "expected_nodes": "-1", "recover_after_data_nodes": "-1", "expected_data_nodes": "-1", "recover_after_time": "0ms", "expected_master_nodes": "-1", "recover_after_nodes": "-1" } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/settings-8.9.1-watermark.json000066400000000000000000001100301511562765300275220ustar00rootroot00000000000000{ "persistent": { "cluster": { "routing": { "allocation": { "disk": { "watermark": { "low": "88%", "flood_stage": "96%", "high": "92%" } } } } } }, "transient": {}, "defaults": { "cluster": { "max_voting_config_exclusions": "10", "auto_shrink_voting_configuration": "true", "discovery_configuration_check": { "interval": "30000ms" }, "election": { "duration": "500ms", "initial_timeout": "100ms", "max_timeout": "10s", "back_off_time": "100ms", "strategy": "supports_voting_only" }, "no_master_block": "write", "persistent_tasks": { "allocation": { "enable": "all", "recheck_interval": "30s" } }, "blocks": { "read_only_allow_delete": "false", "read_only": "false" }, "remote": { "initial_connect_timeout": "30s", "node": { "attr": "" }, "connections_per_cluster": "3" }, "follower_lag": { "timeout": "90000ms" }, "routing": { "use_adaptive_replica_selection": "true", "rebalance": { "enable": "all" }, "allocation": { "enforce_default_tier_preference": "true", "node_concurrent_incoming_recoveries": "2", "node_initial_primaries_recoveries": "4", "desired_balance": { "progress_log_interval": "1m", "undesired_allocations": { "log_interval": "1h", "threshold": "0.1" } }, "same_shard": { "host": "false" }, "total_shards_per_node": "-1", "type": "desired_balance", "disk": { "threshold_enabled": "true", "reroute_interval": "60s", "watermark": { "flood_stage": { "frozen": "95%", "frozen.max_headroom": "20GB", "max_headroom": "-1" }, "high": { "max_headroom": "-1" }, "low": { "max_headroom": "-1" }, "enable_for_single_data_node": "true" } }, "awareness": { "attributes": [] }, "balance": { "disk_usage": "2.0E-11", "index": "0.55", "threshold": "1.0", "shard": "0.45", "write_load": "10.0" }, "enable": "all", "node_concurrent_outgoing_recoveries": "2", "allow_rebalance": "indices_all_active", "cluster_concurrent_rebalance": "2", "node_concurrent_recoveries": "2" } }, "indices": { "tombstones": { "size": "500" }, "close": { "enable": "true" } }, "join_validation": { "cache_timeout": "60s" }, "max_shards_per_node.frozen": "3000", "nodes": { "reconnect_interval": "10s" }, "service": { "master_service_starvation_logging_threshold": "5m", "slow_master_task_logging_threshold": "10s", "slow_task_logging_threshold": "30s" }, "publish": { "timeout": "30000ms", "info_timeout": "10000ms" }, "name": "docker-cluster", "fault_detection": { "leader_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" }, "follower_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" } }, "max_shards_per_node": "1000", "initial_master_nodes": [], "deprecation_indexing": { "enabled": "true", "x_opaque_id_used": { "enabled": "true" } }, "snapshot": { "info": { "max_concurrent_fetches": "5" } }, "info": { "update": { "interval": "30s", "timeout": "15s" } } }, "stack": { "templates": { "enabled": "true" } }, "time_series": { "poll_interval": "5m" }, "readiness": { "port": "-1" }, "logger": { "level": "INFO" }, "bootstrap": { "memory_lock": "false", "ctrlhandler": "true" }, "health_node": { "transport_action_timeout": "5s" }, "ingest": { "user_agent": { "cache_size": "1000" }, "geoip": { "cache_size": "1000", "downloader": { "endpoint": "https://geoip.elastic.co/v1/database", "poll": { "interval": "3d" }, "eager": { "download": "false" }, "enabled": "true" } }, "grok": { "watchdog": { "max_execution_time": "1s", "interval": "1s" } } }, "network": { "host": [ "0.0.0.0" ], "tcp": { "reuse_address": "true", "keep_count": "-1", "keep_interval": "-1", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [ "0.0.0.0" ], "server": "true", "breaker": { "inflight_requests": { "limit": "100%", "overhead": "2.0" } }, "publish_host": [ "0.0.0.0" ] }, "searchable_snapshots": { "blob_cache": { "periodic_cleanup": { "interval": "1h", "batch_size": "100", "pit_keep_alive": "10m", "retention_period": "1h" } } }, "path": { "data": [], "logs": "/usr/share/elasticsearch/logs", "shared_data": "", "home": "/usr/share/elasticsearch", "repo": [] }, "search": { "default_search_timeout": "-1", "max_open_scroll_context": "500", "max_buckets": "65536", "max_async_search_response_size": "10mb", "keep_alive_interval": "1m", "max_keep_alive": "24h", "highlight": { "term_vector_multi_value": "true" }, "default_allow_partial_results": "true", "low_level_cancellation": "true", "allow_expensive_queries": "true", "check_ccs_compatibility": "false", "default_keep_alive": "5m", "aggs": { "rewrite_to_filter_by_filter": "true", "tdigest_execution_hint": "DEFAULT" } }, "security": { "manager": { "filter_bad_defaults": "true" } }, "ccr": { "wait_for_metadata_timeout": "60s", "indices": { "recovery": { "recovery_activity_timeout": "60s", "chunk_size": "1mb", "internal_action_timeout": "60s", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "5" } }, "auto_follow": { "wait_for_metadata_timeout": "60s" } }, "repositories": { "fs": { "chunk_size": "9223372036854775807b", "location": "" }, "url": { "supported_protocols": [ "http", "https", "ftp", "file", "jar" ], "allowed_urls": [], "url": "http:" } }, "action": { "auto_create_index": "true", "search": { "pre_filter_shard_size": { "default": "128" }, "shard_count": { "limit": "9223372036854775807" } }, "destructive_requires_name": "true" }, "client": { "type": "node" }, "enrich": { "max_force_merge_attempts": "3", "cleanup_period": "15m", "fetch_size": "10000", "cache_size": "1000", "coordinator_proxy": { "max_concurrent_requests": "8", "max_lookups_per_request": "128", "queue_capacity": "1024" }, "max_concurrent_policy_executions": "50" }, "xpack": { "watcher": { "execution": { "scroll": { "size": "0", "timeout": "" }, "default_throttle_period": "5s" }, "internal": { "ops": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" }, "search": { "default_timeout": "" } } }, "thread_pool": { "queue_size": "1000", "size": "40" }, "index": { "rest": { "direct_access": "" } }, "use_ilm_index_management": "true", "trigger": { "schedule": { "ticker": { "tick_interval": "500ms" } } }, "enabled": "true", "input": { "search": { "default_timeout": "" } }, "encrypt_sensitive_data": "false", "transform": { "search": { "default_timeout": "" } }, "stop": { "timeout": "30s" }, "watch": { "scroll": { "size": "0" } }, "bulk": { "concurrent_requests": "0", "flush_interval": "1s", "size": "1mb", "actions": "1" }, "actions": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" } } }, "eql": { "enabled": "true" }, "ent_search": { "enabled": "true" }, "monitoring": { "migration": { "decommission_alerts": "false" }, "collection": { "cluster": { "stats": { "timeout": "10s" } }, "node": { "stats": { "timeout": "10s" } }, "indices": [], "ccr": { "stats": { "timeout": "10s" } }, "enrich": { "stats": { "timeout": "10s" } }, "index": { "stats": { "timeout": "10s" }, "recovery": { "active_only": "false", "timeout": "10s" } }, "interval": "10s", "enabled": "false", "ml": { "job": { "stats": { "timeout": "10s" } } } }, "history": { "duration": "168h" }, "elasticsearch": { "collection": { "enabled": "true" } }, "templates": { "enabled": "true" } }, "graph": { "enabled": "true" }, "searchable": { "snapshot": { "allocate_on_rolling_restart": "false", "cache": { "range_size": "32mb", "sync": { "max_files": "10000", "interval": "60s", "shutdown_timeout": "10s" }, "recovery_range_size": "128kb" }, "shared_cache": { "recovery_range_size": "128kb", "region_size": "16mb", "size": "0", "min_time_delta": "60s", "decay": { "interval": "60s" }, "size.max_headroom": "-1", "range_size": "16mb", "max_freq": "100" } } }, "rollup": { "task_thread_pool": { "queue_size": "-1", "size": "1" } }, "searchable_snapshots": { "cache_fetch_async_thread_pool": { "core": "0", "max": "24", "keep_alive": "30s" }, "cache_prewarming_thread_pool": { "core": "0", "max": "16", "keep_alive": "30s" } }, "downsample": { "thread_pool": { "queue_size": "256", "size": "1" } }, "license": { "upload": { "types": [ "standard", "gold", "platinum", "enterprise", "trial" ] }, "self_generated": { "type": "basic" } }, "notification": { "pagerduty": { "default_account": "" }, "webhook": { "additional_token_enabled": "false" }, "email": { "account": { "domain_allowlist": [ "*" ] }, "default_account": "", "html": { "sanitization": { "allow": [ "body", "head", "_tables", "_links", "_blocks", "_formatting", "img:embedded" ], "disallow": [], "enabled": "true" } } }, "reporting": { "retries": "40", "warning": { "enabled": "true" }, "interval": "15s" }, "jira": { "default_account": "" }, "slack": { "default_account": "" } }, "security": { "operator_privileges": { "enabled": "false" }, "dls_fls": { "enabled": "true" }, "dls": { "bitset": { "cache": { "size": "10%", "ttl": "2h" } } }, "transport": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "ssl": { "diagnose": { "trust": "true" } }, "enabled": "false", "enrollment": { "enabled": "false" }, "filter": { "always_allow_bound_address": "true" }, "encryption": { "algorithm": "AES/CTR/NoPadding" }, "audit": { "enabled": "false", "logfile": { "emit_cluster_name": "false", "emit_node_id": "true", "emit_node_name": "false", "emit_node_host_address": "false", "emit_cluster_uuid": "true", "emit_node_host_name": "false", "events": { "emit_request_body": "false", "include": [ "ACCESS_DENIED", "ACCESS_GRANTED", "ANONYMOUS_ACCESS_DENIED", "AUTHENTICATION_FAILED", "CONNECTION_DENIED", "TAMPERED_REQUEST", "RUN_AS_DENIED", "RUN_AS_GRANTED", "SECURITY_CONFIG_CHANGE" ], "exclude": [] } } }, "authc": { "password_hashing": { "algorithm": "BCRYPT" }, "success_cache": { "size": "10000", "enabled": "true", "expire_after_access": "1h" }, "api_key": { "doc_cache": { "ttl": "5m" }, "cache": { "hash_algo": "ssha256", "max_keys": "25000", "ttl": "24h" }, "delete": { "interval": "24h", "retention_period": "7d", "timeout": "-1" }, "enabled": "true", "hashing": { "algorithm": "PBKDF2" } }, "anonymous": { "authz_exception": "true", "roles": [], "username": "_anonymous" }, "run_as": { "enabled": "true" }, "reserved_realm": { "enabled": "true" }, "service_token": { "cache": { "hash_algo": "ssha256", "max_tokens": "100000", "ttl": "20m" } }, "token": { "delete": { "interval": "30m", "timeout": "-1" }, "enabled": "false", "timeout": "20m" } }, "autoconfiguration": { "enabled": "true" }, "fips_mode": { "enabled": "false" }, "encryption_key": { "length": "128", "algorithm": "AES" }, "http": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "automata": { "max_determinized_states": "100000", "cache": { "size": "10000", "ttl": "48h", "enabled": "true" } }, "user": null, "authz": { "timer": { "indices": { "enabled": "false", "threshold": { "warn": "200ms", "debug": "20ms", "info": "100ms" } } }, "store": { "privileges": { "cache": { "ttl": "24h", "max_size": "10000" } }, "roles": { "has_privileges": { "cache": { "max_size": "1000" } }, "cache": { "max_size": "10000" }, "negative_lookup_cache": { "max_size": "10000" }, "field_permissions": { "cache": { "max_size_in_bytes": "104857600" } } } } } }, "transform": { "num_transform_failure_retries": "10", "transform_scheduler_frequency": "1s" }, "ccr": { "enabled": "true", "ccr_thread_pool": { "queue_size": "100", "size": "32" } }, "idp": { "privileges": { "application": "", "cache": { "size": "100", "ttl": "90m" } }, "metadata": { "signing": { "keystore": { "alias": "" } } }, "slo_endpoint": { "post": "https:", "redirect": "https:" }, "defaults": { "nameid_format": "urn:oasis:names:tc:SAML:2.0:nameid-format:transient", "authn_expiry": "5m" }, "allowed_nameid_formats": [ "urn:oasis:names:tc:SAML:2.0:nameid-format:transient" ], "contact": { "given_name": "", "email": "", "surname": "" }, "organization": { "display_name": "", "name": "", "url": "http:" }, "sso_endpoint": { "post": "https:", "redirect": "https:" }, "entity_id": "", "signing": { "keystore": { "alias": "" } }, "sp": { "cache": { "size": "1000", "ttl": "60m" }, "wildcard": { "path": "wildcard_services.json" } }, "enabled": "false" }, "profiling": { "enabled": "true", "query": { "stacktrace": { "max_slices": "16" }, "details": { "max_slices": "16" }, "realtime": "true" }, "templates": { "enabled": "false" } }, "http": { "tcp": { "keep_alive": "true" }, "default_connection_timeout": "10s", "proxy": { "host": "", "scheme": "", "port": "0" }, "connection_pool_ttl": "-1", "max_response_size": "10mb", "whitelist": [ "*" ], "default_read_timeout": "10s" }, "autoscaling": { "memory": { "monitor": { "timeout": "15s" } } }, "applications": { "behavioral_analytics": { "ingest": { "bulk_processor": { "max_events_per_bulk": "500", "flush_delay": "10s", "max_bytes_in_flight": "5%", "max_number_of_retries": "1" } } } }, "ml": { "utility_thread_pool": { "core": "1", "max": "2048", "keep_alive": "10m" }, "max_anomaly_records": "500", "enable_config_migration": "true", "max_open_jobs": "512", "delayed_data_check_freq": "15m", "min_disk_space_off_heap": "5gb", "allocated_processors_scale": "1", "model_repository": "https://ml-models.elastic.co", "use_auto_machine_memory_percent": "false", "inference_model": { "cache_size": "40%", "time_to_live": "5m" }, "nightly_maintenance_requests_per_second": "-1.0", "node_concurrent_job_allocations": "2", "max_model_memory_limit": "0b", "enabled": "true", "max_lazy_ml_nodes": "0", "max_ml_node_size": "0b", "max_machine_memory_percent": "30", "persist_results_max_retries": "20", "autodetect_process": "true", "datafeed_thread_pool": { "core": "1", "max": "512", "keep_alive": "1m" }, "max_inference_processors": "50", "native_inference_comms_thread_pool": { "core": "3", "max": "324", "keep_alive": "1m" }, "process_connect_timeout": "10s", "job_comms_thread_pool": { "core": "4", "max": "2048", "keep_alive": "1m" } } }, "rest": { "action": { "multi": { "allow_explicit_index": "true" } } }, "cache": { "recycler": { "page": { "limit": { "heap": "10%" }, "type": "CONCURRENT", "weight": { "longs": "1.0", "ints": "1.0", "bytes": "1.0", "objects": "0.1" } } } }, "tracing": { "apm": { "sanitize_field_names": [ "password", "passwd", "pwd", "secret", "*key", "*token*", "*session*", "*credit*", "*card*", "*auth*", "*principal*", "set-cookie" ], "enabled": "false", "names": { "include": [], "exclude": [] } } }, "async_search": { "index_cleanup_interval": "1h" }, "reindex": { "remote": { "whitelist": [] } }, "resource": { "reload": { "enabled": "true", "interval": { "low": "60s", "high": "5s", "medium": "30s" } } }, "thread_pool": { "force_merge": { "queue_size": "-1", "size": "1" }, "search_coordination": { "queue_size": "1000", "size": "4" }, "snapshot_meta": { "core": "1", "max": "24", "keep_alive": "30s" }, "fetch_shard_started": { "core": "1", "max": "16", "keep_alive": "5m" }, "estimated_time_interval.warn_threshold": "5s", "scheduler": { "warn_threshold": "5s" }, "cluster_coordination": { "queue_size": "-1", "size": "1" }, "search": { "queue_size": "1000", "size": "13" }, "fetch_shard_store": { "core": "1", "max": "16", "keep_alive": "5m" }, "flush": { "core": "1", "max": "4", "keep_alive": "5m" }, "vectortile": { "queue_size": "-1", "size": "1" }, "get": { "queue_size": "1000", "size": "13" }, "system_read": { "queue_size": "2000", "size": "4" }, "system_critical_read": { "queue_size": "2000", "size": "4" }, "estimated_time_interval": "200ms", "write": { "queue_size": "10000", "size": "8" }, "system_critical_write": { "queue_size": "1500", "size": "4" }, "refresh": { "core": "1", "max": "4", "keep_alive": "5m" }, "repository_azure": { "core": "0", "max": "5", "keep_alive": "30s" }, "system_write": { "queue_size": "1000", "size": "4" }, "generic": { "core": "4", "max": "128", "keep_alive": "30s" }, "warmer": { "core": "1", "max": "4", "keep_alive": "5m" }, "auto_complete": { "queue_size": "100", "size": "2" }, "azure_event_loop": { "core": "0", "max": "1", "keep_alive": "30s" }, "profiling": { "core": "0", "max": "1", "keep_alive": "30m" }, "management": { "core": "1", "max": "5", "keep_alive": "5m" }, "analyze": { "queue_size": "16", "size": "1" }, "snapshot": { "core": "1", "max": "10", "keep_alive": "5m" }, "search_throttled": { "queue_size": "100", "size": "1" } }, "health": { "node": { "enabled": "true" }, "master_history": { "has_master_lookup_timeframe": "30s", "identity_changes_threshold": "4", "no_master_transitions_threshold": "4" }, "ilm": { "max_time_on_action": "1d", "max_time_on_step": "1d", "max_retries_per_step": "100" }, "reporting": { "local": { "monitor": { "interval": "30s" } } } }, "index": { "codec": "default", "recovery": { "type": "" }, "store": { "type": "", "fs": { "fs_lock": "native" }, "preload": [], "snapshot": { "uncached_chunk_size": "-1b", "cache": { "excluded_file_types": [] } } } }, "monitor": { "jvm": { "gc": { "enabled": "true", "overhead": { "warn": "50", "debug": "10", "info": "25" }, "refresh_interval": "1s" }, "refresh_interval": "1s" }, "process": { "refresh_interval": "1s" }, "os": { "refresh_interval": "1s" }, "fs": { "health": { "enabled": "true", "refresh_interval": "120s", "slow_path_logging_threshold": "5s" }, "refresh_interval": "1s" } }, "runtime_fields": { "grok": { "watchdog": { "max_execution_time": "1s", "interval": "1s" } } }, "cluster_state": { "document_page_size": "1mb" }, "transport": { "tcp": { "reuse_address": "true", "keep_count": "-1", "keep_interval": "-1", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [], "connect_timeout": "30s", "compress": "INDEXING_DATA", "ping_schedule": "-1", "connections_per_node": { "recovery": "2", "state": "1", "bulk": "3", "reg": "6", "ping": "1" }, "tracer": { "include": [], "exclude": [ "internal:coordination/fault_detection/*" ] }, "type": "", "slow_operation_logging_threshold": "5s", "type.default": "netty4", "rst_on_close": "false", "port": "9300-9399", "compression_scheme": "LZ4", "host": [], "publish_port": "-1", "publish_host": [], "netty": { "receive_predictor_size": "64kb", "receive_predictor_max": "64kb", "worker_count": "8", "receive_predictor_min": "64kb", "boss_count": "1" } }, "deprecation": { "skip_deprecated_settings": [] }, "script": { "allowed_contexts": [], "max_compilations_rate": "150/5m", "cache": { "max_size": "3000", "expire": "0ms" }, "painless": { "regex": { "enabled": "limited", "limit-factor": "6" } }, "max_size_in_bytes": "65535", "allowed_types": [], "disable_max_compilations_rate": "false" }, "indexing_pressure": { "memory": { "limit": "10%" } }, "node": { "bandwidth": { "recovery": { "disk": { "write": "-1", "read": "-1" }, "factor": { "write": "0.4", "read": "0.4" }, "operator": { "factor.read": "0.4", "factor.write": "0.4", "factor": "0.4", "factor.max_overcommit": "100.0" }, "network": "-1" } }, "enable_lucene_segment_infos_trace": "false", "roles": [ "data", "data_cold", "data_content", "data_frozen", "data_hot", "data_warm", "ingest", "master", "ml", "remote_cluster_client", "transform" ], "_internal": { "default_refresh_interval": "1s" }, "name": "e3ce5021e045", "external_id": "", "id": { "seed": "0" }, "processors": "8.0", "store": { "allow_mmap": "true" }, "attr": { "xpack": { "installed": "true" }, "ml": { "max_jvm_size": "1073741824", "allocated_processors": "8", "machine_memory": "2147483648", "allocated_processors_double": "8.0" } }, "portsfile": "false" }, "indices": { "replication": { "retry_timeout": "60s", "initial_retry_backoff_bound": "50ms" }, "cache": { "cleanup_interval": "1m" }, "mapping": { "dynamic_timeout": "30s", "max_in_flight_updates": "10" }, "memory": { "interval": "5s", "max_index_buffer_size": "-1", "shard_inactive_time": "5m", "index_buffer_size": "10%", "min_index_buffer_size": "48mb" }, "breaker": { "request": { "limit": "60%", "type": "memory", "overhead": "1.0" }, "total": { "limit": "95%", "use_real_memory": "true" }, "fielddata": { "limit": "40%", "type": "memory", "overhead": "1.03" }, "type": "hierarchy" }, "write_ack_delay_interval": "0ms", "query": { "bool": { "max_nested_depth": "30", "max_clause_count": "4096" }, "query_string": { "analyze_wildcard": "false", "allowLeadingWildcard": "true" } }, "id_field_data": { "enabled": "false" }, "recovery": { "internal_action_retry_timeout": "1m", "recovery_activity_timeout": "1800000ms", "retry_delay_network": "5s", "internal_action_timeout": "15m", "max_concurrent_snapshot_file_downloads_per_node": "25", "retry_delay_state_sync": "500ms", "max_concurrent_snapshot_file_downloads": "5", "internal_action_long_timeout": "1800000ms", "max_concurrent_operations": "1", "use_snapshots": "true", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "2" }, "requests": { "cache": { "size": "1%", "expire": "0ms" } }, "store": { "delete": { "shard": { "timeout": "30s" } }, "shard_lock_retry": { "interval": "1s", "timeout": "1m" } }, "analysis": { "hunspell": { "dictionary": { "ignore_case": "false", "lazy": "false" } } }, "queries": { "cache": { "count": "10000", "size": "10%", "all_segments": "false" } }, "lifecycle": { "poll_interval": "10m", "rollover": { "only_if_has_documents": "true" }, "step": { "master_timeout": "30s" }, "history_index_enabled": "true" }, "write_ack_delay_randomness_bound": "70ms", "fielddata": { "cache": { "size": "-1b" } } }, "master_history": { "max_age": "30m" }, "plugin": { "mandatory": [] }, "ingest_node": { "transport_action_timeout": "20s" }, "slm": { "health": { "failed_snapshot_warn_threshold": "5" }, "minimum_interval": "15m", "retention_schedule": "0 30 1 * * ?", "retention_duration": "1h", "history_index_enabled": "true" }, "discovery": { "seed_hosts": [], "unconfigured_bootstrap_timeout": "3s", "request_peers_timeout": "3000ms", "initial_state_timeout": "30s", "cluster_formation_warning_timeout": "10000ms", "seed_providers": [], "type": "single-node", "seed_resolver": { "max_concurrent_resolvers": "10", "timeout": "5s" }, "find_peers_interval": "1000ms", "probe": { "connect_timeout": "30s", "handshake_timeout": "30s" } }, "http": { "cors": { "max-age": "1728000", "allow-origin": "", "allow-headers": "X-Requested-With,Content-Type,Content-Length,Authorization,Accept,User-Agent,X-Elastic-Client-Meta", "allow-credentials": "false", "allow-methods": "OPTIONS,HEAD,GET,POST,PUT,DELETE", "enabled": "false" }, "max_chunk_size": "8kb", "compression_level": "3", "max_initial_line_length": "4kb", "shutdown_grace_period": "0ms", "type": "", "pipelining": { "max_events": "10000" }, "type.default": "netty4", "host": [], "publish_port": "-1", "read_timeout": "0ms", "max_content_length": "100mb", "netty": { "receive_predictor_size": "64kb", "max_composite_buffer_components": "69905", "worker_count": "0" }, "tcp": { "reuse_address": "true", "keep_count": "-1", "keep_interval": "-1", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [], "client_stats": { "enabled": "true", "closed_channels": { "max_age": "5m", "max_count": "10000" } }, "reset_cookies": "false", "max_warning_header_count": "-1", "tracer": { "include": [], "exclude": [] }, "max_warning_header_size": "-1b", "detailed_errors": { "enabled": "true" }, "port": "9200-9300", "max_header_size": "16kb", "compression": "true", "publish_host": [] }, "write_load_forecaster": { "max_index_age": "7d" }, "gateway": { "recover_after_data_nodes": "-1", "expected_data_nodes": "-1", "write_dangling_indices_info": "true", "slow_write_logging_threshold": "10s", "recover_after_time": "0ms" }, "snapshot": { "refresh_repo_uuid_on_restore": "true", "max_concurrent_operations": "1000" } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/settings-merge-5.4.2.json000066400000000000000000000366141511562765300266340ustar00rootroot00000000000000{ "persistent": {}, "transient": { "cluster": { "routing": { "allocation": { "enable": "ALL" } } } }, "defaults": { "cluster": { "routing": { "rebalance": { "enable": "ALL" }, "none": { "node_concurrent_incoming_recoveries": "2", "node_initial_primaries_recoveries": "4", "same_shard": { "host": "false" }, "total_shards_per_node": "-1", "type": "balanced", "disk": { "threshold_enabled": "true", "watermark": { "low": "85%", "high": "90%" }, "include_relocations": "true", "reroute_interval": "60s" }, "awareness": { "attributes": "" }, "balance": { "index": "0.55", "threshold": "1.0", "shard": "0.45" }, "node_concurrent_outgoing_recoveries": "2", "allow_rebalance": "indices_all_active", "cluster_concurrent_rebalance": "2", "node_concurrent_recoveries": "2", "snapshot": { "relocation_enabled": "false" } } }, "indices": { "close": { "enable": "true" } }, "nodes": { "reconnect_interval": "10s" }, "blocks": { "read_only": "false" }, "service": { "slow_task_logging_threshold": "30s" }, "name": "elasticsearch", "info": { "update": { "interval": "30s", "timeout": "15s" } } }, "logger": { "level": "INFO" }, "bootstrap": { "ctrlhandler": "true", "memory_lock": "false", "system_call_filter": "true", "seccomp": "true" }, "processors": "4", "network": { "host": [ "_local_" ], "tcp": { "reuse_address": "true", "connect_timeout": "30s", "blocking": "false", "blocking_server": "false", "no_delay": "true", "blocking_client": "false", "keep_alive": "true", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "bind_host": [ "_local_" ], "server": "true", "breaker": { "inflight_requests": { "limit": "100%", "overhead": "1.0" } }, "publish_host": [ "_local_" ] }, "pidfile": "", "path": { "conf": "", "scripts": "", "logs": "/usr/share/elasticsearch/logs", "shared_data": "", "home": "/usr/share/elasticsearch" }, "default": { "path": { "logs": "", "conf": "" } }, "search": { "default_search_timeout": "-1", "highlight": { "term_vector_multi_value": "true" }, "low_level_cancellation": "false", "keep_alive_interval": "1m", "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "default_keep_alive": "5m" }, "security": { "manager": { "filter_bad_defaults": "true" } }, "repositories": { "fs": { "compress": "false", "chunk_size": "-1b", "location": "" }, "url": { "supported_protocols": [ "http", "https", "ftp", "file", "jar" ], "url": "http:" } }, "action": { "auto_create_index": "true", "search": { "shard_count": { "limit": "9223372036854775807" } }, "destructive_requires_name": "false", "master": { "force_local": "false" } }, "client": { "type": "node", "transport": { "ignore_cluster_name": "false", "nodes_sampler_interval": "5s", "sniff": "false", "ping_timeout": "5s" } }, "rest": { "action": { "multi": { "allow_explicit_index": "true" } } }, "cache": { "recycler": { "page": { "limit": { "heap": "10%" }, "type": "CONCURRENT", "weight": { "longs": "1.0", "ints": "1.0", "bytes": "1.0", "objects": "0.1" } } } }, "resource": { "reload": { "enabled": "true", "interval": { "low": "60s", "high": "5s", "medium": "30s" } } }, "thread_pool": { "force_merge": { "queue_size": "-1", "size": "1" }, "fetch_shard_started": { "core": "1", "max": "8", "keep_alive": "5m" }, "listener": { "queue_size": "-1", "size": "2" }, "index": { "queue_size": "200", "size": "4" }, "refresh": { "core": "1", "max": "2", "keep_alive": "5m" }, "generic": { "core": "4", "max": "128", "keep_alive": "30s" }, "warmer": { "core": "1", "max": "2", "keep_alive": "5m" }, "search": { "queue_size": "1000", "size": "7" }, "fetch_shard_store": { "core": "1", "max": "8", "keep_alive": "5m" }, "flush": { "core": "1", "max": "2", "keep_alive": "5m" }, "management": { "core": "1", "max": "5", "keep_alive": "5m" }, "get": { "queue_size": "1000", "size": "4" }, "bulk": { "queue_size": "200", "size": "4" }, "estimated_time_interval": "200ms", "snapshot": { "core": "1", "max": "2", "keep_alive": "5m" } }, "index": { "codec": "default", "store": { "type": "", "fs": { "fs_lock": "native" } } }, "monitor": { "jvm": { "gc": { "enabled": "true", "overhead": { "warn": "50", "debug": "10", "info": "25" }, "refresh_interval": "1s" }, "refresh_interval": "1s" }, "process": { "refresh_interval": "1s" }, "os": { "refresh_interval": "1s" }, "fs": { "refresh_interval": "1s" } }, "transport": { "tcp": { "reuse_address": "true", "connect_timeout": "30s", "compress": "false", "port": "9300-9400", "blocking_server": "false", "blocking_client": "false", "keep_alive": "true", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "ping_schedule": "-1", "publish_port": "-1", "connections_per_node": { "recovery": "2", "state": "1", "bulk": "3", "reg": "6", "ping": "1" }, "tcp_no_delay": "true", "tracer": { "exclude": [ "internal:discovery/zen/fd*", "cluster:monitor/nodes/liveness" ] }, "type": "", "netty": { "max_composite_buffer_components": "-1", "worker_count": "8", "receive_predictor_size": "512kb", "receive_predictor_max": "512kb", "receive_predictor_min": "512kb", "boss_count": "1", "max_cumulation_buffer_capacity": "-1b" }, "type.default": "netty4" }, "script": { "cache": { "max_size": "100", "expire": "0ms" }, "painless": { "regex": { "enabled": "false" } }, "legacy": { "default_lang": "groovy" }, "max_size_in_bytes": "65535", "update": "false", "max_compilations_per_minute": "15", "ingest": "false", "search": "false", "file": "true", "inline": "false", "auto_reload_enabled": "true", "engine": { "painless": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" }, "expression": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" }, "groovy": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "false", "file": "true", "inline": "false", "inline.update": "false", "stored.search": "false", "inline.aggs": "false", "file.search": "true", "stored": "false", "stored.ingest": "false", "stored.aggs": "false", "stored.update": "false", "inline.search": "false" }, "mustache": { "file.ingest": "true", "file.update": "true", "file.aggs": "true", "inline.ingest": "true", "file": "true", "inline": "true", "inline.update": "true", "stored.search": "true", "inline.aggs": "true", "file.search": "true", "stored": "true", "stored.ingest": "true", "stored.aggs": "true", "stored.update": "true", "inline.search": "true" } }, "stored": "false", "aggs": "false" }, "node": { "data": "true", "enable_lucene_segment_infos_trace": "false", "local_storage": "true", "max_local_storage_nodes": "1", "name": "DK8-2Lc", "id": { "seed": "0" }, "add_lock_id_to_custom_path": "true", "portsfile": "false", "ingest": "true", "master": "true" }, "indices": { "cache": { "cleanup_interval": "1m" }, "mapping": { "dynamic_timeout": "30s" }, "memory": { "interval": "5s", "max_index_buffer_size": "-1b", "shard_inactive_time": "5m", "index_buffer_size": "10%", "min_index_buffer_size": "48mb" }, "breaker": { "request": { "limit": "60%", "type": "memory", "overhead": "1.0" }, "total": { "limit": "70%" }, "fielddata": { "limit": "60%", "type": "memory", "overhead": "1.03" }, "type": "hierarchy" }, "fielddata": { "cache": { "size": "-1b" } }, "query": { "bool": { "max_clause_count": "1024" }, "query_string": { "analyze_wildcard": "false", "allowLeadingWildcard": "true" } }, "recovery": { "recovery_activity_timeout": "1800000ms", "retry_delay_network": "5s", "internal_action_timeout": "15m", "retry_delay_state_sync": "500ms", "internal_action_long_timeout": "1800000ms", "max_bytes_per_sec": "40mb" }, "requests": { "cache": { "size": "1%", "expire": "0ms" } }, "store": { "delete": { "shard": { "timeout": "30s" } }, "throttle": { "type": "NONE", "max_bytes_per_sec": "0b" } }, "analysis": { "hunspell": { "dictionary": { "ignore_case": "false", "lazy": "false" } } }, "queries": { "cache": { "count": "10000", "size": "10%", "all_segments": "false" } }, "ttl": { "interval": "60s" } }, "discovery": { "type": "zen", "zen": { "commit_timeout": "30s", "no_master_block": "write", "join_retry_delay": "100ms", "join_retry_attempts": "3", "ping": { "unicast": { "concurrent_connects": "10", "hosts": { "resolve_timeout": "5s" } } }, "master_election": { "ignore_non_master_pings": "false", "wait_for_joins_timeout": "30000ms" }, "send_leave_request": "true", "ping_timeout": "3s", "join_timeout": "60000ms", "publish_diff": { "enable": "true" }, "minimum_master_nodes": "-1", "hosts_provider": null, "publish_timeout": "30s", "fd": { "connect_on_network_disconnect": "false", "ping_interval": "1s", "ping_retries": "3", "register_connection_listener": "true", "ping_timeout": "30s" }, "max_pings_from_another_master": "3" }, "initial_state_timeout": "30s" }, "tribe": { "name": "", "on_conflict": "any", "blocks": { "write": "false", "metadata": "false" } }, "http": { "tcp": { "reuse_address": "true", "keep_alive": "true", "blocking_server": "false", "receive_buffer_size": "-1b", "send_buffer_size": "-1b" }, "bind_host": [ "0.0.0.0" ], "cors": { "max-age": "1728000", "allow-origin": "", "allow-headers": "X-Requested-With,Content-Type,Content-Length", "allow-credentials": "false", "allow-methods": "OPTIONS,HEAD,GET,POST,PUT,DELETE", "enabled": "false" }, "max_chunk_size": "8kb", "compression_level": "3", "reset_cookies": "false", "max_initial_line_length": "4kb", "type": "", "pipelining": "true", "enabled": "true", "type.default": "netty4", "detailed_errors": { "enabled": "true" }, "content_type": { "required": "false" }, "port": "9200-9300", "host": [ "0.0.0.0" ], "publish_port": "-1", "max_header_size": "8kb", "pipelining.max_events": "10000", "tcp_no_delay": "true", "compression": "true", "publish_host": [ "0.0.0.0" ], "max_content_length": "100mb", "netty": { "receive_predictor_size": "64kb", "max_composite_buffer_components": "-1", "receive_predictor_max": "64kb", "worker_count": "8", "receive_predictor_min": "64kb", "max_cumulation_buffer_capacity": "-1b" } }, "gateway": { "recover_after_master_nodes": "0", "expected_nodes": "-1", "recover_after_data_nodes": "-1", "initial_shards": "quorum", "expected_data_nodes": "-1", "recover_after_time": "0ms", "expected_master_nodes": "-1", "recover_after_nodes": "-1" } } } settings-persistent-clustermaxshardspernode-7.17.5.json000066400000000000000000001067261511562765300347200ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures{ "persistent": { "cluster": { "max_shards_per_node": "1000" } }, "transient": {}, "defaults": { "cluster": { "max_voting_config_exclusions": "10", "auto_shrink_voting_configuration": "true", "election": { "duration": "500ms", "initial_timeout": "100ms", "max_timeout": "10s", "back_off_time": "100ms", "strategy": "supports_voting_only" }, "no_master_block": "write", "persistent_tasks": { "allocation": { "enable": "all", "recheck_interval": "30s" } }, "blocks": { "read_only_allow_delete": "false", "read_only": "false" }, "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "follower_lag": { "timeout": "90000ms" }, "routing": { "use_adaptive_replica_selection": "true", "rebalance": { "enable": "all" }, "allocation": { "enforce_default_tier_preference": "false", "node_concurrent_incoming_recoveries": "2", "include": { "_tier": "" }, "node_initial_primaries_recoveries": "4", "same_shard": { "host": "false" }, "total_shards_per_node": "-1", "require": { "_tier": "" }, "shard_state": { "reroute": { "priority": "NORMAL" } }, "type": "balanced", "disk": { "threshold_enabled": "true", "watermark": { "flood_stage.frozen.max_headroom": "20GB", "flood_stage": "100b", "high": "200gb", "low": "50mb", "enable_for_single_data_node": "false", "flood_stage.frozen": "95%" }, "include_relocations": "true", "reroute_interval": "60s" }, "awareness": { "attributes": [] }, "balance": { "index": "0.55", "threshold": "1.0", "shard": "0.45" }, "enable": "all", "node_concurrent_outgoing_recoveries": "2", "allow_rebalance": "indices_all_active", "cluster_concurrent_rebalance": "2", "node_concurrent_recoveries": "2", "exclude": { "_tier": "" } } }, "indices": { "tombstones": { "size": "500" }, "close": { "enable": "true" } }, "nodes": { "reconnect_interval": "10s" }, "service": { "master_service_starvation_logging_threshold": "5m", "slow_master_task_logging_threshold": "10s", "slow_task_logging_threshold": "30s" }, "publish": { "timeout": "30000ms", "info_timeout": "10000ms" }, "name": "docker-cluster", "fault_detection": { "leader_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" }, "follower_check": { "interval": "1000ms", "timeout": "10000ms", "retry_count": "3" } }, "join": { "timeout": "60000ms" }, "max_shards_per_node": { "frozen": "3000" }, "initial_master_nodes": [], "deprecation_indexing": { "enabled": "true", "x_opaque_id_used": { "enabled": "true" } }, "snapshot": { "info": { "max_concurrent_fetches": "5" } }, "info": { "update": { "interval": "30s", "timeout": "15s" } } }, "stack": { "templates": { "enabled": "true" } }, "logger": { "level": "INFO" }, "bootstrap": { "memory_lock": "false", "system_call_filter": "true", "ctrlhandler": "true" }, "processors": "12", "ingest": { "user_agent": { "cache_size": "1000" }, "geoip": { "cache_size": "1000", "downloader": { "enabled": "true", "endpoint": "https://geoip.elastic.co/v1/database", "poll": { "interval": "3d" } } }, "grok": { "watchdog": { "max_execution_time": "1s", "interval": "1s" } } }, "network": { "host": [ "0.0.0.0" ], "tcp": { "reuse_address": "true", "keep_count": "-1", "connect_timeout": "30s", "keep_interval": "-1", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [ "0.0.0.0" ], "server": "true", "breaker": { "inflight_requests": { "limit": "100%", "overhead": "2.0" } }, "publish_host": [ "0.0.0.0" ] }, "pidfile": "", "searchable_snapshots": { "blob_cache": { "periodic_cleanup": { "interval": "1h", "batch_size": "100", "pit_keep_alive": "10m", "retention_period": "1h" } } }, "path": { "data": [], "logs": "/usr/share/elasticsearch/logs", "shared_data": "", "home": "/usr/share/elasticsearch", "repo": [] }, "search": { "default_search_timeout": "-1", "max_open_scroll_context": "500", "max_buckets": "65536", "max_async_search_response_size": "-1b", "keep_alive_interval": "1m", "remote": { "node": { "attr": "" }, "initial_connect_timeout": "30s", "connect": "true", "connections_per_cluster": "3" }, "max_keep_alive": "24h", "highlight": { "term_vector_multi_value": "true" }, "default_allow_partial_results": "true", "low_level_cancellation": "true", "allow_expensive_queries": "true", "default_keep_alive": "5m", "aggs": { "rewrite_to_filter_by_filter": "true" } }, "security": { "manager": { "filter_bad_defaults": "true" } }, "ccr": { "wait_for_metadata_timeout": "60s", "indices": { "recovery": { "recovery_activity_timeout": "60s", "chunk_size": "1mb", "internal_action_timeout": "60s", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "5" } }, "auto_follow": { "wait_for_metadata_timeout": "60s" } }, "repositories": { "fs": { "compress": "false", "chunk_size": "9223372036854775807b", "location": "" }, "url": { "supported_protocols": [ "http", "https", "ftp", "file", "jar" ], "allowed_urls": [], "url": "http:" } }, "action": { "auto_create_index": "true", "search": { "pre_filter_shard_size": { "default": "128" }, "shard_count": { "limit": "9223372036854775807" } }, "destructive_requires_name": "false" }, "client": { "type": "node", "transport": { "ignore_cluster_name": "false", "nodes_sampler_interval": "5s", "sniff": "false", "ping_timeout": "5s" } }, "enrich": { "max_force_merge_attempts": "3", "cleanup_period": "15m", "fetch_size": "10000", "cache_size": "1000", "coordinator_proxy": { "max_concurrent_requests": "8", "max_lookups_per_request": "128", "queue_capacity": "1024" }, "max_concurrent_policy_executions": "50" }, "xpack": { "flattened": { "enabled": "true" }, "watcher": { "execution": { "scroll": { "size": "0", "timeout": "" }, "default_throttle_period": "5s" }, "internal": { "ops": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" }, "search": { "default_timeout": "" } } }, "thread_pool": { "queue_size": "1000", "size": "50" }, "index": { "rest": { "direct_access": "" } }, "use_ilm_index_management": "true", "history": { "cleaner_service": { "enabled": "true" } }, "trigger": { "schedule": { "ticker": { "tick_interval": "500ms" } } }, "enabled": "true", "input": { "search": { "default_timeout": "" } }, "encrypt_sensitive_data": "false", "transform": { "search": { "default_timeout": "" } }, "stop": { "timeout": "30s" }, "watch": { "scroll": { "size": "0" } }, "bulk": { "concurrent_requests": "0", "flush_interval": "1s", "size": "1mb", "actions": "1" }, "actions": { "bulk": { "default_timeout": "" }, "index": { "default_timeout": "" } } }, "eql": { "enabled": "true" }, "data_frame": { "enabled": "true" }, "ilm": { "enabled": "true" }, "monitoring": { "migration": { "decommission_alerts": "false" }, "collection": { "cluster": { "stats": { "timeout": "10s" } }, "node": { "stats": { "timeout": "10s" } }, "indices": [], "ccr": { "stats": { "timeout": "10s" } }, "enrich": { "stats": { "timeout": "10s" } }, "index": { "stats": { "timeout": "10s" }, "recovery": { "active_only": "false", "timeout": "10s" } }, "interval": "10s", "enabled": "false", "ml": { "job": { "stats": { "timeout": "10s" } } } }, "history": { "duration": "168h" }, "elasticsearch": { "collection": { "enabled": "true" } }, "enabled": "true" }, "graph": { "enabled": "true" }, "searchable": { "snapshot": { "allocate_on_rolling_restart": "false", "cache": { "range_size": "32mb", "sync": { "max_files": "10000", "interval": "60s", "shutdown_timeout": "10s" }, "recovery_range_size": "128kb" }, "shared_cache": { "recovery_range_size": "128kb", "region_size": "16mb", "size": "0", "min_time_delta": "60s", "decay": { "interval": "60s" }, "size.max_headroom": "-1", "range_size": "16mb", "max_freq": "100" } } }, "rollup": { "enabled": "true", "task_thread_pool": { "queue_size": "-1", "size": "1" } }, "sql": { "enabled": "true" }, "searchable_snapshots": { "cache_fetch_async_thread_pool": { "core": "0", "max": "36", "keep_alive": "30s" }, "cache_prewarming_thread_pool": { "core": "0", "max": "16", "keep_alive": "30s" } }, "license": { "upload": { "types": [ "standard", "gold", "platinum", "enterprise", "trial" ] }, "self_generated": { "type": "basic" } }, "logstash": { "enabled": "true" }, "notification": { "pagerduty": { "default_account": "" }, "email": { "account": { "domain_allowlist": [ "*" ] }, "default_account": "", "html": { "sanitization": { "allow": [ "body", "head", "_tables", "_links", "_blocks", "_formatting", "img:embedded" ], "disallow": [], "enabled": "true" } } }, "reporting": { "retries": "40", "warning": { "enabled": "true" }, "interval": "15s" }, "jira": { "default_account": "" }, "slack": { "default_account": "" } }, "security": { "operator_privileges": { "enabled": "false" }, "dls_fls": { "enabled": "true" }, "dls": { "bitset": { "cache": { "size": "10%", "ttl": "2h" } } }, "transport": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "ssl": { "diagnose": { "trust": "true" } }, "enabled": "true", "crypto": { "thread_pool": { "queue_size": "1000", "size": "6" } }, "filter": { "always_allow_bound_address": "true" }, "encryption": { "algorithm": "AES/CTR/NoPadding" }, "audit": { "enabled": "false", "logfile": { "emit_node_id": "true", "emit_node_host_name": "false", "emit_node_name": "false", "events": { "emit_request_body": "false", "include": [ "ACCESS_DENIED", "ACCESS_GRANTED", "ANONYMOUS_ACCESS_DENIED", "AUTHENTICATION_FAILED", "CONNECTION_DENIED", "TAMPERED_REQUEST", "RUN_AS_DENIED", "RUN_AS_GRANTED", "SECURITY_CONFIG_CHANGE" ], "exclude": [] }, "emit_node_host_address": "false" } }, "authc": { "password_hashing": { "algorithm": "bcrypt" }, "success_cache": { "size": "10000", "enabled": "true", "expire_after_access": "1h" }, "api_key": { "doc_cache": { "ttl": "5m" }, "cache": { "hash_algo": "ssha256", "max_keys": "25000", "ttl": "24h" }, "delete": { "interval": "24h", "timeout": "-1" }, "enabled": "false", "hashing": { "algorithm": "pbkdf2" } }, "anonymous": { "authz_exception": "true", "roles": [], "username": "_anonymous" }, "run_as": { "enabled": "true" }, "reserved_realm": { "enabled": "true" }, "service_token": { "cache": { "hash_algo": "ssha256", "max_tokens": "100000", "ttl": "20m" } }, "token": { "delete": { "interval": "30m", "timeout": "-1" }, "enabled": "false", "thread_pool": { "queue_size": "1000", "size": "1" }, "timeout": "20m" } }, "fips_mode": { "enabled": "false" }, "encryption_key": { "length": "128", "algorithm": "AES" }, "http": { "filter": { "allow": [], "deny": [], "enabled": "true" }, "ssl": { "enabled": "false" } }, "automata": { "max_determinized_states": "100000", "cache": { "size": "10000", "ttl": "48h", "enabled": "true" } }, "user": null, "authz": { "timer": { "indices": { "enabled": "false", "threshold": { "warn": "200ms", "debug": "20ms", "info": "100ms" } } }, "store": { "privileges": { "cache": { "ttl": "24h", "max_size": "10000" } }, "roles": { "index": { "cache": { "ttl": "20m", "max_size": "10000" } }, "cache": { "max_size": "10000" }, "negative_lookup_cache": { "max_size": "10000" }, "field_permissions": { "cache": { "max_size_in_bytes": "104857600" } } } } } }, "transform": { "num_transform_failure_retries": "10", "enabled": "true" }, "vectors": { "enabled": "true" }, "ccr": { "enabled": "true", "ccr_thread_pool": { "queue_size": "100", "size": "32" } }, "idp": { "privileges": { "application": "", "cache": { "size": "100", "ttl": "90m" } }, "metadata": { "signing": { "keystore": { "alias": "" } } }, "slo_endpoint": { "post": "https:", "redirect": "https:" }, "defaults": { "nameid_format": "urn:oasis:names:tc:SAML:2.0:nameid-format:transient", "authn_expiry": "5m" }, "allowed_nameid_formats": [ "urn:oasis:names:tc:SAML:2.0:nameid-format:transient" ], "contact": { "given_name": "", "email": "", "surname": "" }, "organization": { "display_name": "", "name": "", "url": "http:" }, "sso_endpoint": { "post": "https:", "redirect": "https:" }, "entity_id": "", "signing": { "keystore": { "alias": "" } }, "sp": { "cache": { "size": "1000", "ttl": "60m" }, "wildcard": { "path": "wildcard_services.json" } }, "enabled": "false" }, "slm": { "enabled": "true" }, "enrich": { "enabled": "true" }, "http": { "tcp": { "keep_alive": "true" }, "default_connection_timeout": "10s", "proxy": { "host": "", "scheme": "", "port": "0" }, "connection_pool_ttl": "-1", "max_response_size": "10mb", "whitelist": [ "*" ], "default_read_timeout": "10s" }, "autoscaling": { "memory": { "monitor": { "timeout": "15s" } } }, "ml": { "utility_thread_pool": { "core": "1", "max": "2048", "keep_alive": "10m" }, "max_anomaly_records": "500", "enable_config_migration": "true", "max_open_jobs": "512", "delayed_data_check_freq": "15m", "min_disk_space_off_heap": "5gb", "use_auto_machine_memory_percent": "false", "inference_model": { "cache_size": "40%", "time_to_live": "5m" }, "nightly_maintenance_requests_per_second": "-1.0", "node_concurrent_job_allocations": "2", "max_model_memory_limit": "0b", "enabled": "true", "max_lazy_ml_nodes": "0", "max_ml_node_size": "0b", "max_machine_memory_percent": "30", "persist_results_max_retries": "20", "autodetect_process": "true", "datafeed_thread_pool": { "core": "1", "max": "512", "keep_alive": "1m" }, "max_inference_processors": "50", "process_connect_timeout": "10s", "job_comms_thread_pool": { "core": "4", "max": "2048", "keep_alive": "1m" } } }, "rest": { "action": { "multi": { "allow_explicit_index": "true" } } }, "cache": { "recycler": { "page": { "limit": { "heap": "10%" }, "type": "CONCURRENT", "weight": { "longs": "1.0", "ints": "1.0", "bytes": "1.0", "objects": "0.1" } } } }, "async_search": { "index_cleanup_interval": "1h" }, "reindex": { "remote": { "whitelist": [] } }, "resource": { "reload": { "enabled": "true", "interval": { "low": "60s", "high": "5s", "medium": "30s" } } }, "thread_pool": { "force_merge": { "queue_size": "-1", "size": "1" }, "search_coordination": { "queue_size": "1000", "size": "5" }, "snapshot_meta": { "core": "1", "max": "36", "keep_alive": "30s" }, "fetch_shard_started": { "core": "1", "max": "24", "keep_alive": "5m" }, "listener": { "queue_size": "-1", "size": "6" }, "estimated_time_interval.warn_threshold": "5s", "scheduler": { "warn_threshold": "5s" }, "search": { "max_queue_size": "1000", "queue_size": "1000", "size": "19", "auto_queue_frame_size": "2000", "target_response_time": "1s", "min_queue_size": "1000" }, "fetch_shard_store": { "core": "1", "max": "24", "keep_alive": "5m" }, "flush": { "core": "1", "max": "5", "keep_alive": "5m" }, "vectortile": { "queue_size": "-1", "size": "1" }, "get": { "queue_size": "1000", "size": "12" }, "system_read": { "queue_size": "2000", "size": "5" }, "system_critical_read": { "queue_size": "2000", "size": "5" }, "estimated_time_interval": "200ms", "write": { "queue_size": "10000", "size": "12" }, "system_critical_write": { "queue_size": "1500", "size": "5" }, "refresh": { "core": "1", "max": "6", "keep_alive": "5m" }, "system_write": { "queue_size": "1000", "size": "5" }, "generic": { "core": "4", "max": "128", "keep_alive": "30s" }, "warmer": { "core": "1", "max": "5", "keep_alive": "5m" }, "auto_complete": { "queue_size": "100", "size": "3" }, "management": { "core": "1", "max": "5", "keep_alive": "5m" }, "analyze": { "queue_size": "16", "size": "1" }, "snapshot": { "core": "1", "max": "5", "keep_alive": "5m" }, "search_throttled": { "max_queue_size": "100", "queue_size": "100", "size": "1", "auto_queue_frame_size": "200", "target_response_time": "1s", "min_queue_size": "100" } }, "index": { "codec": "default", "recovery": { "type": "" }, "store": { "type": "", "fs": { "fs_lock": "native" }, "preload": [], "snapshot": { "uncached_chunk_size": "-1b", "cache": { "excluded_file_types": [] } } } }, "monitor": { "jvm": { "gc": { "enabled": "true", "overhead": { "warn": "50", "debug": "10", "info": "25" }, "refresh_interval": "1s" }, "refresh_interval": "1s" }, "process": { "refresh_interval": "1s" }, "os": { "refresh_interval": "1s" }, "fs": { "health": { "enabled": "true", "refresh_interval": "120s", "slow_path_logging_threshold": "5s" }, "refresh_interval": "1s" } }, "runtime_fields": { "grok": { "watchdog": { "max_execution_time": "1s", "interval": "1s" } } }, "transport": { "tcp": { "reuse_address": "true", "keep_count": "-1", "connect_timeout": "30s", "keep_interval": "-1", "compress": "FALSE", "port": "9300-9400", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [], "connect_timeout": "30s", "compress": "FALSE", "ping_schedule": "-1", "connections_per_node": { "recovery": "2", "state": "1", "bulk": "3", "reg": "6", "ping": "1" }, "tracer": { "include": [], "exclude": [ "internal:discovery/zen/fd*", "internal:coordination/fault_detection/*", "cluster:monitor/nodes/liveness" ] }, "type": "security4", "slow_operation_logging_threshold": "5s", "type.default": "netty4", "features": { "x-pack": "true" }, "port": "9300-9400", "compression_scheme": "DEFLATE", "host": [], "publish_port": "-1", "tcp_no_delay": "true", "publish_host": [], "netty": { "receive_predictor_size": "64kb", "receive_predictor_max": "64kb", "worker_count": "12", "receive_predictor_min": "64kb", "boss_count": "1" } }, "deprecation": { "skip_deprecated_settings": [] }, "script": { "allowed_contexts": [], "max_compilations_rate": "150/5m", "cache": { "max_size": "3000", "expire": "0ms" }, "painless": { "regex": { "enabled": "limited", "limit-factor": "6" } }, "max_size_in_bytes": "65535", "allowed_types": [], "disable_max_compilations_rate": "false" }, "indexing_pressure": { "memory": { "limit": "10%" } }, "node": { "data": "true", "bandwidth": { "recovery": { "disk": { "write": "-1", "read": "-1" }, "operator": { "factor.read": "0.4", "factor.write": "0.4", "factor": "0.4", "factor.max_overcommit": "100.0" }, "network": "-1" } }, "roles": [ "data_frozen", "data_warm", "transform", "data", "remote_cluster_client", "data_cold", "data_content", "data_hot", "ingest", "master", "ml" ], "max_local_storage_nodes": "1", "processors": "12", "store": { "allow_mmap": "true" }, "ingest": "true", "master": "true", "pidfile": "", "transform": "true", "remote_cluster_client": "true", "enable_lucene_segment_infos_trace": "false", "local_storage": "true", "name": "36ac32055483", "id": { "seed": "0" }, "voting_only": "false", "attr": { "transform": { "node": "true" }, "xpack": { "installed": "true" }, "ml": { "max_jvm_size": "8392802304", "machine_memory": "16784928768", "max_open_jobs": "512" } }, "portsfile": "false", "ml": "true" }, "indices": { "replication": { "retry_timeout": "60s", "initial_retry_backoff_bound": "50ms" }, "cache": { "cleanup_interval": "1m" }, "mapping": { "dynamic_timeout": "30s", "max_in_flight_updates": "10" }, "memory": { "interval": "5s", "max_index_buffer_size": "-1", "shard_inactive_time": "5m", "index_buffer_size": "10%", "min_index_buffer_size": "48mb" }, "breaker": { "request": { "limit": "60%", "type": "memory", "overhead": "1.0" }, "total": { "limit": "95%", "use_real_memory": "true" }, "accounting": { "limit": "100%", "overhead": "1.0" }, "fielddata": { "limit": "40%", "type": "memory", "overhead": "1.03" }, "type": "hierarchy" }, "query": { "bool": { "max_nested_depth": "20", "max_clause_count": "1024" }, "query_string": { "analyze_wildcard": "false", "allowLeadingWildcard": "true" } }, "id_field_data": { "enabled": "true" }, "recovery": { "internal_action_retry_timeout": "1m", "recovery_activity_timeout": "1800000ms", "retry_delay_network": "5s", "internal_action_timeout": "15m", "max_concurrent_snapshot_file_downloads_per_node": "25", "retry_delay_state_sync": "500ms", "max_concurrent_snapshot_file_downloads": "5", "internal_action_long_timeout": "1800000ms", "max_concurrent_operations": "1", "use_snapshots": "true", "max_bytes_per_sec": "40mb", "max_concurrent_file_chunks": "2" }, "requests": { "cache": { "size": "1%", "expire": "0ms" } }, "store": { "delete": { "shard": { "timeout": "30s" } } }, "analysis": { "hunspell": { "dictionary": { "ignore_case": "false", "lazy": "false" } } }, "queries": { "cache": { "count": "10000", "size": "10%", "all_segments": "false" } }, "lifecycle": { "history_index_enabled": "true", "poll_interval": "10m", "step": { "master_timeout": "30s" } }, "fielddata": { "cache": { "size": "-1b" } } }, "plugin": { "mandatory": [] }, "slm": { "minimum_interval": "15m", "retention_schedule": "0 30 1 * * ?", "retention_duration": "1h", "history_index_enabled": "true" }, "discovery": { "seed_hosts": [], "unconfigured_bootstrap_timeout": "3s", "request_peers_timeout": "3000ms", "zen": { "commit_timeout": "30s", "no_master_block": "write", "join_retry_delay": "100ms", "join_retry_attempts": "3", "ping": { "unicast": { "concurrent_connects": "10", "hosts": [], "hosts.resolve_timeout": "5s" } }, "master_election": { "ignore_non_master_pings": "false", "wait_for_joins_timeout": "30000ms" }, "send_leave_request": "true", "ping_timeout": "3s", "bwc_ping_timeout": "3s", "join_timeout": "60000ms", "publish_diff": { "enable": "true" }, "publish": { "max_pending_cluster_states": "25" }, "minimum_master_nodes": "-1", "unsafe_rolling_upgrades_enabled": "true", "hosts_provider": [], "publish_timeout": "30s", "fd": { "connect_on_network_disconnect": "false", "ping_interval": "1s", "ping_retries": "3", "register_connection_listener": "true", "ping_timeout": "30s" }, "max_pings_from_another_master": "3" }, "initial_state_timeout": "30s", "cluster_formation_warning_timeout": "10000ms", "seed_providers": [], "type": "single-node", "seed_resolver": { "max_concurrent_resolvers": "10", "timeout": "5s" }, "find_peers_interval": "1000ms", "probe": { "connect_timeout": "30s", "handshake_timeout": "30s" } }, "http": { "cors": { "max-age": "1728000", "allow-origin": "", "allow-headers": "X-Requested-With,Content-Type,Content-Length", "allow-credentials": "false", "allow-methods": "OPTIONS,HEAD,GET,POST,PUT,DELETE", "enabled": "false" }, "max_chunk_size": "8kb", "compression_level": "3", "max_initial_line_length": "4kb", "type": "security4", "pipelining": { "max_events": "10000" }, "type.default": "netty4", "content_type": { "required": "true" }, "host": [], "publish_port": "-1", "read_timeout": "0ms", "max_content_length": "100mb", "netty": { "receive_predictor_size": "64kb", "max_composite_buffer_components": "69905", "worker_count": "0" }, "tcp": { "reuse_address": "true", "keep_count": "-1", "keep_interval": "-1", "no_delay": "true", "keep_alive": "true", "receive_buffer_size": "-1b", "keep_idle": "-1", "send_buffer_size": "-1b" }, "bind_host": [], "client_stats": { "enabled": "true", "closed_channels": { "max_age": "5m", "max_count": "10000" } }, "reset_cookies": "false", "max_warning_header_count": "-1", "tracer": { "include": [], "exclude": [] }, "max_warning_header_size": "-1b", "detailed_errors": { "enabled": "true" }, "port": "9200-9300", "max_header_size": "8kb", "tcp_no_delay": "true", "compression": "true", "publish_host": [] }, "gateway": { "recover_after_master_nodes": "0", "expected_nodes": "-1", "recover_after_data_nodes": "-1", "expected_data_nodes": "-1", "write_dangling_indices_info": "true", "slow_write_logging_threshold": "10s", "recover_after_time": "0ms", "expected_master_nodes": "-1", "recover_after_nodes": "-1", "auto_import_dangling_indices": "false" }, "snapshot": { "refresh_repo_uuid_on_restore": "true", "max_concurrent_operations": "1000" } } } prometheus-elasticsearch-exporter-1.10.0/fixtures/shards/000077500000000000000000000000001511562765300236125ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/shards/7.15.0.json000066400000000000000000000011741511562765300252400ustar00rootroot00000000000000[{"index":".geoip_databases","shard":"0","prirep":"p","state":"STARTED","docs":"38","store":"36.4mb","ip":"172.17.0.2","node":"35dfca79831a"},{"index":"otherindex","shard":"0","prirep":"p","state":"STARTED","docs":"0","store":"208b","ip":"172.17.0.2","node":"35dfca79831a"},{"index":"otherindex","shard":"0","prirep":"r","state":"UNASSIGNED","docs":null,"store":null,"ip":null,"node":null},{"index":"testindex","shard":"0","prirep":"p","state":"STARTED","docs":"0","store":"208b","ip":"172.17.0.2","node":"35dfca79831a"},{"index":"testindex","shard":"0","prirep":"r","state":"UNASSIGNED","docs":null,"store":null,"ip":null,"node":null}]prometheus-elasticsearch-exporter-1.10.0/fixtures/slm/000077500000000000000000000000001511562765300231215ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/slm/stats/000077500000000000000000000000001511562765300242575ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/slm/stats/7.15.0.json000066400000000000000000000007521511562765300257060ustar00rootroot00000000000000{ "retention_runs": 9, "retention_failed": 0, "retention_timed_out": 0, "retention_deletion_time": "1.2m", "retention_deletion_time_millis": 72491, "total_snapshots_taken": 103, "total_snapshots_failed": 2, "total_snapshots_deleted": 20, "total_snapshot_deletion_failures": 0, "policy_stats": [ { "policy": "everything", "snapshots_taken": 50, "snapshots_failed": 2, "snapshots_deleted": 20, "snapshot_deletion_failures": 0 } ] } prometheus-elasticsearch-exporter-1.10.0/fixtures/slm/status/000077500000000000000000000000001511562765300244445ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/slm/status/7.15.0.json000066400000000000000000000000031511562765300260600ustar00rootroot00000000000000{} prometheus-elasticsearch-exporter-1.10.0/fixtures/snapshots/000077500000000000000000000000001511562765300243505ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/fixtures/snapshots/1.7.6.json000066400000000000000000000005551511562765300257210ustar00rootroot00000000000000{"snapshots":[{"snapshot":"snapshot_1","version_id":1070699,"version":"1.7.6","indices":["foo_1","foo_2"],"state":"SUCCESS","start_time":"2018-09-04T09:09:02.427Z","start_time_in_millis":1536052142427,"end_time":"2018-09-04T09:09:02.755Z","end_time_in_millis":1536052142755,"duration_in_millis":328,"failures":[],"shards":{"total":10,"failed":0,"successful":10}}]} prometheus-elasticsearch-exporter-1.10.0/fixtures/snapshots/2.4.5.json000066400000000000000000000005551511562765300257160ustar00rootroot00000000000000{"snapshots":[{"snapshot":"snapshot_1","version_id":2040599,"version":"2.4.5","indices":["foo_2","foo_1"],"state":"SUCCESS","start_time":"2018-09-04T09:25:25.818Z","start_time_in_millis":1536053125818,"end_time":"2018-09-04T09:25:26.326Z","end_time_in_millis":1536053126326,"duration_in_millis":508,"failures":[],"shards":{"total":10,"failed":0,"successful":10}}]} prometheus-elasticsearch-exporter-1.10.0/fixtures/snapshots/5.4.2-failed.json000066400000000000000000000013121511562765300271300ustar00rootroot00000000000000{"snapshots":[{"snapshot":"snapshot_1","uuid":"VZ_c_kKISAW8rpcqiwSg0w","version_id":5040299,"version":"5.4.2","indices":["foo_2","foo_1"],"state":"SUCCESS","start_time":"2018-09-04T09:29:13.971Z","start_time_in_millis":1536053353971,"end_time":"2018-09-04T09:29:14.477Z","end_time_in_millis":1536053354477,"duration_in_millis":506,"failures":[{"index" : "index_name","index_uuid" : "index_name","shard_id" : 52,"reason" : "IndexShardSnapshotFailedException[error deleting index file [pending-index-5] during cleanup]; nested: NoSuchFileException[Blob [pending-index-5] does not exist]; ","node_id" : "pPm9jafyTjyMk0T5A101xA","status" : "INTERNAL_SERVER_ERROR"}],"shards":{"total":10,"failed":1,"successful":10}}]} prometheus-elasticsearch-exporter-1.10.0/fixtures/snapshots/5.4.2.json000066400000000000000000000006151511562765300257130ustar00rootroot00000000000000{"snapshots":[{"snapshot":"snapshot_1","uuid":"VZ_c_kKISAW8rpcqiwSg0w","version_id":5040299,"version":"5.4.2","indices":["foo_2","foo_1"],"state":"SUCCESS","start_time":"2018-09-04T09:29:13.971Z","start_time_in_millis":1536053353971,"end_time":"2018-09-04T09:29:14.477Z","end_time_in_millis":1536053354477,"duration_in_millis":506,"failures":[],"shards":{"total":10,"failed":0,"successful":10}}]} prometheus-elasticsearch-exporter-1.10.0/go.mod000066400000000000000000000045571511562765300215760ustar00rootroot00000000000000module github.com/prometheus-community/elasticsearch_exporter go 1.24.0 require ( github.com/alecthomas/kingpin/v2 v2.4.0 github.com/aws/aws-sdk-go-v2 v1.40.0 github.com/aws/aws-sdk-go-v2/config v1.32.2 github.com/aws/aws-sdk-go-v2/credentials v1.19.2 github.com/aws/aws-sdk-go-v2/service/sts v1.41.2 github.com/blang/semver/v4 v4.0.0 github.com/imdario/mergo v0.3.13 github.com/prometheus/client_golang v1.23.2 github.com/prometheus/common v0.67.4 github.com/prometheus/exporter-toolkit v0.15.0 go.yaml.in/yaml/v3 v3.0.4 ) require ( github.com/alecthomas/units v0.0.0-20240927000941-0f3dac36c52b // indirect github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.14 // indirect github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.14 // indirect github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.14 // indirect github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 // indirect github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.3 // indirect github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.14 // indirect github.com/aws/aws-sdk-go-v2/service/signin v1.0.2 // indirect github.com/aws/aws-sdk-go-v2/service/sso v1.30.5 // indirect github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.10 // indirect github.com/aws/smithy-go v1.23.2 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/coreos/go-systemd/v22 v22.6.0 // indirect github.com/golang-jwt/jwt/v5 v5.3.0 // indirect github.com/google/uuid v1.6.0 // indirect github.com/jpillora/backoff v1.0.0 // indirect github.com/kylelemons/godebug v1.1.0 // indirect github.com/mdlayher/socket v0.4.1 // indirect github.com/mdlayher/vsock v1.2.1 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect github.com/prometheus/client_model v0.6.2 // indirect github.com/prometheus/procfs v0.16.1 // indirect github.com/xhit/go-str2duration/v2 v2.1.0 // indirect go.yaml.in/yaml/v2 v2.4.3 // indirect golang.org/x/crypto v0.45.0 // indirect golang.org/x/net v0.47.0 // indirect golang.org/x/oauth2 v0.32.0 // indirect golang.org/x/sync v0.18.0 // indirect golang.org/x/sys v0.38.0 // indirect golang.org/x/text v0.31.0 // indirect golang.org/x/time v0.13.0 // indirect google.golang.org/protobuf v1.36.10 // indirect ) prometheus-elasticsearch-exporter-1.10.0/go.sum000066400000000000000000000261051511562765300216140ustar00rootroot00000000000000github.com/alecthomas/kingpin/v2 v2.4.0 h1:f48lwail6p8zpO1bC4TxtqACaGqHYA22qkHjHpqDjYY= github.com/alecthomas/kingpin/v2 v2.4.0/go.mod h1:0gyi0zQnjuFk8xrkNKamJoyUo382HRL7ATRpFZCw6tE= github.com/alecthomas/units v0.0.0-20240927000941-0f3dac36c52b h1:mimo19zliBX/vSQ6PWWSL9lK8qwHozUj03+zLoEB8O0= github.com/alecthomas/units v0.0.0-20240927000941-0f3dac36c52b/go.mod h1:fvzegU4vN3H1qMT+8wDmzjAcDONcgo2/SZ/TyfdUOFs= github.com/aws/aws-sdk-go-v2 v1.40.0 h1:/WMUA0kjhZExjOQN2z3oLALDREea1A7TobfuiBrKlwc= github.com/aws/aws-sdk-go-v2 v1.40.0/go.mod h1:c9pm7VwuW0UPxAEYGyTmyurVcNrbF6Rt/wixFqDhcjE= github.com/aws/aws-sdk-go-v2/config v1.32.2 h1:4liUsdEpUUPZs5WVapsJLx5NPmQhQdez7nYFcovrytk= github.com/aws/aws-sdk-go-v2/config v1.32.2/go.mod h1:l0hs06IFz1eCT+jTacU/qZtC33nvcnLADAPL/XyrkZI= github.com/aws/aws-sdk-go-v2/credentials v1.19.2 h1:qZry8VUyTK4VIo5aEdUcBjPZHL2v4FyQ3QEOaWcFLu4= github.com/aws/aws-sdk-go-v2/credentials v1.19.2/go.mod h1:YUqm5a1/kBnoK+/NY5WEiMocZihKSo15/tJdmdXnM5g= github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.14 h1:WZVR5DbDgxzA0BJeudId89Kmgy6DIU4ORpxwsVHz0qA= github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.14/go.mod h1:Dadl9QO0kHgbrH1GRqGiZdYtW5w+IXXaBNCHTIaheM4= github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.14 h1:PZHqQACxYb8mYgms4RZbhZG0a7dPW06xOjmaH0EJC/I= github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.14/go.mod h1:VymhrMJUWs69D8u0/lZ7jSB6WgaG/NqHi3gX0aYf6U0= github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.14 h1:bOS19y6zlJwagBfHxs0ESzr1XCOU2KXJCWcq3E2vfjY= github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.14/go.mod h1:1ipeGBMAxZ0xcTm6y6paC2C/J6f6OO7LBODV9afuAyM= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 h1:WKuaxf++XKWlHWu9ECbMlha8WOEGm0OUEZqm4K/Gcfk= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4/go.mod h1:ZWy7j6v1vWGmPReu0iSGvRiise4YI5SkR3OHKTZ6Wuc= github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.3 h1:x2Ibm/Af8Fi+BH+Hsn9TXGdT+hKbDd5XOTZxTMxDk7o= github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.3/go.mod h1:IW1jwyrQgMdhisceG8fQLmQIydcT/jWY21rFhzgaKwo= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.14 h1:FIouAnCE46kyYqyhs0XEBDFFSREtdnr8HQuLPQPLCrY= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.14/go.mod h1:UTwDc5COa5+guonQU8qBikJo1ZJ4ln2r1MkF7Dqag1E= github.com/aws/aws-sdk-go-v2/service/signin v1.0.2 h1:MxMBdKTYBjPQChlJhi4qlEueqB1p1KcbTEa7tD5aqPs= github.com/aws/aws-sdk-go-v2/service/signin v1.0.2/go.mod h1:iS6EPmNeqCsGo+xQmXv0jIMjyYtQfnwg36zl2FwEouk= github.com/aws/aws-sdk-go-v2/service/sso v1.30.5 h1:ksUT5KtgpZd3SAiFJNJ0AFEJVva3gjBmN7eXUZjzUwQ= github.com/aws/aws-sdk-go-v2/service/sso v1.30.5/go.mod h1:av+ArJpoYf3pgyrj6tcehSFW+y9/QvAY8kMooR9bZCw= github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.10 h1:GtsxyiF3Nd3JahRBJbxLCCdYW9ltGQYrFWg8XdkGDd8= github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.10/go.mod h1:/j67Z5XBVDx8nZVp9EuFM9/BS5dvBznbqILGuu73hug= github.com/aws/aws-sdk-go-v2/service/sts v1.41.2 h1:a5UTtD4mHBU3t0o6aHQZFJTNKVfxFWfPX7J0Lr7G+uY= github.com/aws/aws-sdk-go-v2/service/sts v1.41.2/go.mod h1:6TxbXoDSgBQ225Qd8Q+MbxUxUh6TtNKwbRt/EPS9xso= github.com/aws/smithy-go v1.23.2 h1:Crv0eatJUQhaManss33hS5r40CG3ZFH+21XSkqMrIUM= github.com/aws/smithy-go v1.23.2/go.mod h1:LEj2LM3rBRQJxPZTB4KuzZkaZYnZPnvgIhb4pu07mx0= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/coreos/go-systemd/v22 v22.6.0 h1:aGVa/v8B7hpb0TKl0MWoAavPDmHvobFe5R5zn0bCJWo= github.com/coreos/go-systemd/v22 v22.6.0/go.mod h1:iG+pp635Fo7ZmV/j14KUcmEyWF+0X7Lua8rrTWzYgWU= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/golang-jwt/jwt/v5 v5.3.0 h1:pv4AsKCKKZuqlgs5sUmn4x8UlGa0kEVt/puTpKx9vvo= github.com/golang-jwt/jwt/v5 v5.3.0/go.mod h1:fxCRLWMO43lRc8nhHWY6LGqRcf+1gQWArsqaEUEa5bE= github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/imdario/mergo v0.3.13 h1:lFzP57bqS/wsqKssCGmtLAb8A0wKjLGrve2q3PPVcBk= github.com/imdario/mergo v0.3.13/go.mod h1:4lJ1jqUDcsbIECGy0RUJAXNIhg+6ocWgb1ALK2O4oXg= github.com/jpillora/backoff v1.0.0 h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/klauspost/compress v1.18.0 h1:c/Cqfb0r+Yi+JtIEq73FWXVkRonBlf0CRNYc8Zttxdo= github.com/klauspost/compress v1.18.0/go.mod h1:2Pp+KzxcywXVXMr50+X0Q/Lsb43OQHYWRCY2AiWywWQ= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/mdlayher/socket v0.4.1 h1:eM9y2/jlbs1M615oshPQOHZzj6R6wMT7bX5NPiQvn2U= github.com/mdlayher/socket v0.4.1/go.mod h1:cAqeGjoufqdxWkD7DkpyS+wcefOtmu5OQ8KuoJGIReA= github.com/mdlayher/vsock v1.2.1 h1:pC1mTJTvjo1r9n9fbm7S1j04rCgCzhCOS5DY0zqHlnQ= github.com/mdlayher/vsock v1.2.1/go.mod h1:NRfCibel++DgeMD8z/hP+PPTjlNJsdPOmxcnENvE+SE= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/prometheus/client_golang v1.23.2 h1:Je96obch5RDVy3FDMndoUsjAhG5Edi49h0RJWRi/o0o= github.com/prometheus/client_golang v1.23.2/go.mod h1:Tb1a6LWHB3/SPIzCoaDXI4I8UHKeFTEQ1YCr+0Gyqmg= github.com/prometheus/client_model v0.6.2 h1:oBsgwpGs7iVziMvrGhE53c/GrLUsZdHnqNwqPLxwZyk= github.com/prometheus/client_model v0.6.2/go.mod h1:y3m2F6Gdpfy6Ut/GBsUqTWZqCUvMVzSfMLjcu6wAwpE= github.com/prometheus/common v0.67.4 h1:yR3NqWO1/UyO1w2PhUvXlGQs/PtFmoveVO0KZ4+Lvsc= github.com/prometheus/common v0.67.4/go.mod h1:gP0fq6YjjNCLssJCQp0yk4M8W6ikLURwkdd/YKtTbyI= github.com/prometheus/exporter-toolkit v0.15.0 h1:Pcle5sSViwR1x0gdPd0wtYrPQENBieQAM7TmT0qtb2U= github.com/prometheus/exporter-toolkit v0.15.0/go.mod h1:OyRWd2iTo6Xge9Kedvv0IhCrJSBu36JCfJ2yVniRIYk= github.com/prometheus/procfs v0.16.1 h1:hZ15bTNuirocR6u0JZ6BAHHmwS1p8B4P6MRqxtzMyRg= github.com/prometheus/procfs v0.16.1/go.mod h1:teAbpZRB1iIAJYREa1LsoWUXykVXA1KlTmWl8x/U+Is= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= github.com/xhit/go-str2duration/v2 v2.1.0 h1:lxklc02Drh6ynqX+DdPyp5pCKLUQpRT8bp8Ydu2Bstc= github.com/xhit/go-str2duration/v2 v2.1.0/go.mod h1:ohY8p+0f07DiV6Em5LKB0s2YpLtXVyJfNt1+BlmyAsU= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.yaml.in/yaml/v2 v2.4.3 h1:6gvOSjQoTB3vt1l+CU+tSyi/HOjfOjRLJ4YwYZGwRO0= go.yaml.in/yaml/v2 v2.4.3/go.mod h1:zSxWcmIDjOzPXpjlTTbAsKokqkDNAVtZO0WOMiT90s8= go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc= go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg= golang.org/x/crypto v0.45.0 h1:jMBrvKuj23MTlT0bQEOBcAE0mjg8mK9RXFhRH6nyF3Q= golang.org/x/crypto v0.45.0/go.mod h1:XTGrrkGJve7CYK7J8PEww4aY7gM3qMCElcJQ8n8JdX4= golang.org/x/net v0.47.0 h1:Mx+4dIFzqraBXUugkia1OOvlD6LemFo1ALMHjrXDOhY= golang.org/x/net v0.47.0/go.mod h1:/jNxtkgq5yWUGYkaZGqo27cfGZ1c5Nen03aYrrKpVRU= golang.org/x/oauth2 v0.32.0 h1:jsCblLleRMDrxMN29H3z/k1KliIvpLgCkE6R8FXXNgY= golang.org/x/oauth2 v0.32.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA= golang.org/x/sync v0.18.0 h1:kr88TuHDroi+UVf+0hZnirlk8o8T+4MrK6mr60WkH/I= golang.org/x/sync v0.18.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= golang.org/x/sys v0.38.0 h1:3yZWxaJjBmCWXqhN1qh02AkOnCQ1poK6oF+a7xWL6Gc= golang.org/x/sys v0.38.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks= golang.org/x/text v0.31.0 h1:aC8ghyu4JhP8VojJ2lEHBnochRno1sgL6nEi9WGFGMM= golang.org/x/text v0.31.0/go.mod h1:tKRAlv61yKIjGGHX/4tP1LTbc13YSec1pxVEWXzfoeM= golang.org/x/time v0.13.0 h1:eUlYslOIt32DgYD6utsuUeHs4d7AsEYLuIAdg7FlYgI= golang.org/x/time v0.13.0/go.mod h1:eL/Oa2bBBK0TkX57Fyni+NgnyQQN4LitPmob2Hjnqw4= google.golang.org/protobuf v1.36.10 h1:AYd7cD/uASjIL6Q9LiTjz8JLcrh/88q5UObnmY3aOOE= google.golang.org/protobuf v1.36.10/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= prometheus-elasticsearch-exporter-1.10.0/main.go000066400000000000000000000332151511562765300217340ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package main import ( "context" "fmt" "io" "net/http" _ "net/http/pprof" "net/url" "os" "os/signal" "strings" "time" "github.com/alecthomas/kingpin/v2" "github.com/prometheus/client_golang/prometheus" versioncollector "github.com/prometheus/client_golang/prometheus/collectors/version" "github.com/prometheus/client_golang/prometheus/promhttp" "github.com/prometheus/common/promslog" "github.com/prometheus/common/promslog/flag" "github.com/prometheus/common/version" "github.com/prometheus/exporter-toolkit/web" webflag "github.com/prometheus/exporter-toolkit/web/kingpinflag" "github.com/prometheus-community/elasticsearch_exporter/collector" "github.com/prometheus-community/elasticsearch_exporter/config" "github.com/prometheus-community/elasticsearch_exporter/pkg/clusterinfo" "github.com/prometheus-community/elasticsearch_exporter/pkg/roundtripper" ) const name = "elasticsearch_exporter" type transportWithAPIKey struct { underlyingTransport http.RoundTripper apiKey string } func (t *transportWithAPIKey) RoundTrip(req *http.Request) (*http.Response, error) { req.Header.Add("Authorization", fmt.Sprintf("ApiKey %s", t.apiKey)) return t.underlyingTransport.RoundTrip(req) } func main() { var ( metricsPath = kingpin.Flag("web.telemetry-path", "Path under which to expose metrics."). Default("/metrics").String() toolkitFlags = webflag.AddFlags(kingpin.CommandLine, ":9114") esURI = kingpin.Flag("es.uri", "HTTP API address of an Elasticsearch node."). Default("").String() esTimeout = kingpin.Flag("es.timeout", "Timeout for trying to get stats from Elasticsearch."). Default("5s").Duration() esAllNodes = kingpin.Flag("es.all", "Export stats for all nodes in the cluster. If used, this flag will override the flag es.node."). Default("false").Bool() esNode = kingpin.Flag("es.node", "Node's name of which metrics should be exposed."). Default("_local").String() esExportIndices = kingpin.Flag("es.indices", "Export stats for indices in the cluster."). Default("false").Bool() esExportIndicesSettings = kingpin.Flag("es.indices_settings", "Export stats for settings of all indices of the cluster."). Default("false").Bool() esExportIndicesMappings = kingpin.Flag("es.indices_mappings", "Export stats for mappings of all indices of the cluster."). Default("false").Bool() esExportIndexAliases = kingpin.Flag("es.aliases", "Export informational alias metrics."). Default("true").Bool() esExportShards = kingpin.Flag("es.shards", "Export stats for shards in the cluster (implies --es.indices)."). Default("false").Bool() esClusterInfoInterval = kingpin.Flag("es.clusterinfo.interval", "Cluster info update interval for the cluster label"). Default("5m").Duration() esCA = kingpin.Flag("es.ca", "Path to PEM file that contains trusted Certificate Authorities for the Elasticsearch connection."). Default("").String() esClientPrivateKey = kingpin.Flag("es.client-private-key", "Path to PEM file that contains the private key for client auth when connecting to Elasticsearch."). Default("").String() esClientCert = kingpin.Flag("es.client-cert", "Path to PEM file that contains the corresponding cert for the private key to connect to Elasticsearch."). Default("").String() esInsecureSkipVerify = kingpin.Flag("es.ssl-skip-verify", "Skip SSL verification when connecting to Elasticsearch."). Default("false").Bool() logOutput = kingpin.Flag("log.output", "Sets the log output. Valid outputs are stdout and stderr"). Default("stdout").String() awsRegion = kingpin.Flag("aws.region", "Region for AWS elasticsearch"). Default("").String() awsRoleArn = kingpin.Flag("aws.role-arn", "Role ARN of an IAM role to assume."). Default("").String() configFile = kingpin.Flag("config.file", "Path to YAML configuration file.").Default("").String() ) promslogConfig := &promslog.Config{} flag.AddFlags(kingpin.CommandLine, promslogConfig) kingpin.Version(version.Print(name)) kingpin.CommandLine.HelpFlag.Short('h') kingpin.Parse() // Load optional YAML config var cfg *config.Config if *configFile != "" { var cfgErr error cfg, cfgErr = config.LoadConfig(*configFile) if cfgErr != nil { // At this stage logger not yet created; fallback to stderr fmt.Fprintf(os.Stderr, "failed to load config file: %v\n", cfgErr) os.Exit(1) } } var w io.Writer switch strings.ToLower(*logOutput) { case "stderr": w = os.Stderr case "stdout": w = os.Stdout default: w = os.Stdout } promslogConfig.Writer = w logger := promslog.New(promslogConfig) // version metric prometheus.MustRegister(versioncollector.NewCollector(name)) // Create a context that is cancelled on SIGKILL or SIGINT. ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt, os.Kill) defer cancel() if *esURI != "" { esURL, err := url.Parse(*esURI) if err != nil { logger.Error("failed to parse es.uri", "err", err) os.Exit(1) } esUsername := os.Getenv("ES_USERNAME") esPassword := os.Getenv("ES_PASSWORD") if esUsername != "" && esPassword != "" { esURL.User = url.UserPassword(esUsername, esPassword) } // returns nil if not provided and falls back to simple TCP. tlsConfig := createTLSConfig(*esCA, *esClientCert, *esClientPrivateKey, *esInsecureSkipVerify) var httpTransport http.RoundTripper httpTransport = &http.Transport{ TLSClientConfig: tlsConfig, Proxy: http.ProxyFromEnvironment, } esAPIKey := os.Getenv("ES_API_KEY") if esAPIKey != "" { httpTransport = &transportWithAPIKey{ underlyingTransport: httpTransport, apiKey: esAPIKey, } } httpClient := &http.Client{ Timeout: *esTimeout, Transport: httpTransport, } if *awsRegion != "" { var err error httpClient.Transport, err = roundtripper.NewAWSSigningTransport(httpTransport, *awsRegion, *awsRoleArn, logger) if err != nil { logger.Error("failed to create AWS transport", "err", err) os.Exit(1) } } // create the exporter exporter, err := collector.NewElasticsearchCollector( logger, []string{}, collector.WithElasticsearchURL(esURL), collector.WithHTTPClient(httpClient), ) if err != nil { logger.Error("failed to create Elasticsearch collector", "err", err) os.Exit(1) } prometheus.MustRegister(exporter) // TODO(@sysadmind): Remove this when we have a better way to get the cluster name to down stream collectors. // cluster info retriever clusterInfoRetriever := clusterinfo.New(logger, httpClient, esURL, *esClusterInfoInterval) prometheus.MustRegister(collector.NewClusterHealth(logger, httpClient, esURL)) prometheus.MustRegister(collector.NewNodes(logger, httpClient, esURL, *esAllNodes, *esNode)) if *esExportIndices || *esExportShards { sC := collector.NewShards(logger, httpClient, esURL) prometheus.MustRegister(sC) iC := collector.NewIndices(logger, httpClient, esURL, *esExportShards, *esExportIndexAliases) prometheus.MustRegister(iC) if registerErr := clusterInfoRetriever.RegisterConsumer(iC); registerErr != nil { logger.Error("failed to register indices collector in cluster info") os.Exit(1) } if registerErr := clusterInfoRetriever.RegisterConsumer(sC); registerErr != nil { logger.Error("failed to register shards collector in cluster info") os.Exit(1) } } if *esExportIndicesSettings { prometheus.MustRegister(collector.NewIndicesSettings(logger, httpClient, esURL)) } if *esExportIndicesMappings { prometheus.MustRegister(collector.NewIndicesMappings(logger, httpClient, esURL)) } // start the cluster info retriever switch runErr := clusterInfoRetriever.Run(ctx); runErr { case nil: logger.Info("started cluster info retriever", "interval", (*esClusterInfoInterval).String()) case clusterinfo.ErrInitialCallTimeout: logger.Info("initial cluster info call timed out") default: logger.Error("failed to run cluster info retriever", "err", runErr) os.Exit(1) } // register cluster info retriever as prometheus collector prometheus.MustRegister(clusterInfoRetriever) } http.HandleFunc(*metricsPath, func(w http.ResponseWriter, r *http.Request) { // /metrics endpoint is reserved for single-target mode only. // For per-scrape overrides use the dedicated /probe endpoint. promhttp.Handler().ServeHTTP(w, r) }) if *metricsPath != "/" && *metricsPath != "" { landingConfig := web.LandingConfig{ Name: "Elasticsearch Exporter", Description: "Prometheus Exporter for Elasticsearch servers", Version: version.Info(), Links: []web.LandingLinks{ { Address: *metricsPath, Text: "Metrics", }, }, } landingPage, err := web.NewLandingPage(landingConfig) if err != nil { logger.Error("error creating landing page", "err", err) os.Exit(1) } http.Handle("/", landingPage) } // health endpoint http.HandleFunc("/healthz", func(w http.ResponseWriter, r *http.Request) { http.Error(w, http.StatusText(http.StatusOK), http.StatusOK) }) // probe endpoint http.HandleFunc("/probe", func(w http.ResponseWriter, r *http.Request) { origQuery := r.URL.Query() targetStr, am, valErr := validateProbeParams(cfg, origQuery) if valErr != nil { http.Error(w, valErr.Error(), http.StatusBadRequest) return } targetURL, _ := url.Parse(targetStr) if am != nil { // Apply userpass credentials only if the module type is explicitly set to userpass. if strings.EqualFold(am.Type, "userpass") && am.UserPass != nil { targetURL.User = url.UserPassword(am.UserPass.Username, am.UserPass.Password) } if len(am.Options) > 0 { q := targetURL.Query() for k, v := range am.Options { q.Set(k, v) } targetURL.RawQuery = q.Encode() } } // Build a dedicated HTTP client for this probe request (reuse TLS opts, timeout, etc.). pemCA := *esCA pemCert := *esClientCert pemKey := *esClientPrivateKey insecure := *esInsecureSkipVerify // Apply TLS configuration from auth module if provided (for transport security) // This matches single-target behavior where TLS settings are always applied if am != nil && am.TLS != nil { // Override with module-specific TLS settings if am.TLS.CAFile != "" { pemCA = am.TLS.CAFile } if am.TLS.CertFile != "" { pemCert = am.TLS.CertFile } if am.TLS.KeyFile != "" { pemKey = am.TLS.KeyFile } if am.TLS.InsecureSkipVerify { insecure = true } } tlsCfg := createTLSConfig(pemCA, pemCert, pemKey, insecure) var transport http.RoundTripper = &http.Transport{ TLSClientConfig: tlsCfg, Proxy: http.ProxyFromEnvironment, } // inject authentication based on auth_module type if am != nil { switch strings.ToLower(am.Type) { case "apikey": if am.APIKey != "" { transport = &transportWithAPIKey{ underlyingTransport: transport, apiKey: am.APIKey, } } case "aws": var region string if am.AWS.Region != "" { region = am.AWS.Region } var err error transport, err = roundtripper.NewAWSSigningTransport(transport, region, am.AWS.RoleARN, logger) if err != nil { http.Error(w, "failed to create AWS signing transport", http.StatusInternalServerError) return } case "tls": // No additional auth wrapper needed - client certificates in TLS config handle authentication case "userpass": // Already handled above by setting targetURL.User } } probeClient := &http.Client{ Timeout: *esTimeout, Transport: transport, } reg := prometheus.NewRegistry() // version metric reg.MustRegister(versioncollector.NewCollector(name)) // Core exporter collector exp, err := collector.NewElasticsearchCollector( logger, []string{}, collector.WithElasticsearchURL(targetURL), collector.WithHTTPClient(probeClient), ) if err != nil { http.Error(w, "failed to create exporter", http.StatusInternalServerError) return } reg.MustRegister(exp) // Basic additional collectors – reuse global CLI flags reg.MustRegister(collector.NewClusterHealth(logger, probeClient, targetURL)) reg.MustRegister(collector.NewNodes(logger, probeClient, targetURL, *esAllNodes, *esNode)) if *esExportIndices || *esExportShards { shardsC := collector.NewShards(logger, probeClient, targetURL) indicesC := collector.NewIndices(logger, probeClient, targetURL, *esExportShards, *esExportIndexAliases) reg.MustRegister(shardsC) reg.MustRegister(indicesC) } if *esExportIndicesSettings { reg.MustRegister(collector.NewIndicesSettings(logger, probeClient, targetURL)) } if *esExportIndicesMappings { reg.MustRegister(collector.NewIndicesMappings(logger, probeClient, targetURL)) } promhttp.HandlerFor(reg, promhttp.HandlerOpts{}).ServeHTTP(w, r) }) server := &http.Server{} go func() { if err := web.ListenAndServe(server, toolkitFlags, logger); err != nil { logger.Error("http server quit", "err", err) os.Exit(1) } }() <-ctx.Done() logger.Info("shutting down") // create a context for graceful http server shutdown srvCtx, srvCancel := context.WithTimeout(context.Background(), 5*time.Second) defer srvCancel() _ = server.Shutdown(srvCtx) } prometheus-elasticsearch-exporter-1.10.0/metrics.md000066400000000000000000001110201511562765300224400ustar00rootroot00000000000000# Metrics | Name | Type | Cardinality | Help | |----------------------------------------------------------------------|------------|-------------|-----------------------------------------------------------------------------------------------------| | elasticsearch_breakers_estimated_size_bytes | gauge | 4 | Estimated size in bytes of breaker | | elasticsearch_breakers_limit_size_bytes | gauge | 4 | Limit size in bytes for breaker | | elasticsearch_breakers_tripped | counter | 4 | tripped for breaker | | elasticsearch_cluster_health_active_primary_shards | gauge | 1 | The number of primary shards in your cluster. This is an aggregate total across all indices. | | elasticsearch_cluster_health_active_shards | gauge | 1 | Aggregate total of all shards across all indices, which includes replica shards. | | elasticsearch_cluster_health_delayed_unassigned_shards | gauge | 1 | Shards delayed to reduce reallocation overhead | | elasticsearch_cluster_health_initializing_shards | gauge | 1 | Count of shards that are being freshly created. | | elasticsearch_cluster_health_number_of_data_nodes | gauge | 1 | Number of data nodes in the cluster. | | elasticsearch_cluster_health_number_of_in_flight_fetch | gauge | 1 | The number of ongoing shard info requests. | | elasticsearch_cluster_health_number_of_nodes | gauge | 1 | Number of nodes in the cluster. | | elasticsearch_cluster_health_number_of_pending_tasks | gauge | 1 | Cluster level changes which have not yet been executed | | elasticsearch_cluster_health_task_max_waiting_in_queue_millis | gauge | 1 | Max time in millis that a task is waiting in queue. | | elasticsearch_cluster_health_relocating_shards | gauge | 1 | The number of shards that are currently moving from one node to another node. | | elasticsearch_cluster_health_status | gauge | 3 | Whether all primary and replica shards are allocated. | | elasticsearch_cluster_health_unassigned_shards | gauge | 1 | The number of shards that exist in the cluster state, but cannot be found in the cluster itself. | | elasticsearch_clustersettings_stats_max_shards_per_node | gauge | 0 | Current maximum number of shards per node setting. | | elasticsearch_clustersettings_allocation_threshold_enabled | gauge | 0 | Is disk allocation decider enabled. | | elasticsearch_clustersettings_allocation_watermark_flood_stage_bytes | gauge | 0 | Flood stage watermark as in bytes. | | elasticsearch_clustersettings_allocation_watermark_high_bytes | gauge | 0 | High watermark for disk usage in bytes. | | elasticsearch_clustersettings_allocation_watermark_low_bytes | gauge | 0 | Low watermark for disk usage in bytes. | | elasticsearch_clustersettings_allocation_watermark_flood_stage_ratio | gauge | 0 | Flood stage watermark as a ratio. | | elasticsearch_clustersettings_allocation_watermark_high_ratio | gauge | 0 | High watermark for disk usage as a ratio. | | elasticsearch_clustersettings_allocation_watermark_low_ratio | gauge | 0 | Low watermark for disk usage as a ratio. | | elasticsearch_filesystem_data_available_bytes | gauge | 1 | Available space on block device in bytes | | elasticsearch_filesystem_data_free_bytes | gauge | 1 | Free space on block device in bytes | | elasticsearch_filesystem_data_size_bytes | gauge | 1 | Size of block device in bytes | | elasticsearch_filesystem_io_stats_device_operations_count | gauge | 1 | Count of disk operations | | elasticsearch_filesystem_io_stats_device_read_operations_count | gauge | 1 | Count of disk read operations | | elasticsearch_filesystem_io_stats_device_write_operations_count | gauge | 1 | Count of disk write operations | | elasticsearch_filesystem_io_stats_device_read_size_kilobytes_sum | gauge | 1 | Total kilobytes read from disk | | elasticsearch_filesystem_io_stats_device_write_size_kilobytes_sum | gauge | 1 | Total kilobytes written to disk | | elasticsearch_ilm_status | gauge | 1 | Current status of ILM. Status can be `STOPPED`, `RUNNING`, `STOPPING`. | | elasticsearch_ilm_index_status | gauge | 4 | Status of ILM policy for index | | elasticsearch_indices_active_queries | gauge | 1 | The number of currently active queries | | elasticsearch_indices_docs | gauge | 1 | Count of documents on this node | | elasticsearch_indices_docs_deleted | gauge | 1 | Count of deleted documents on this node | | elasticsearch_indices_deleted_docs_primary | gauge | 1 | Count of deleted documents with only primary shards | | elasticsearch_indices_docs_primary | gauge | 1 | Count of documents with only primary shards on all nodes | | elasticsearch_indices_docs_total | gauge | | Count of documents with shards on all nodes | | elasticsearch_indices_fielddata_evictions | counter | 1 | Evictions from field data | | elasticsearch_indices_fielddata_memory_size_bytes | gauge | 1 | Field data cache memory usage in bytes | | elasticsearch_indices_filter_cache_evictions | counter | 1 | Evictions from filter cache | | elasticsearch_indices_filter_cache_memory_size_bytes | gauge | 1 | Filter cache memory usage in bytes | | elasticsearch_indices_flush_time_seconds | counter | 1 | Cumulative flush time in seconds | | elasticsearch_indices_flush_total | counter | 1 | Total flushes | | elasticsearch_indices_get_exists_time_seconds | counter | 1 | Total time get exists in seconds | | elasticsearch_indices_get_exists_total | counter | 1 | Total get exists operations | | elasticsearch_indices_get_missing_time_seconds | counter | 1 | Total time of get missing in seconds | | elasticsearch_indices_get_missing_total | counter | 1 | Total get missing | | elasticsearch_indices_get_time_seconds | counter | 1 | Total get time in seconds | | elasticsearch_indices_get_total | counter | 1 | Total get | | elasticsearch_indices_indexing_delete_time_seconds_total | counter | 1 | Total time indexing delete in seconds | | elasticsearch_indices_indexing_delete_total | counter | 1 | Total indexing deletes | | elasticsearch_indices_index_current | gauge | 1 | The number of documents currently being indexed to an index | | elasticsearch_indices_indexing_index_time_seconds_total | counter | 1 | Cumulative index time in seconds | | elasticsearch_indices_indexing_index_total | counter | 1 | Total index calls | | elasticsearch_indices_mappings_stats_fields | gauge | 1 | Count of fields currently mapped by index | | elasticsearch_indices_mappings_stats_json_parse_failures_total | counter | 0 | Number of errors while parsing JSON | | elasticsearch_indices_mappings_stats_scrapes_total | counter | 0 | Current total Elasticsearch Indices Mappings scrapes | | elasticsearch_indices_mappings_stats_up | gauge | 0 | Was the last scrape of the Elasticsearch Indices Mappings endpoint successful | | elasticsearch_indices_merges_docs_total | counter | 1 | Cumulative docs merged | | elasticsearch_indices_merges_total | counter | 1 | Total merges | | elasticsearch_indices_merges_total_size_bytes_total | counter | 1 | Total merge size in bytes | | elasticsearch_indices_merges_total_time_seconds_total | counter | 1 | Total time spent merging in seconds | | elasticsearch_indices_query_cache_cache_total | counter | 1 | Count of query cache | | elasticsearch_indices_query_cache_cache_size | gauge | 1 | Size of query cache | | elasticsearch_indices_query_cache_count | counter | 2 | Count of query cache hit/miss | | elasticsearch_indices_query_cache_evictions | counter | 1 | Evictions from query cache | | elasticsearch_indices_query_cache_memory_size_bytes | gauge | 1 | Query cache memory usage in bytes | | elasticsearch_indices_query_cache_total | counter | 1 | Size of query cache total | | elasticsearch_indices_refresh_time_seconds_total | counter | 1 | Total time spent refreshing in seconds | | elasticsearch_indices_refresh_total | counter | 1 | Total refreshes | | elasticsearch_indices_request_cache_count | counter | 2 | Count of request cache hit/miss | | elasticsearch_indices_request_cache_evictions | counter | 1 | Evictions from request cache | | elasticsearch_indices_request_cache_memory_size_bytes | gauge | 1 | Request cache memory usage in bytes | | elasticsearch_indices_search_fetch_time_seconds | counter | 1 | Total search fetch time in seconds | | elasticsearch_indices_search_fetch_total | counter | 1 | Total number of fetches | | elasticsearch_indices_search_query_time_seconds | counter | 1 | Total search query time in seconds | | elasticsearch_indices_search_query_total | counter | 1 | Total number of queries | | elasticsearch_indices_segments_count | gauge | 1 | Count of index segments on this node | | elasticsearch_indices_segments_memory_bytes | gauge | 1 | Current memory size of segments in bytes | | elasticsearch_indices_settings_creation_timestamp_seconds | gauge | 1 | Timestamp of the index creation in seconds | | elasticsearch_indices_settings_stats_read_only_indices | gauge | 1 | Count of indices that have read_only_allow_delete=true | | elasticsearch_indices_settings_total_fields | gauge | | Index setting value for index.mapping.total_fields.limit (total allowable mapped fields in a index) | | elasticsearch_indices_settings_replicas | gauge | | Index setting value for index.replicas | | elasticsearch_indices_shards_docs | gauge | 3 | Count of documents on this shard | | elasticsearch_indices_shards_docs_deleted | gauge | 3 | Count of deleted documents on each shard | | elasticsearch_indices_store_size_bytes | gauge | 1 | Current size of stored index data in bytes | | elasticsearch_indices_store_size_bytes_primary | gauge | | Current size of stored index data in bytes with only primary shards on all nodes | | elasticsearch_indices_store_size_bytes_total | gauge | | Current size of stored index data in bytes with all shards on all nodes | | elasticsearch_indices_store_throttle_time_seconds_total | counter | 1 | Throttle time for index store in seconds | | elasticsearch_indices_translog_operations | counter | 1 | Total translog operations | | elasticsearch_indices_translog_size_in_bytes | counter | 1 | Total translog size in bytes | | elasticsearch_indices_warmer_time_seconds_total | counter | 1 | Total warmer time in seconds | | elasticsearch_indices_warmer_total | counter | 1 | Total warmer count | | elasticsearch_jvm_gc_collection_seconds_count | counter | 2 | Count of JVM GC runs | | elasticsearch_jvm_gc_collection_seconds_sum | counter | 2 | GC run time in seconds | | elasticsearch_jvm_memory_committed_bytes | gauge | 2 | JVM memory currently committed by area | | elasticsearch_jvm_memory_max_bytes | gauge | 1 | JVM memory max | | elasticsearch_jvm_memory_used_bytes | gauge | 2 | JVM memory currently used by area | | elasticsearch_jvm_memory_pool_used_bytes | gauge | 3 | JVM memory currently used by pool | | elasticsearch_jvm_memory_pool_max_bytes | counter | 3 | JVM memory max by pool | | elasticsearch_jvm_memory_pool_peak_used_bytes | counter | 3 | JVM memory peak used by pool | | elasticsearch_jvm_memory_pool_peak_max_bytes | counter | 3 | JVM memory peak max by pool | | elasticsearch_os_cpu_percent | gauge | 1 | Percent CPU used by the OS | | elasticsearch_os_load1 | gauge | 1 | Shortterm load average | | elasticsearch_os_load5 | gauge | 1 | Midterm load average | | elasticsearch_os_load15 | gauge | 1 | Longterm load average | | elasticsearch_process_cpu_percent | gauge | 1 | Percent CPU used by process | | elasticsearch_process_cpu_seconds_total | counter | 1 | Process CPU time in seconds | | elasticsearch_process_mem_resident_size_bytes | gauge | 1 | Resident memory in use by process in bytes | | elasticsearch_process_mem_share_size_bytes | gauge | 1 | Shared memory in use by process in bytes | | elasticsearch_process_mem_virtual_size_bytes | gauge | 1 | Total virtual memory used in bytes | | elasticsearch_process_open_files_count | gauge | 1 | Open file descriptors | | elasticsearch_snapshot_stats_number_of_snapshots | gauge | 1 | Total number of snapshots | | elasticsearch_snapshot_stats_oldest_snapshot_timestamp | gauge | 1 | Oldest snapshot timestamp | | elasticsearch_snapshot_stats_snapshot_start_time_timestamp | gauge | 1 | Last snapshot start timestamp | | elasticsearch_snapshot_stats_latest_snapshot_timestamp_seconds | gauge | 1 | Timestamp of the latest SUCCESS or PARTIAL snapshot | | elasticsearch_snapshot_stats_snapshot_end_time_timestamp | gauge | 1 | Last snapshot end timestamp | | elasticsearch_snapshot_stats_snapshot_number_of_failures | gauge | 1 | Last snapshot number of failures | | elasticsearch_snapshot_stats_snapshot_number_of_indices | gauge | 1 | Last snapshot number of indices | | elasticsearch_snapshot_stats_snapshot_failed_shards | gauge | 1 | Last snapshot failed shards | | elasticsearch_snapshot_stats_snapshot_successful_shards | gauge | 1 | Last snapshot successful shards | | elasticsearch_snapshot_stats_snapshot_total_shards | gauge | 1 | Last snapshot total shard | | elasticsearch_thread_pool_active_count | gauge | 14 | Thread Pool threads active | | elasticsearch_thread_pool_completed_count | counter | 14 | Thread Pool operations completed | | elasticsearch_thread_pool_largest_count | gauge | 14 | Thread Pool largest threads count | | elasticsearch_thread_pool_queue_count | gauge | 14 | Thread Pool operations queued | | elasticsearch_thread_pool_rejected_count | counter | 14 | Thread Pool operations rejected | | elasticsearch_thread_pool_threads_count | gauge | 14 | Thread Pool current threads count | | elasticsearch_transport_rx_packets_total | counter | 1 | Count of packets received | | elasticsearch_transport_rx_size_bytes_total | counter | 1 | Total number of bytes received | | elasticsearch_transport_tx_packets_total | counter | 1 | Count of packets sent | | elasticsearch_transport_tx_size_bytes_total | counter | 1 | Total number of bytes sent | | elasticsearch_clusterinfo_last_retrieval_success_ts | gauge | 1 | Timestamp of the last successful cluster info retrieval | | elasticsearch_clusterinfo_up | gauge | 1 | Up metric for the cluster info collector | | elasticsearch_clusterinfo_version_info | gauge | 6 | Constant metric with ES version information as labels | | elasticsearch_slm_stats_up | gauge | 0 | Up metric for SLM collector | | elasticsearch_slm_stats_total_scrapes | counter | 0 | Number of scrapes for SLM collector | | elasticsearch_slm_stats_json_parse_failures | counter | 0 | JSON parse failures for SLM collector | | elasticsearch_slm_stats_retention_runs_total | counter | 0 | Total retention runs | | elasticsearch_slm_stats_retention_failed_total | counter | 0 | Total failed retention runs | | elasticsearch_slm_stats_retention_timed_out_total | counter | 0 | Total retention run timeouts | | elasticsearch_slm_stats_retention_deletion_time_seconds | gauge | 0 | Retention run deletion time | | elasticsearch_slm_stats_total_snapshots_taken_total | counter | 0 | Total snapshots taken | | elasticsearch_slm_stats_total_snapshots_failed_total | counter | 0 | Total snapshots failed | | elasticsearch_slm_stats_total_snapshots_deleted_total | counter | 0 | Total snapshots deleted | | elasticsearch_slm_stats_total_snapshots_failed_total | counter | 0 | Total snapshots failed | | elasticsearch_slm_stats_snapshots_taken_total | counter | 1 | Snapshots taken by policy | | elasticsearch_slm_stats_snapshots_failed_total | counter | 1 | Snapshots failed by policy | | elasticsearch_slm_stats_snapshots_deleted_total | counter | 1 | Snapshots deleted by policy | | elasticsearch_slm_stats_snapshot_deletion_failures_total | counter | 1 | Snapshot deletion failures by policy | | elasticsearch_slm_stats_operation_mode | gauge | 1 | SLM operation mode (Running, stopping, stopped) | | elasticsearch_data_stream_stats_up | gauge | 0 | Up metric for Data Stream collection | | elasticsearch_data_stream_stats_total_scrapes | counter | 0 | Total scrapes for Data Stream stats | | elasticsearch_data_stream_stats_json_parse_failures | counter | 0 | Number of parsing failures for Data Stream stats | | elasticsearch_data_stream_backing_indices_total | gauge | 1 | Number of backing indices for Data Stream | | elasticsearch_data_stream_store_size_bytes | gauge | 1 | Current size of data stream backing indices in bytes | | elasticsearch_health_report_creating_primaries | gauge | 1 | The number of creating primary shards | | elasticsearch_health_report_creating_replicas | gauge | 1 | The number of creating replica shards | | elasticsearch_health_report_data_stream_lifecycle_status | gauge | 2 | Data stream lifecycle status | | elasticsearch_health_report_disk_status | gauge | 2 | disk status | | elasticsearch_health_report_ilm_policies | gauge | 1 | The number of ILM Policies | | elasticsearch_health_report_ilm_stagnating_indices | gauge | 1 | The number of stagnating indices | | elasticsearch_health_report_ilm_status | gauge | 2 | ILM status | | elasticsearch_health_report_initializing_primaries | gauge | 1 | The number of initializing primary shards | | elasticsearch_health_report_initializing_replicas | gauge | 1 | The number of initializing replica shards | | elasticsearch_health_report_master_is_stable_status | gauge | 2 | Master is stable status | | elasticsearch_health_report_max_shards_in_cluster_data | gauge | 1 | The number of maximum shards in a cluster | | elasticsearch_health_report_max_shards_in_cluster_frozen | gauge | 1 | The number of maximum frozen shards in a cluster | | elasticsearch_health_report_repository_integrity_status | gauge | 2 | Repository integrity status | | elasticsearch_health_report_restarting_primaries | gauge | 1 | The number of restarting primary shards | | elasticsearch_health_report_restarting_replicas | gauge | 1 | The number of restarting replica shards | | elasticsearch_health_report_shards_availabilty_status | gauge | 2 | Shards availabilty status | | elasticsearch_health_report_shards_capacity_status | gauge | 2 | Shards capacity status | | elasticsearch_health_report_slm_policies | gauge | 1 | The number of SLM policies | | elasticsearch_health_report_slm_status | gauge | 2 | SLM status | | elasticsearch_health_report_started_primaries | gauge | 1 | The number of started primary shards | | elasticsearch_health_report_started_replicas | gauge | 1 | The number of started replica shards | | elasticsearch_health_report_status | gauge | 2 | Overall cluster status | | elasticsearch_health_report_total_repositories | gauge | 1 | The number snapshot repositories | | elasticsearch_health_report_unassigned_primaries | gauge | 1 | The number of unassigned primary shards | | elasticsearch_health_report_unassigned_replicas | gauge | 1 | The number of unassigned replica shards | prometheus-elasticsearch-exporter-1.10.0/pkg/000077500000000000000000000000001511562765300212365ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/pkg/clusterinfo/000077500000000000000000000000001511562765300235735ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/pkg/clusterinfo/clusterinfo.go000066400000000000000000000172051511562765300264640ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package clusterinfo import ( "context" "encoding/json" "errors" "fmt" "io" "log/slog" "net/http" "net/url" "path" "time" "github.com/prometheus/client_golang/prometheus" ) const ( namespace = "elasticsearch" subsystem = "clusterinfo" ) var ( // ErrConsumerAlreadyRegistered is returned if a consumer is already registered ErrConsumerAlreadyRegistered = errors.New("consumer already registered") // ErrInitialCallTimeout is returned if the initial clusterinfo call timed out ErrInitialCallTimeout = errors.New("initial cluster info call timed out") initialTimeout = 10 * time.Second ) type consumer interface { // ClusterLabelUpdates returns a pointer to channel for cluster label updates ClusterLabelUpdates() *chan *Response // String implements the stringer interface String() string } // Retriever periodically gets the cluster info from the / endpoint and // sends it to all registered consumer channels type Retriever struct { consumerChannels map[string]*chan *Response logger *slog.Logger client *http.Client url *url.URL interval time.Duration sync chan struct{} versionMetric *prometheus.GaugeVec up *prometheus.GaugeVec lastUpstreamSuccessTs *prometheus.GaugeVec lastUpstreamErrorTs *prometheus.GaugeVec } // New creates a new Retriever func New(logger *slog.Logger, client *http.Client, u *url.URL, interval time.Duration) *Retriever { return &Retriever{ consumerChannels: make(map[string]*chan *Response), logger: logger, client: client, url: u, interval: interval, sync: make(chan struct{}, 1), versionMetric: prometheus.NewGaugeVec( prometheus.GaugeOpts{ Name: prometheus.BuildFQName(namespace, subsystem, "version_info"), Help: "Constant metric with ES version information as labels", }, []string{ "cluster", "cluster_uuid", "build_date", "build_hash", "version", "lucene_version", }, ), up: prometheus.NewGaugeVec( prometheus.GaugeOpts{ Name: prometheus.BuildFQName(namespace, subsystem, "up"), Help: "Up metric for the cluster info collector", }, []string{"url"}, ), lastUpstreamSuccessTs: prometheus.NewGaugeVec( prometheus.GaugeOpts{ Name: prometheus.BuildFQName(namespace, subsystem, "last_retrieval_success_ts"), Help: "Timestamp of the last successful cluster info retrieval", }, []string{"url"}, ), lastUpstreamErrorTs: prometheus.NewGaugeVec( prometheus.GaugeOpts{ Name: prometheus.BuildFQName(namespace, subsystem, "last_retrieval_failure_ts"), Help: "Timestamp of the last failed cluster info retrieval", }, []string{"url"}, ), } } // Describe implements the prometheus.Collector interface func (r *Retriever) Describe(ch chan<- *prometheus.Desc) { r.versionMetric.Describe(ch) r.up.Describe(ch) r.lastUpstreamSuccessTs.Describe(ch) r.lastUpstreamErrorTs.Describe(ch) } // Collect implements the prometheus.Collector interface func (r *Retriever) Collect(ch chan<- prometheus.Metric) { r.versionMetric.Collect(ch) r.up.Collect(ch) r.lastUpstreamSuccessTs.Collect(ch) r.lastUpstreamErrorTs.Collect(ch) } func (r *Retriever) updateMetrics(res *Response) { u := *r.url u.User = nil url := u.String() r.logger.Debug("updating cluster info metrics") // scrape failed, response is nil if res == nil { r.up.WithLabelValues(url).Set(0.0) r.lastUpstreamErrorTs.WithLabelValues(url).Set(float64(time.Now().Unix())) return } r.up.WithLabelValues(url).Set(1.0) r.versionMetric.WithLabelValues( res.ClusterName, res.ClusterUUID, res.Version.BuildDate, res.Version.BuildHash, res.Version.Number.String(), res.Version.LuceneVersion.String(), ).Set(1.0) r.lastUpstreamSuccessTs.WithLabelValues(url).Set(float64(time.Now().Unix())) } // Update triggers an external cluster info label update func (r *Retriever) Update() { r.sync <- struct{}{} } // RegisterConsumer registers a consumer for cluster info updates func (r *Retriever) RegisterConsumer(c consumer) error { if _, registered := r.consumerChannels[c.String()]; registered { return ErrConsumerAlreadyRegistered } r.consumerChannels[c.String()] = c.ClusterLabelUpdates() return nil } // Run starts the update loop and periodically queries the / endpoint // The update loop is terminated upon ctx cancellation. The call blocks until the first // call to the cluster info endpoint was successful func (r *Retriever) Run(ctx context.Context) error { startupComplete := make(chan struct{}) // start update routine go func(ctx context.Context) { for { select { case <-ctx.Done(): r.logger.Info( "context cancelled, exiting cluster info update loop", "err", ctx.Err(), ) return case <-r.sync: r.logger.Info("providing consumers with updated cluster info label") res, err := r.fetchAndDecodeClusterInfo() if err != nil { r.logger.Error( "failed to retrieve cluster info from ES", "err", err, ) r.updateMetrics(nil) continue } r.updateMetrics(res) for name, consumerCh := range r.consumerChannels { r.logger.Debug( "sending update", "consumer", name, "res", fmt.Sprintf("%+v", res), ) *consumerCh <- res } // close startupComplete if not already closed select { case <-startupComplete: default: close(startupComplete) } } } }(ctx) // trigger initial cluster info call r.logger.Info("triggering initial cluster info call") r.sync <- struct{}{} // start a ticker routine go func(ctx context.Context) { if r.interval <= 0 { r.logger.Info("no periodic cluster info label update requested") return } ticker := time.NewTicker(r.interval) defer ticker.Stop() for { select { case <-ctx.Done(): r.logger.Info( "context cancelled, exiting cluster info trigger loop", "err", ctx.Err(), ) return case <-ticker.C: r.logger.Debug("triggering periodic update") r.sync <- struct{}{} } } }(ctx) // block until the first retrieval was successful select { case <-startupComplete: // first sync has been successful r.logger.Debug("initial clusterinfo sync succeeded") return nil case <-time.After(initialTimeout): // initial call timed out return ErrInitialCallTimeout case <-ctx.Done(): // context cancelled return nil } } func (r *Retriever) fetchAndDecodeClusterInfo() (*Response, error) { var response *Response u := *r.url u.Path = path.Join(r.url.Path, "/") res, err := r.client.Get(u.String()) if err != nil { r.logger.Error( "failed to get cluster info", "err", err, ) return nil, err } defer func() { err = res.Body.Close() if err != nil { r.logger.Warn( "failed to close http.Client", "err", err, ) } }() if res.StatusCode != http.StatusOK { return nil, fmt.Errorf("HTTP Request failed with code %d", res.StatusCode) } bts, err := io.ReadAll(res.Body) if err != nil { return nil, err } if err := json.Unmarshal(bts, &response); err != nil { return nil, err } return response, nil } prometheus-elasticsearch-exporter-1.10.0/pkg/clusterinfo/clusterinfo_response.go000066400000000000000000000024611511562765300304000ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package clusterinfo import ( "github.com/blang/semver/v4" ) // Response is the cluster info retrievable from the / endpoint type Response struct { Name string `json:"name"` ClusterName string `json:"cluster_name"` ClusterUUID string `json:"cluster_uuid"` Version VersionInfo `json:"version"` Tagline string `json:"tagline"` } // VersionInfo is the version info retrievable from the / endpoint, embedded in Response type VersionInfo struct { Number semver.Version `json:"number"` BuildHash string `json:"build_hash"` BuildDate string `json:"build_date"` BuildSnapshot bool `json:"build_snapshot"` LuceneVersion semver.Version `json:"lucene_version"` } prometheus-elasticsearch-exporter-1.10.0/pkg/clusterinfo/clusterinfo_test.go000066400000000000000000000121721511562765300275210ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package clusterinfo import ( "context" "fmt" "net/http" "net/http/httptest" "net/url" "os" "reflect" "sync" "testing" "time" "github.com/blang/semver/v4" "github.com/prometheus/common/promslog" ) const ( nodeName = "test-node-" clusterName = "test-cluster-1" clusterUUID = "r1bT9sBrR7S9-CamE41Qqg" versionNumber = "5.6.9" buildHash = "877a590" buildDate = "2018-04-12T16:25:14.838Z" buildSnapshot = false luceneVersion = "6.6.1" tagline = "You Know, for Search" ) type mockES struct{} func (mockES) ServeHTTP(w http.ResponseWriter, _ *http.Request) { fmt.Fprintf(w, `{ "name" : "%s", "cluster_name" : "%s", "cluster_uuid" : "%s", "version" : { "number" : "%s", "build_hash" : "%s", "build_date" : "%s", "build_snapshot" : %t, "lucene_version" : "%s" }, "tagline" : "%s" }`, nodeName, clusterName, clusterUUID, versionNumber, buildHash, buildDate, buildSnapshot, luceneVersion, tagline, ) } type mockConsumer struct { name string mu sync.RWMutex data *Response ch chan *Response } func newMockConsumer(ctx context.Context, name string, t *testing.T) *mockConsumer { mc := &mockConsumer{ name: name, ch: make(chan *Response), } go func() { for { select { case d := <-mc.ch: mc.mu.Lock() mc.data = d t.Logf("consumer %s received data from channel: %+v\n", mc, mc.data) mc.mu.Unlock() case <-ctx.Done(): return } } }() return mc } func (mc *mockConsumer) getData() Response { mc.mu.RLock() defer mc.mu.RUnlock() return *mc.data } func (mc *mockConsumer) String() string { return mc.name } func (mc *mockConsumer) ClusterLabelUpdates() *chan *Response { return &mc.ch } func TestNew(t *testing.T) { u, err := url.Parse("http://localhost:9200") if err != nil { t.Skipf("internal test error: %s", err) } r := New(promslog.NewNopLogger(), http.DefaultClient, u, 0) if r.url != u { t.Errorf("new Retriever mal-constructed") } } func TestRetriever_RegisterConsumer(t *testing.T) { mockES := httptest.NewServer(mockES{}) u, err := url.Parse(mockES.URL) if err != nil { t.Fatalf("internal test error: %s", err) } retriever := New(promslog.NewNopLogger(), mockES.Client(), u, 0) ctx, cancel := context.WithCancel(context.Background()) defer cancel() consumerNames := []string{"consumer-1", "consumer-2"} for _, n := range consumerNames { c := newMockConsumer(ctx, n, t) if err := retriever.RegisterConsumer(c); err != nil { t.Errorf("failed to register consumer: %s", err) } } if len(retriever.consumerChannels) != len(consumerNames) { t.Error("number of registered consumerChannels doesn't match the number of calls to the register func") } } func TestRetriever_fetchAndDecodeClusterInfo(t *testing.T) { // these override test package globals versionNumber, _ := semver.Make(versionNumber) luceneVersion, _ := semver.Make(luceneVersion) expected := &Response{ Name: nodeName, ClusterName: clusterName, ClusterUUID: clusterUUID, Version: VersionInfo{ Number: versionNumber, BuildHash: buildHash, BuildDate: buildDate, BuildSnapshot: buildSnapshot, LuceneVersion: luceneVersion, }, Tagline: tagline, } mockES := httptest.NewServer(mockES{}) u, err := url.Parse(mockES.URL) if err != nil { t.Skipf("internal test error: %s", err) } retriever := New(promslog.NewNopLogger(), mockES.Client(), u, 0) ci, err := retriever.fetchAndDecodeClusterInfo() if err != nil { t.Fatalf("failed to retrieve cluster info: %s", err) } if !reflect.DeepEqual(ci, expected) { t.Errorf("unexpected response, want %v, got %v", expected, ci) } } func TestRetriever_Run(t *testing.T) { // setup mock ES mockES := httptest.NewServer(mockES{}) u, err := url.Parse(mockES.URL) if err != nil { t.Fatalf("internal test error: %s", err) } // setup cluster info retriever retriever := New(promslog.New(&promslog.Config{Writer: os.Stdout}), mockES.Client(), u, 0) // setup mock consumer ctx, cancel := context.WithTimeout(context.Background(), 2*time.Second) defer cancel() mc := newMockConsumer(ctx, "test-consumer", t) if err := retriever.RegisterConsumer(mc); err != nil { t.Fatalf("failed to register consumer: %s", err) } // start retriever retriever.Run(ctx) // trigger update retriever.Update() time.Sleep(20 * time.Millisecond) // ToDo: check mockConsumers received data t.Logf("%+v\n", mc.getData()) // check for deadlocks select { case <-ctx.Done(): if err := ctx.Err(); err == context.DeadlineExceeded { t.Fatal("context timeout exceeded, caught deadlock") } default: } } prometheus-elasticsearch-exporter-1.10.0/pkg/roundtripper/000077500000000000000000000000001511562765300237735ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/pkg/roundtripper/roundtripper.go000066400000000000000000000062221511562765300270610ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package roundtripper import ( "bytes" "context" "crypto/sha256" "encoding/hex" "io" "log/slog" "net/http" "time" "github.com/aws/aws-sdk-go-v2/aws" v4 "github.com/aws/aws-sdk-go-v2/aws/signer/v4" "github.com/aws/aws-sdk-go-v2/config" "github.com/aws/aws-sdk-go-v2/credentials/stscreds" "github.com/aws/aws-sdk-go-v2/service/sts" ) const ( service = "es" ) type AWSSigningTransport struct { t http.RoundTripper creds aws.CredentialsProvider region string log *slog.Logger } func NewAWSSigningTransport(transport http.RoundTripper, region string, roleArn string, log *slog.Logger) (*AWSSigningTransport, error) { // Only set region explicitly when provided; otherwise allow env/IMDS resolution var opts []func(*config.LoadOptions) error if region != "" { opts = append(opts, config.WithRegion(region)) } cfg, err := config.LoadDefaultConfig(context.Background(), opts...) if err != nil { log.Error("failed to load aws default config", "err", err) return nil, err } if roleArn != "" { cfg.Credentials = stscreds.NewAssumeRoleProvider(sts.NewFromConfig(cfg), roleArn) } creds := aws.NewCredentialsCache(cfg.Credentials) // Run a single fetch credentials operation to ensure that the credentials // are valid before returning the transport. _, err = cfg.Credentials.Retrieve(context.Background()) if err != nil { log.Error("failed to retrive aws credentials", "err", err) return nil, err } return &AWSSigningTransport{ t: transport, region: region, creds: creds, log: log, }, err } func (a *AWSSigningTransport) RoundTrip(req *http.Request) (*http.Response, error) { signer := v4.NewSigner() payloadHash, newReader, err := hashPayload(req.Body) if err != nil { a.log.Error("failed to hash request body", "err", err) return nil, err } req.Body = newReader creds, err := a.creds.Retrieve(context.Background()) if err != nil { a.log.Error("failed to retrieve aws credentials", "err", err) return nil, err } err = signer.SignHTTP(context.Background(), creds, req, payloadHash, service, a.region, time.Now()) if err != nil { a.log.Error("failed to sign request body", "err", err) return nil, err } return a.t.RoundTrip(req) } func hashPayload(r io.ReadCloser) (string, io.ReadCloser, error) { var newReader io.ReadCloser payload := []byte("") if r != nil { defer r.Close() payload, err := io.ReadAll(r) if err != nil { return "", newReader, err } newReader = io.NopCloser(bytes.NewReader(payload)) } hash := sha256.Sum256(payload) payloadHash := hex.EncodeToString(hash[:]) return payloadHash, newReader, nil } prometheus-elasticsearch-exporter-1.10.0/probe.go000066400000000000000000000045011511562765300221130ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package main import ( "errors" "net/url" "strings" "github.com/prometheus-community/elasticsearch_exporter/config" ) var ( errMissingTarget = errors.New("missing target parameter") errInvalidTarget = errors.New("invalid target parameter") errModuleNotFound = errors.New("auth_module not found") errUnsupportedModule = errors.New("unsupported auth_module type") ) // validateProbeParams performs upfront validation of the query parameters. // It returns the target string (as given), the resolved AuthModule (optional), or an error. func validateProbeParams(cfg *config.Config, q url.Values) (string, *config.AuthModule, error) { target := q.Get("target") if target == "" { return "", nil, errMissingTarget } // If the target does not contain an URL scheme, default to http. // This allows users to pass "host:port" without the "http://" prefix. if !strings.Contains(target, "://") { target = "http://" + target } u, err := url.Parse(target) if err != nil { return "", nil, errInvalidTarget } if u.Scheme != "http" && u.Scheme != "https" { return "", nil, errInvalidTarget } modu := q.Get("auth_module") if modu == "" { return target, nil, nil // no auth module requested } if cfg == nil { return "", nil, errModuleNotFound } am, ok := cfg.AuthModules[modu] if !ok { return "", nil, errModuleNotFound } switch strings.ToLower(am.Type) { case "userpass": return target, &am, nil case "apikey": return target, &am, nil case "aws": // Accept module even if region omitted; environment resolver can provide it. return target, &am, nil case "tls": // TLS auth type is valid; detailed TLS validation is performed during config load. return target, &am, nil default: return "", nil, errUnsupportedModule } } prometheus-elasticsearch-exporter-1.10.0/probe_test.go000066400000000000000000000075711511562765300231640ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package main import ( "net/url" "testing" "github.com/prometheus-community/elasticsearch_exporter/config" ) func TestValidateProbeParams(t *testing.T) { cfg := &config.Config{AuthModules: map[string]config.AuthModule{}} // missing target _, _, err := validateProbeParams(cfg, url.Values{}) if err != errMissingTarget { t.Fatalf("expected missing target error, got %v", err) } // invalid target vals := url.Values{} vals.Set("target", "http://[::1") _, _, err = validateProbeParams(cfg, vals) if err == nil { t.Fatalf("expected invalid target error") } // invalid scheme vals = url.Values{} vals.Set("target", "ftp://example.com") _, _, err = validateProbeParams(cfg, vals) if err == nil { t.Fatalf("expected invalid target error for unsupported scheme") } // unknown module vals = url.Values{} vals.Set("target", "http://localhost:9200") vals.Set("auth_module", "foo") _, _, err = validateProbeParams(cfg, vals) if err != errModuleNotFound { t.Fatalf("expected module not found error, got %v", err) } // good path (userpass) cfg.AuthModules["foo"] = config.AuthModule{Type: "userpass", UserPass: &config.UserPassConfig{Username: "u", Password: "p"}} vals = url.Values{} vals.Set("target", "http://localhost:9200") vals.Set("auth_module", "foo") tgt, am, err := validateProbeParams(cfg, vals) if err != nil || am == nil || tgt == "" { t.Fatalf("expected success, got err=%v", err) } // good path (apikey) with both userpass and apikey set - apikey should be accepted cfg.AuthModules["api"] = config.AuthModule{ Type: "apikey", APIKey: "mysecret", UserPass: &config.UserPassConfig{Username: "u", Password: "p"}, } vals = url.Values{} vals.Set("target", "http://localhost:9200") vals.Set("auth_module", "api") _, am, err = validateProbeParams(cfg, vals) if err != nil { t.Fatalf("expected success for apikey module, got err=%v", err) } if am == nil || am.Type != "apikey" { t.Fatalf("expected apikey module, got %+v", am) } if am.APIKey != "mysecret" { t.Fatalf("unexpected apikey value: %s", am.APIKey) } // good path (aws) cfg.AuthModules["awsmod"] = config.AuthModule{ Type: "aws", AWS: &config.AWSConfig{ Region: "us-east-1", RoleARN: "arn:aws:iam::123456789012:role/metrics", }, } vals = url.Values{} vals.Set("target", "http://localhost:9200") vals.Set("auth_module", "awsmod") _, am, err = validateProbeParams(cfg, vals) if err != nil { t.Fatalf("expected success for aws module, got err=%v", err) } if am == nil || am.Type != "aws" { t.Fatalf("expected aws module, got %+v", am) } if am.AWS == nil || am.AWS.Region != "us-east-1" { t.Fatalf("unexpected aws config: %+v", am.AWS) } // invalid path (aws with empty region - rejected at config load; simulate here by passing nil cfg lookup) // No additional test needed as config.LoadConfig enforces region. // good path (tls) cfg.AuthModules["mtls"] = config.AuthModule{ Type: "tls", TLS: &config.TLSConfig{CAFile: "/dev/null", CertFile: "/dev/null", KeyFile: "/dev/null"}, } vals = url.Values{} vals.Set("target", "http://localhost:9200") vals.Set("auth_module", "mtls") _, am, err = validateProbeParams(cfg, vals) if err != nil { t.Fatalf("expected success for tls module, got err=%v", err) } if am == nil || am.Type != "tls" { t.Fatalf("expected tls module, got %+v", am) } } prometheus-elasticsearch-exporter-1.10.0/scripts/000077500000000000000000000000001511562765300221445ustar00rootroot00000000000000prometheus-elasticsearch-exporter-1.10.0/scripts/compile-mixin.sh000077500000000000000000000005611511562765300252570ustar00rootroot00000000000000#!/bin/bash MIXIN_PATH=./elasticsearch-mixin MIXIN_OUT_PATH=./elasticsearch-mixin/compiled rm -rf ${MIXIN_OUT_PATH} && mkdir ${MIXIN_OUT_PATH} pushd ${MIXIN_PATH} && jb install && popd mixtool generate all --output-alerts ${MIXIN_OUT_PATH}/alerts.yaml --output-rules ${MIXIN_OUT_PATH}/rules.yaml --directory ${MIXIN_OUT_PATH}/dashboards ${MIXIN_PATH}/mixin.libsonnet prometheus-elasticsearch-exporter-1.10.0/scripts/lint-jsonnet.sh000077500000000000000000000005141511562765300251270ustar00rootroot00000000000000#!/bin/bash # Run lint on all jsonnet files in the repository RESULT=0; for f in $(find . -name 'vendor' -prune -o -name '*.libsonnet' -print -o -name '*.jsonnet' -print); do # jsonnet fmt -i "$$f" echo "Linting ${f}" jsonnetfmt -- "${f}" | diff -u "${f}" - RESULT=$((RESULT+$?)) done echo "Linting complete" exit $RESULT prometheus-elasticsearch-exporter-1.10.0/tls.go000066400000000000000000000043111511562765300216050ustar00rootroot00000000000000// Copyright The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package main import ( "crypto/tls" "crypto/x509" "log" "os" ) func createTLSConfig(pemFile, pemCertFile, pemPrivateKeyFile string, insecureSkipVerify bool) *tls.Config { tlsConfig := tls.Config{} if insecureSkipVerify { // pem settings are irrelevant if we're skipping verification anyway tlsConfig.InsecureSkipVerify = true } if len(pemFile) > 0 { rootCerts, err := loadCertificatesFrom(pemFile) if err != nil { log.Fatalf("Couldn't load root certificate from %s. Got %s.", pemFile, err) return nil } tlsConfig.RootCAs = rootCerts } if len(pemCertFile) > 0 && len(pemPrivateKeyFile) > 0 { // Load files once to catch configuration error early. _, err := loadPrivateKeyFrom(pemCertFile, pemPrivateKeyFile) if err != nil { log.Fatalf("Couldn't setup client authentication. Got %s.", err) return nil } // Define a function to load certificate and key lazily at TLS handshake to // ensure that the latest files are used in case they have been rotated. tlsConfig.GetClientCertificate = func(*tls.CertificateRequestInfo) (*tls.Certificate, error) { return loadPrivateKeyFrom(pemCertFile, pemPrivateKeyFile) } } return &tlsConfig } func loadCertificatesFrom(pemFile string) (*x509.CertPool, error) { caCert, err := os.ReadFile(pemFile) if err != nil { return nil, err } certificates := x509.NewCertPool() certificates.AppendCertsFromPEM(caCert) return certificates, nil } func loadPrivateKeyFrom(pemCertFile, pemPrivateKeyFile string) (*tls.Certificate, error) { privateKey, err := tls.LoadX509KeyPair(pemCertFile, pemPrivateKeyFile) if err != nil { return nil, err } return &privateKey, nil }