-
Notifications
You must be signed in to change notification settings - Fork 62
OTLP telemetry exporter #213
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
Merged
Merged
Changes from 12 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
2bad215
fix bug in initializing logger
maxdml 88d5168
Type contextual metadata and format them more nicely + remove overkil…
maxdml c8f6250
first jab at OTLP transport
maxdml c717e49
Augment the Winston wrapper and expose it to the rest of the system
maxdml 026ef11
first jab at implementing the OTLP exporter
maxdml a89c82e
fix creation of OTLP log records and simplify config
maxdml c2606a3
dabble with active context
maxdml 0f16f42
lint
maxdml 811af49
always add the console transport
maxdml aa5482f
update unit tests
maxdml d17e5fe
need to use exactly 0.41.2
maxdml bb1ffae
update package-lock.json
maxdml 9c01f53
lint
maxdml 05cc512
strengthen typing
maxdml ecb03dc
lint
maxdml a0016fa
add a comment
maxdml e3ce5d9
remove obsolete comment
maxdml 8b47554
correctly log errors
maxdml afc5915
allow people to pass objects to the logger methods
maxdml 0f65fae
do not gobble error objects
maxdml 97ad516
ensure non error, non string error() inputs from context loggers get …
maxdml 1affc05
only support 1 exporter
maxdml 0fe544b
Merge branch 'main' into otlp-telemetry-exporter
maxdml a20cc09
remove commented tests + update comment
maxdml File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| import { Span } from "@opentelemetry/sdk-trace-base"; | ||
| import { WinstonLogger as Logger, Logger as DBOSLogger } from "./telemetry/logs"; | ||
| import { GlobalLogger as Logger, Logger as DBOSLogger } from "./telemetry/logs"; | ||
| import { has, get } from "lodash"; | ||
| import { IncomingHttpHeaders } from "http"; | ||
| import { ParsedUrlQuery } from "querystring"; | ||
|
|
@@ -44,14 +44,14 @@ export class DBOSContextImpl implements DBOSContext { | |
| readonly logger: DBOSLogger; // Wrapper around the global logger for this context. | ||
|
|
||
| constructor(readonly operationName: string, readonly span: Span, logger: Logger, parentCtx?: DBOSContextImpl) { | ||
| this.logger = new DBOSLogger(logger, this); | ||
| if (parentCtx) { | ||
| this.request = parentCtx.request; | ||
| this.authenticatedUser = parentCtx.authenticatedUser; | ||
| this.authenticatedRoles = parentCtx.authenticatedRoles; | ||
| this.assumedRole = parentCtx.assumedRole; | ||
| this.workflowUUID = parentCtx.workflowUUID; | ||
| } | ||
| this.logger = new DBOSLogger(logger, this); | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This fix a bug where the metadata would be missing if provided from the |
||
| } | ||
|
|
||
| /*** Application configuration ***/ | ||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.