Otel Custom Receiver Error: error decoding 'receivers': unknown type: #9800
Unanswered
Umang01-hash
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am trying to make a custom receiver that will Collect and receive traces from applications and store it in MySQL database.(An alternative to zipkin). Later on will work on exporting them when asked.
So for my custom receiver this is the code I have written following the otel's official documentation
Link to code: https://github.com/Umang01-hash/traceCollectorService
Also after writing the receiver , I included it in
components.go
file insdideotelcol-dev
directory.Changes in compoentns.go
And my conifg.yaml looks like this:
When trying to run it using this command :
Getting the following error:
Error: failed to get config: cannot unmarshal the configuration: 1 error(s) decoding:
error decoding 'receivers': unknown type: "traceCollectorService" for id: "traceCollectorService" (valid values: [otlp])
2024/03/20 16:22:02 collector server run finished with error: failed to get config: cannot unmarshal the configuration: 1 error(s) decoding:
error decoding 'receivers': unknown type: "traceCollectorService" for id: "traceCollectorService" (valid values: [otlp])
Can someone please guide me on how to resolve it. I have checked there is proper consistency in naming of traceCollectorService. Also feel free to tell if anything is wrong in the receiver code. Thanyou in advance.
Beta Was this translation helpful? Give feedback.
All reactions