compose
compose copied to clipboard
Optimize tracing for Docker Compose projects
Summary
This pull request optimizes the OpenTelemetry tracing functionality for Docker Compose projects. Key improvements include:
- Pre-allocating slices in
ProjectOptions,ServiceOptions, andContainerOptionsto minimize memory allocations and improve execution speed. - Simplified utility functions (
keys,getSourceNames, etc.) for readability and maintainability. - Optimized the project hash calculation by using direct formatting of the hash output.
- Improved tracing instrumentation by reducing redundant conversions between
SpanStartOptionandSpanStartEventOption. - Enhanced metadata collection for Docker containers, services, and Compose projects.
Testing
- Unit tests have been added to cover the new functionality.
- The full test suite, including end-to-end tests, has been run locally and passed without errors.
Issue Reference
Closes #12217
please sign off your commit, this is a legal requirement for all contributions on this repo
about your PR, afaict you just added a few explicit casts which have no (?) impact, as compiler already manages. What about the other improvements you listed here ?
closing for inactivity