[CI App] - Agentless Writer#2402
Conversation
lucaspimentel
left a comment
There was a problem hiding this comment.
Left a few comments but nothing that should block this PR.
This comment has been minimized.
This comment has been minimized.
| return 1; | ||
| } | ||
| } | ||
| else if (!Utils.CheckAgentConnectionAsync(options.AgentUrl).GetAwaiter().GetResult()) |
There was a problem hiding this comment.
Do we want to/can we test the connection when using agentless mode? 🤔 May be a feature request for the backend, but would be useful to be able to check that a) connection is successful (presumably requires correct DD_SITE, haven't got that far yet) b) the API key is correct.
There was a problem hiding this comment.
That can be helpful, I have to check with the backend team. Maybe for another PR.
|
|
||
| // https://github.com/DataDog/datadog-agent/blob/eac2327c5574da7f225f9ef0f89eaeb05ed10382/pkg/trace/traceutil/truncate.go#L36-L51 | ||
| [MethodImpl(MethodImplOptions.AggressiveInlining)] | ||
| public static bool TruncateUTF8(ref string value, int limit) |
There was a problem hiding this comment.
How strict is the tag length limit? What happens is we go over the limit, does it get truncated in the intake anyway or does it get rejected?
Only partially related, but if we use this logic to calculate metrics in the tracer (as we need to), then I think we need to make sure we use exactly the same truncation, otherwise we could end up with strange discrepancies? Not entirely sure or thought through yet though 😅
| yield return new object[] { "#test_starting_hash", "test_starting_hash" }; | ||
| yield return new object[] { "TestCAPSandSuch", "testcapsandsuch" }; | ||
| yield return new object[] { "Test Conversion Of Weird !@#$%^&**() Characters", "test_conversion_of_weird_characters" }; |
There was a problem hiding this comment.
You've triggered a new build since then, so you can't see the code coverage until the new one completely, but I think it would be good to check the code coverage for the TraceUtil class and make sure you've covered all the branches, given there's a lot of complexity in there! 🙂
There was a problem hiding this comment.
I'll check, the tests are the same as the ones in the agent.
This comment has been minimized.
This comment has been minimized.
Co-authored-by: Andrew Lock <[email protected]>
Co-authored-by: Andrew Lock <[email protected]>
…et into tony/agentless-poc
Co-authored-by: Andrew Lock <[email protected]>
…et into tony/agentless-poc
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Benchmarks Report 🐌Benchmarks for #2402 compared to master:
The following thresholds were used for comparing the benchmark speeds:
Allocation changes below 0.5% are ignored. Benchmark detailsBenchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.AspNetCoreBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.DbCommandBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.ElasticsearchBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.GraphQLBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.HttpClientBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.ILoggerBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.Log4netBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.NLogBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.RedisBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.SerilogBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.SpanBenchmark - Same speed ✔️ Same allocations ✔️Raw results
|
Code Coverage Report 📊
View the full report for further details: Datadog.Trace Breakdown
|
| master | #2402 | Change | |
|---|---|---|---|
| Lines % | 73% |
70% |
-3% |
| Branches % | 67% |
65% |
-1% |
| Complexity | 10573 |
11016 |
443 ⛔ |
The following classes have significant coverage changes.
| File | Line coverage change | Branch coverage change | Complexity change |
|---|---|---|---|
| Datadog.Trace.Agent.StreamFactories.TcpStreamFactory | -90% ⛔ |
0% ✔️ |
0 ✔️ |
| Datadog.Trace.Ci.CITracerManagerFactory | -76% ⛔ |
-90% ⛔ |
11 ⛔ |
| Datadog.Trace.Ci.CITracerManager | -70% ⛔ |
-100% ⛔ |
11 ⛔ |
| Datadog.Trace.Ci.Agent.CIAgentWriter | -50% ⛔ |
-93% ⛔ |
-6 ✔️ |
| Datadog.Trace.Agent.Transports.ApiWebRequestFactory | -36% ⛔ |
-33% ⛔ |
5 ⛔ |
| Datadog.Trace.Agent.Transports.HttpClientRequestFactory | -36% ⛔ |
-33% ⛔ |
2 ⛔ |
| Datadog.Trace.Telemetry.JsonHttpClientTelemetryTransport | -26% ⛔ |
-38% ⛔ |
0 ✔️ |
| Datadog.Trace.Agent.TracesTransportStrategy | -15% ⛔ |
0% ✔️ |
0 ✔️ |
| Datadog.Trace.Agent.Transports.HttpStreamRequestFactory | -13% ⛔ |
0% ✔️ |
1 ⛔ |
| Datadog.Trace.ClrProfiler.AutoInstrumentation.MongoDb.MongoDbIntegration | -7% ⛔ |
0% ✔️ |
0 ✔️ |
| ...And 3 more |
The following classes were added in #2402:
| File | Line coverage | Branch coverage | Complexity |
|---|---|---|---|
| Datadog.Trace.Ci.Agent.CIAgentlessWriter | 0% |
0% |
40 |
| Datadog.Trace.Ci.Agent.CIWriterFileSender | 0% |
100% |
3 |
| Datadog.Trace.Ci.Agent.CIWriterHttpSender | 0% |
0% |
24 |
| Datadog.Trace.Ci.Agent.MessagePack.CIEventMessagePackFormatter | 0% |
0% |
20 |
| Datadog.Trace.Ci.Agent.MessagePack.CIFormatterResolver | 0% |
0% |
12 |
| ...And 17 more |
View the full reports for further details:
The PR is primarily focused on introducing the V1 of
Agentless test reportingon the .NET tracer as opt-in only when theCI Visibility modeisEnabled.For the reviewing process, there's an internal document about all changes made by the PR.
@DataDog/apm-dotnet