-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[v2] Configure health check extension for all configs #5861
Conversation
Signed-off-by: Wise-Wizard <[email protected]>
Hi, so the health check configuration should be added to every config file individually itself right? |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5861 +/- ##
=======================================
Coverage 96.79% 96.79%
=======================================
Files 342 342
Lines 16525 16525
=======================================
Hits 15996 15996
Misses 341 341
Partials 188 188
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Yes. And you need your mention it in the service section. |
Signed-off-by: Wise-Wizard <[email protected]>
See #5859 |
Step 1 is done, I will proceed with e2e tests now. |
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
… into V2/Health_Check
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
error in the logs
|
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
Signed-off-by: Wise-Wizard <[email protected]>
While the test is running you can query it for traces with jaeger service name to see which endpoint is causing it to appear. It's possible that it comes from the health extension, although it would be strange since we did not enable global tracer, only jtracer for our parts. |
Hi @yurishkuro, So I ran the gRPC integration test locally and the logs are perfect and no error is being reported in the test. |
Signed-off-by: Yuri Shkuro <[email protected]>
I added logging of the traces corresponding to the service names that are retrieved, and turns out the "offending" service name "jaeger" is coming from traces on the write path
This is actually (a) a great find, and (b) a problem, because we should never be tracing the write path due to the risk of infinite self-trace loop. |
what is weird is why this doesn't seem to happen when running the test locally... |
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Yes exactly, I had added the same logs in order to debug it, but surprisingly locally all the tests were being passed. |
It's a timing issue. The traces used in the unit tests are directly written to the pipeline and quickly end up in the storage. But the extraneous traces from "jaeger" first go through SDK's batch exporter, which buffers spans for some time before flushing. In local tests those "jaeger" traces don't make it in time for the test traces to be detected. I was able to reproduce it locally with this diff: diff --git a/cmd/jaeger/internal/integration/e2e_integration.go b/cmd/jaeger/internal/integration/e2e_integration.go
index 55f1517f..c65ca281 100644
--- a/cmd/jaeger/internal/integration/e2e_integration.go
+++ b/cmd/jaeger/internal/integration/e2e_integration.go
@@ -184,6 +184,8 @@ func (s *E2EStorageIntegration) doHealthCheck(t *testing.T) bool {
t.Logf("Received non-K status %s: %s", healthResponse.Status, string(body))
return false
}
+ t.Logf("%s is ready, but let's sleep a bit", s.BinaryName)
+ time.Sleep(30*time.Second + 3*time.Second)
return true
}
diff --git a/cmd/jaeger/internal/integration/grpc_test.go b/cmd/jaeger/internal/integration/grpc_test.go
index 4f7c1cee..6cf0cddf 100644
--- a/cmd/jaeger/internal/integration/grpc_test.go
+++ b/cmd/jaeger/internal/integration/grpc_test.go
@@ -4,11 +4,9 @@
package integration
import (
- "fmt"
"testing"
"github.com/jaegertracing/jaeger/plugin/storage/integration"
- "github.com/jaegertracing/jaeger/ports"
)
type GRPCStorageIntegration struct {
@@ -33,7 +31,7 @@ func TestGRPCStorage(t *testing.T) {
E2EStorageIntegration: E2EStorageIntegration{
ConfigFile: "../../config-remote-storage.yaml",
// TODO this should be removed in favor of default health check endpoint
- HealthCheckEndpoint: fmt.Sprintf("http://localhost:%d/", ports.QueryHTTP),
},
}
s.CleanUp = s.cleanUp |
Ah, makes sense now. |
…5861) **Which problem is this PR solving?** Part of jaegertracing#5633, part of jaegertracing#5859 **Description of the changes** * Integrate health check extension to monitor and report Jaeger V2 component's health * Enhance all-in-one CI test to ping the new health port **How was this change tested?** The changes were tested by running the following command: ```bash make test ``` ```bash CI actions and new Unit Tests ``` **Checklist** - [x] I have read [CONTRIBUTING_GUIDELINES.md](https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md) - [x] I have signed all commits - [x] I have added unit tests for the new functionality - [x] I have run lint and test steps successfully - `for jaeger: make lint test` - `for jaeger-ui: yarn lint` and `yarn test` --------- Signed-off-by: Wise-Wizard <[email protected]> Signed-off-by: Yuri Shkuro <[email protected]> Co-authored-by: Yuri Shkuro <[email protected]> Co-authored-by: Yuri Shkuro <[email protected]> Signed-off-by: Jared Tan <[email protected]>
…5861) **Which problem is this PR solving?** Part of jaegertracing#5633, part of jaegertracing#5859 **Description of the changes** * Integrate health check extension to monitor and report Jaeger V2 component's health * Enhance all-in-one CI test to ping the new health port **How was this change tested?** The changes were tested by running the following command: ```bash make test ``` ```bash CI actions and new Unit Tests ``` **Checklist** - [x] I have read [CONTRIBUTING_GUIDELINES.md](https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md) - [x] I have signed all commits - [x] I have added unit tests for the new functionality - [x] I have run lint and test steps successfully - `for jaeger: make lint test` - `for jaeger-ui: yarn lint` and `yarn test` --------- Signed-off-by: Wise-Wizard <[email protected]> Signed-off-by: Yuri Shkuro <[email protected]> Co-authored-by: Yuri Shkuro <[email protected]> Co-authored-by: Yuri Shkuro <[email protected]> Signed-off-by: Mahad Zaryab <[email protected]>
Which problem is this PR solving?
Part of #5633, part of #5859
Description of the changes
How was this change tested?
The changes were tested by running the following command:
make test
Checklist
for jaeger: make lint test
for jaeger-ui: yarn lint
andyarn test