Skip to content

Conversation

sunwupark
Copy link
Contributor

Added listContactPoints function to fetch and paginate contact points from Grafana.
Supports filtering by name and returns summarized data (UID, Name, Type).
Tests included for pagination, filtering, and invalid parameters.

@sunwupark sunwupark requested a review from a team as a code owner April 5, 2025 10:56
@CLAassistant
Copy link

CLAassistant commented Apr 5, 2025

CLA assistant check
All committers have signed the CLA.

@sunwupark
Copy link
Contributor Author

image

Copy link
Contributor

@ioanarm ioanarm left a comment

Choose a reason for hiding this comment

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

Thanks so much for your contribution @sunwupark !
One small comment from my side! :)

@sunwupark sunwupark requested a review from ioanarm April 7, 2025 09:21
@sunwupark
Copy link
Contributor Author

I have also removed the page parameter from the alert test file.

return result
}

func applyContactPointPagination(items []*models.EmbeddedContactPoint, limit int) ([]*models.EmbeddedContactPoint, error) {
Copy link
Contributor

Choose a reason for hiding this comment

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

tiny last comment, can we change the name of this function now?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Would you be okay with renaming the function to applyLimitToContactPoints? I think it accurately reflects the current functionality.

@sunwupark sunwupark requested a review from ioanarm April 8, 2025 00:43
Copy link
Contributor

@ioanarm ioanarm left a comment

Choose a reason for hiding this comment

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

Just to clean it up!

@sunwupark sunwupark requested a review from ioanarm April 8, 2025 12:40
@sunwupark
Copy link
Contributor Author

yup! changed and commited

@ioanarm ioanarm merged commit 8558891 into grafana:main Apr 9, 2025
5 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.

3 participants