Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

feat(otel): log notice to STDOUT when using OTel #1215

Merged
merged 4 commits into from
Jan 3, 2024

Conversation

10xLaCroixDrinker
Copy link
Member

Description

Rather than simply leaving an empty console on startup when using OTel, send a single message informing the user that startup was successful and that logs are going to OTel.

Motivation and Context

DX improvement

How Has This Been Tested?

Unit tests and running locally validating that log is present

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation (adding or updating documentation)
  • Dependency update
  • Security update

Checklist:

  • My change requires a change to the documentation and I have updated the documentation accordingly.
  • These changes should be applied to a maintenance branch.
  • This change requires cross browser checks.
  • Performance tests should be ran against the server prior to merging.
  • This change impacts caching for client browsers.
  • This change impacts HTTP headers.
  • This change adds additional environment variable requirements for One App users.
  • I have added the Apache 2.0 license header to any new files created.

What is the Impact to Developers Using One App?

More clear what's happening with the logs from the application console when using OTel for logging

Copy link
Contributor

github-actions bot commented Dec 21, 2023

Size Change: 0 B

Total Size: 712 kB

ℹ️ View Unchanged
Filename Size
./build/app/app.js 164 kB
./build/app/app~vendors.js 411 kB
./build/app/runtime.js 7.07 kB
./build/app/service-worker-client.js 7.25 kB
./build/app/vendors.js 123 kB

compressed-size-action

JAdshead
JAdshead previously approved these changes Dec 21, 2023
@JAdshead JAdshead requested a review from a team December 21, 2023 19:41
smackfu
smackfu previously approved these changes Dec 21, 2023
@10xLaCroixDrinker
Copy link
Member Author

Need to add another log for error scenario, failure to start

giulianok
giulianok previously approved these changes Dec 22, 2023
Copy link
Member

@giulianok giulianok left a comment

Choose a reason for hiding this comment

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

lgtm

@10xLaCroixDrinker
Copy link
Member Author

Need to add another log for error scenario, failure to start

done in eb166b0

Matthew-Mallimo
Matthew-Mallimo previously approved these changes Jan 2, 2024
Comment on lines 48 to 53
// setGlobalErrorHandler((err) => {
// process.stderr.write('OTel Error one-app: ');
// process.stderr.write(err);
// loggingErrorHandler(err);
// process.exit(1);
// });
Copy link
Member

Choose a reason for hiding this comment

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

Can we remove this instead of leaving it commented

Copy link
Member Author

Choose a reason for hiding this comment

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

Dang, committed this on accident 🤦🏻

@10xLaCroixDrinker 10xLaCroixDrinker merged commit b4bcf21 into main Jan 3, 2024
9 checks passed
@10xLaCroixDrinker 10xLaCroixDrinker deleted the feature/otel-notice branch January 3, 2024 15:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants