Skip to content

fix: change receiver model pointer to value#3338

Merged
gotjosh merged 2 commits intoprometheus:mainfrom
fgouteroux:fix-api-v2-receivers
Apr 28, 2023
Merged

fix: change receiver model pointer to value#3338
gotjosh merged 2 commits intoprometheus:mainfrom
fgouteroux:fix-api-v2-receivers

Conversation

@fgouteroux
Copy link
Contributor

Hello,

There is a bug when calling /api/v2/receivers, it return the same receiver name multiple times.

Expected:

curl http://localhost:9093/api/v2/receivers
[{"name":"web.hook"},{"name":"web.hook2"}]

Got:

$ curl http://localhost:9093/api/v2/receivers
[{"name":"web.hook2"},{"name":"web.hook2"}]

I think it was related to this change #3209.

@fgouteroux fgouteroux force-pushed the fix-api-v2-receivers branch 3 times, most recently from 9e28e3d to d14eb77 Compare April 25, 2023 10:13
Copy link
Member

@gotjosh gotjosh left a comment

Choose a reason for hiding this comment

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

Thanks! Please see my comment.

@gotjosh gotjosh added the waiting-for-user-input The Pull Request or Issue is waiting for input from the user that reported it or created it. label Apr 28, 2023
@fgouteroux fgouteroux force-pushed the fix-api-v2-receivers branch 2 times, most recently from e739162 to 59fcf78 Compare April 28, 2023 13:39
Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
@fgouteroux fgouteroux force-pushed the fix-api-v2-receivers branch from 59fcf78 to 775e94a Compare April 28, 2023 13:41
@fgouteroux fgouteroux requested a review from gotjosh April 28, 2023 13:49
Copy link
Member

@gotjosh gotjosh left a comment

Choose a reason for hiding this comment

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

LGTM

I just have one small nit, can you please address it really quickly? 😄

Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
@gotjosh
Copy link
Member

gotjosh commented Apr 28, 2023

Thank you very much for your contribution!

@gotjosh gotjosh merged commit 29ed858 into prometheus:main Apr 28, 2023
@fgouteroux
Copy link
Contributor Author

Thanks for your review ! Happy to make my 1rst contribution !

gotjosh pushed a commit that referenced this pull request Aug 7, 2023
* fix: change receiver pointer to value and add test

Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
---------

Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
radek-ryckowski pushed a commit to goldmansachs/alertmanager that referenced this pull request Nov 6, 2023
* fix: change receiver pointer to value and add test

Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
---------

Signed-off-by: François Gouteroux <francois.gouteroux@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

waiting-for-user-input The Pull Request or Issue is waiting for input from the user that reported it or created it.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants