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

otel_log_level (common debug) proposal #139

Closed
wants to merge 1 commit into from
Closed

Conversation

ghost
Copy link

@ghost ghost commented Oct 20, 2021

No description provided.

@ghost ghost requested review from a team as code owners October 20, 2021 12:40
Copy link
Contributor

@pellared pellared left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that this PR would only add noise as I think that it is obvious that if something is defined in OTel spec then we should support it.

The only addition is that the spec only mentions info and here we are having INFO, DEBUG, TRACE. Maybe we should rather make a PR to the OTel spec with value proposals.

@pellared
Copy link
Contributor

@MrAlias Already created an issue: open-telemetry/opentelemetry-specification#2039

@ghost
Copy link
Author

ghost commented Oct 21, 2021

I think that this PR would only add noise as I think that it is obvious that if something is defined in OTel spec then we should support it.

The only addition is that the spec only mentions info and here we are having INFO, DEBUG, TRACE. Maybe we should rather make a PR to the OTel spec with value proposals.

It is obvious, but for non-OTel (yes, we have non-OTel components) it is not. Hence this PR.

@pellared
Copy link
Contributor

pellared commented Oct 21, 2021

If the component is non-OTel then maybe we should name it SPLUNK_LOG_LEVEL? Maybe even SPLUNK_LAMBDA_LOG_LEVEL if it is tightly coupled to some component and it will be hard to support the OTel recommended values? But I guess you can always make some "translation" logic.

Moreover, it would help the reviewers if you elaborate on why this change is needed.

@@ -135,7 +135,11 @@ beyond the OpenTelemetry specification exist.
- `OTEL_TRACES_EXPORTER`
- Non-RUM distribution MUST default to `otlp` over gRPC with an endpoint of `localhost:4317`
- Non-RUM distribution MUST offer `jaeger-thrift-splunk` that defaults to `http://127.0.0.1:9080/v1/trace`

- `OTEL_LOG_LEVEL`
- Distribution SHOULD support `DEBUG` setting. With this value all relevant troubleshooting data should be logged.
Copy link
Contributor

@pellared pellared Oct 21, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK supporting this would involve hacking in most of the SDKs. I would rather make a hack to convert debug to DEBUG if a component needs it as it seems more OTel compliant.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, we need to wait for the values to be finalized in the spec. Then it will be a no-brainer ;)

@ghost
Copy link
Author

ghost commented Oct 21, 2021

If the component is non-OTel then maybe we should name it SPLUNK_LOG_LEVEL? Maybe even SPLUNK_LAMBDA_LOG_LEVEL if it is tightly coupled to some component and it will be hard to support the OTel recommended values? But I guess you can always make some "translation" logic.

Moreover, it would help the reviewers if you elaborate on why this change is needed.

This was my idea. But @flands believes that it will be better to support "OTEL" debug var in other (non-OTel) libs.

Comment on lines +140 to +142
- Distribution MAY support additional levels:
- `INFO` - coarser-grained informational events than the `DEBUG`.
- `TRACE` - finer-grained informational events than the `DEBUG`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're going to use OTEL_LOG_LEVEL (which is a good idea, since it's stable in the otel spec) I believe we should wait for the OTel spec issues to get resolved before deciding on anything here.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want to introduce log levels here that'll end up not being included in the otel spec...

@rauno56
Copy link

rauno56 commented Oct 21, 2021

It is obvious, but for non-OTel (yes, we have non-OTel components) it is not. Hence this PR.

I wasn't aware of that - What kind of non-OTel components are we expecting(or are already) to follow the GDI spec?

@ghost
Copy link
Author

ghost commented Nov 3, 2021

It is obvious, but for non-OTel (yes, we have non-OTel components) it is not. Hence this PR.

I wasn't aware of that - What kind of non-OTel components are we expecting(or are already) to follow the GDI spec?

Currently - the metrics extension (based on SFx metrics) which is bundled with the Splunk OTel Lambda Layer. It has currently different config for logging which IMO is confusing for end-users. Hence this request.

@ghost ghost closed this Jan 5, 2022
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants