Skip to content

Conversation

@nickbazinet
Copy link
Contributor

Add support for scraping Redshift-Serverless metrics.

When I queried the /metrics endpoint, I was able to view the expected metrics:
image

This is my first PR on this project and I am not 100% sure about the ResourceFilters in services.go, but based on my understanding it seems proper.
Feedback is then appreciated :)

This was based on this config:

 jobs:
  - type: AWS/Redshift-Serverless
    regions: *regions
    roles: *masterArns
    enableMetricData: true
    metrics:
      - name: DatabaseConnections
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: ComputeCapacity
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: QueriesCompletedPerSecond
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: ComputeSeconds
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: QueriesFailed
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: QueriesQueued
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: QueriesRunning
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
      - name: QueriesSucceeded
        statistics:
          - Average
        period: 60
        length: 60
        nilToZero: true
    exportedTagsOnMetrics: *masterTags

ResourceFilters: []*string{
aws.String("redshift-serverless:namespace"),
},
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nickbazinet would you mind adding a test case in the maxdimassociator package?

@nickbazinet nickbazinet force-pushed the master branch 2 times, most recently from ce57a21 to a2ea539 Compare January 13, 2025 21:15
Signed-off-by: nickbazinet <nicolas.bazinet@hotmail.com>
@cristiangreco cristiangreco merged commit b95099a into prometheus-community:master Jan 14, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants