fix(exporter-logs-otlp-http): set useHex to true - #3875
Conversation
84c58eb to
616b93a
Compare
Hi ! I just have a look at other packages and i think no one test the "convert" method. Do you have some advice or asserts i should write ? thank you :D |
You export some log records and expect the output to be in correct otlp-http format. Please refer to tests of
You don't need to test the |
|
Thank you for you for your answer. I'm really sorry but i'm a bit confused by your comment.
Since i don't need to test As I understand, you ask me to test twice the |
I mean you should:
|
616b93a to
ae0c1a5
Compare
7bdf6ea to
eb5f9a8
Compare
|
Ok should be good now, in the end the issue was with |
eb5f9a8 to
e6926df
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #3875 +/- ##
==========================================
+ Coverage 92.89% 92.90% +0.01%
==========================================
Files 297 297
Lines 8838 8838
Branches 1815 1815
==========================================
+ Hits 8210 8211 +1
+ Misses 628 627 -1
|
pichlermarc
left a comment
There was a problem hiding this comment.
Hi, thanks for fixing this 🙂 Would you mind setting useHex to true in the browser exporter as well (src/platform/browser/OTLPLogExporter.ts)? This way we'll have this bug fixed for good 🙂
Done :D |
c670d2c to
f3a0b2f
Compare
pichlermarc
left a comment
There was a problem hiding this comment.
whoops, looks like a test is still failing 👀
a54144e to
ba446f1
Compare
ba446f1 to
6eb6be4
Compare
The browser tests seem to fail, you can run those with |
527e032 to
6600955
Compare
|
Facing same issue in our project, any news on this topic ? Thanks @Nico385412 |
|
@pichlermarc should be good :D |
97d5b12 to
02ccd83
Compare
|
Looks great, thanks for sticking with us on this one. 🙂 |
4d35e5b to
767244c
Compare
767244c to
6209f9a
Compare
|
Any idea when this fix will be available in a release? |
Planning to release |
|
Perfect, thank you! :) |
|
Any news on the 0.41.0 version this will be fixed in? I'm waiting on this one too and I'd like to see if there is anything I can do to help get it out there :-) |
|
coincidently we are awaiting this bug fix as well |


Which problem is this PR solving?
When we use the
OTLPLogExporterto send logs to a collector I face this issue:When I look at what the exporter send, traceId look like this
x+wKeY+LpUblmgFbiqXBwQ==which is base64. that a bug we should have an hex.When I look at
OTLPTraceExporteri notice it adds an extra parametertrueto this functioncreateExportLogsServiceRequestwhich disable the mapping to base64.This PR replicate this behavior to
OTLPLogExporterShort description of the changes
createExportLogsServiceRequestfunction used in OTLPLogExporter now have an extra parametertrueto use hex formatType of change
Please delete options that are not relevant.
How Has This Been Tested?
Has been tested in TDD and i had a single new test
should call createExportLogsServiceRequest with useHex parameter to trueChecklist: