Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Initialize OpenTelemetry SDK * Create OpenTelemetry root and middleware spans * Add exit handlers for otel * Set traceparent and tracestate on the active otel context * Add otel imports to prelude * Refactor grpc switching logic * Use isHoneycomb/isOtel everywhere, including prelude * Export beeline by default * Use OpenTelemetry semantic attributes * Move isHoneycomb/isOtel tests to prelude * Replace type guards with unsafe casts, yolo * Configure sampler * Switch from @opentelemetry/node to @opentelemetry/sdk-trace-node * Fix deprecation warning * Use individual node instrumentations * Change default port to 8000 * Update dependencies.ron, clean up unused dependency * Add @opentelemetry/api dependency * set up W3CTraceContextPropagator * Pretest hook to check typescript types * Simplify ts check script * Break otel functionality into unit-test-able functions * TODOs for instrumentation modules * Wrap honeycomb env var normalization in a function * Clean up tap setup in prelude * Remove a bunch of crufty instrumentations and respect postgres + redis feature flags * a bunch of otel unit tests * t.equals -> t.equal (the former is deprecated) * fix: Add v to version for error-produced urls The url structure is `/v${versionNumber}/`, so these errors produce 404s * whack-a-mole deprecated tap APIs * Don't import middleware/test in prelude tests * Resolve promise on error when closing parent span * Remove testing stubs from honeycomb middleware * Fix template bug * Fix syntax error in dependencies.ron * push honeycomb into core module * Move honeycomb core code out of prelude.ts * build succeeds! but beelines are broken in the middleware layer, womp womp * Don't try to open/close spans when honeycomb isn't even initialized * SMOKE TESTS PASSING * Remove otel functionality to create more manageable pull request * Remove otel deps * Test the honeycomb trace span name logic * boltzmann-cli npm package will now run x64 darwin build on arm * Start the trace *after* handling the ping route * Update middleware.ts to use honeycomb abstraction * Revert "Remove otel deps" This reverts commit 11fb7ef. * Revert "Remove otel functionality to create more manageable pull request" This reverts commit c2e98a2. * rename otlp to otel throughout * Remove search querystring from trace span names * Use HTTP_CLIENT_IP instead of NET_PEER_IP * Set span kind to SERVER * Clean up trace propagation code * Fix W3CTraceContextPropagator import * update core/middleware to use honeycomb facade API * Failing test for honeycomb/otel instrumentation * Respect doNotTrace and fill in test asserts * Attempt to plumb up contexts better * spruced up the test trace propagator * Extra log lines for honeycomb tracing (parent/child spans not connecting in beelines) * Refactor honeycomb mocking - tests should all use the same mock object now * Move span/trace up/down logic back into middleware * Traces are now connecting and have the correct service.name * ignore noisy http auto-instrumentation * WE HAVE INWARD PROPAGATION * rename otelAPI to otel (for convenience) * Minor cleanup/refactors * remove top-level trace span in non-test mode * Remove explicit trace context propagator (w3c works automatically) * Remove spans array and use closures instead * nudge span context property def to make js build happy * Fill in otel trace URL params * Use bole for logging in honeycomb middleware * honeycomb-related logging uses bole when available * type for logger * Organization/cleanup of core/honeycomb.ts * Refactor how honeycomb mock is created * Use the traceparent header for the context ID if available * context.addTraceAttributes method * scope otel "trace" attributes to "app." + note on traces vs spans * Fix setting otel "trace" attributes - strike that, reverse it * Upgrade actions from node 12.x to 16.x * Use node action v2 * Only add properties to otel trace span if defined * Fixes to make dispensary-dashboard build happy * Update honeycomb-beeline.d.ts in build * Make dispensary-dashboard happy with honeycomb-beeline.d.ts formatting * Naively upgrade typescript-eslint libraries to fix huge warning in consumer-app-gateway * Improved comments * Add some extra trace attributes * Refactor "trace attributes" feature * use otel.context.with instead of carrying spans on boltzmann context * Wrap honeycomb logging setup in if-block + add deprecation warning * Minor otel middleware bugfixes * Remove addTraceAttributes helper * Improve logging * Automatically append service_name and trace_type to every span * Silly templating bug * Test that traceExporter respects url * Improved otel logging * imports/exports match between honeycomb + prelude * Mock the span in the test instead of as a fallback * Fix honeycomb export * Honeycomb logging only generated in debug/dev build * Honeycomb logging fixes * Update documentation for OpenTelemetry support * Update examples to use current release build * Bump to 0.6.0 and fill out changelog fields * Expand middleware test to cover handlers * Regenerate all examples * Respect the same defaults as vanilla beelines * Don't write debug feature to package.json * Manage node version with volta (and also template it in the github action!) * Switch from GRPC exporter to HTTP exporter - need to update env vars * Switch on OTEL_* env vars instead of HONEYCOMB_API_HOST * Use otel diagnostic logger * Clean up SDK setup, get rid of errors * Button up otel logging * Remove debug flag from boltzmann generator * Support ALL THREE OTLP trace exporters * Improved comments * More comments * Only do otel logging if LOG_LEVEL === "debug" * Improved comments for OTEL_EXPORTER_OTLP_ENDPOINT * one OVER sampling rate * bugfix - use proto exporter when protocol is http/protobuf * Let otel use the automatically-configured sampler * Make HONEYCOMB_WRITEKEY optional for otel * Fix volta feature bug * Respect OTEL_SERVICE_NAME * More tests for parseEnv * Move honeycomb singleton out of prelude * Don't run honeycomb init inside test block, oops * Rename the default otel http span * Remove comment * Add span attributes for CORS origin * Make honeycomb settings logging more useful for beelines * Set the initialized flag when beeline * Minor logging tweaks * Some gaps on beeline trace_type/service.name attributes * Rename boltzman.honeycomb.trace_type to honeycomb.trace_type * Use {{ version }} instead of hard-coding 1.0 * Remove stale comment * Update stale test description * Remove stale comment * Update honeycomb middleware configuration docs * Tweaks to honeycomb middleware docs * Wrap honeycomb tracing in cors with template if block * Fix tests * fix typed example build * Remove ctor def in span processor + comment onEnd * Comment update Co-authored-by: Chris Dickinson <[email protected]> * Improved documentation and comments * Use INTERNAL SpanKind instead of SERVER * Document factory overrides as internal * Remove graceful shutdown code * Expose boltzmann version in /monitor/status * Remove compatibility + trace_type attributes * Install volta during tests * Try a different strategy to add volta to the PATH * why isnt volta working?? * Try running "volta install node" * Try installing volta during the build step * Remove volta from --all * Clean up release build task * updated package.json * Handle peer dependencies shenanigans as best we can Co-authored-by: Jeffrey Lembeck <[email protected]> Co-authored-by: Chris Dickinson <[email protected]>
- Loading branch information