Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Implement end-to-end ruler test for AlertManager HTTP Client. #4056

Closed
idoqo opened this issue Apr 14, 2021 · 4 comments
Closed

Implement end-to-end ruler test for AlertManager HTTP Client. #4056

idoqo opened this issue Apr 14, 2021 · 4 comments
Labels

Comments

@idoqo
Copy link
Contributor

idoqo commented Apr 14, 2021

We need to test that Thanos Ruler is able to send alerts to AlertManager(AM) in different setups such as:

  • Plain HTTP
  • HTTPS with custom CA
  • API with a prefix
  • API protected by a bearer token authentication.

Because AlertManager supports HTTP only and no authentication, we had to initially use a mocked AM server instead of a “real” one:

func TestRule_AlertmanagerHTTPClient(t *testing.T) {

That didn’t work though, because having docker containers reach out to services running on the host would be hacky.

It will make sense to have a test implementation that will cater to those different setups, without the downsides of the initial implementation.

Possible solutions include putting the mocked server in a container, or putting AlertManager and a proxy in a container so services can reach them.

idoqo added a commit to idoqo/thanos that referenced this issue Apr 14, 2021
E2E tests for ruler are currently marked as skip. This re-enables the test until it breaks again
and we are able to catch the flakiness.

Also, it removes the test for AlertManager HTTP client pending when we can improve on implementation
(see thanos-io#4056).

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>
idoqo added a commit to idoqo/thanos that referenced this issue May 27, 2021
E2E tests for ruler are currently marked as skip. This re-enables the test until it breaks again
and we are able to catch the flakiness.

Also, it removes the test for AlertManager HTTP client pending when we can improve on implementation
(see thanos-io#4056).

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>
idoqo added a commit to idoqo/thanos that referenced this issue May 31, 2021
E2E tests for ruler are currently marked as skip. This re-enables the test until it breaks again
and we are able to catch the flakiness.

Also, it removes the test for AlertManager HTTP client pending when we can improve on implementation
(see thanos-io#4056).

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>
idoqo added a commit to idoqo/thanos that referenced this issue Jun 8, 2021
E2E tests for ruler are currently marked as skip. This re-enables the test until it breaks again
and we are able to catch the flakiness.

Also, it removes the test for AlertManager HTTP client pending when we can improve on implementation
(see thanos-io#4056).

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>
yeya24 pushed a commit that referenced this issue Jun 9, 2021
* Re-enable e2e test for ruler

E2E tests for ruler are currently marked as skip. This re-enables the test until it breaks again
and we are able to catch the flakiness.

Also, it removes the test for AlertManager HTTP client pending when we can improve on implementation
(see #4056).

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>

* Bump rule group intervals and AM timeout

Signed-off-by: Michael Okoko <okokomichaels@outlook.com>
@stale
Copy link

stale bot commented Jun 16, 2021

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jun 16, 2021
@idoqo
Copy link
Contributor Author

idoqo commented Jun 16, 2021

Still valid.

@stale stale bot removed the stale label Jun 16, 2021
@stale
Copy link

stale bot commented Aug 17, 2021

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Aug 17, 2021
@stale
Copy link

stale bot commented Sep 3, 2021

Closing for now as promised, let us know if you need this to be reopened! 🤗

@stale stale bot closed this as completed Sep 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant