Conversation
This package implements a Docker Stats input using the OpenTelemetry Collector's dockerstats receiver, following the pattern established in PR #14315. Key features: - Type: integration with otelcol input (not content package) - Configurable collection interval, endpoint, and filtering - Comprehensive field definitions for container metrics - Full documentation and test policy Resolves: #15731 Co-authored-by: William Easton <strawgate@users.noreply.github.com>
Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
|
@claude how does this compare to the other feedback given to other input package PRs? as well as what has merged into main? any important discrepancies? It looks like some of the ways we're configuring collection are no longer available and use the Can you review the input package for other discrepancies? |
Vale Linting ResultsSummary: 6 suggestions found 💡 Suggestions (6)
The Vale linter checks documentation changes against the Elastic Docs style guide. To use Vale locally or report issues, refer to Elastic style guide for Vale. |
|
Claude finished @strawgate's task in 2m 52s —— View job Reviewing Docker OTel Input Package
SummaryI've compared this PR against merged OTel input packages (
|
| Field | This PR | nginx_input_otel | kubeletstats_input_otel | Upstream |
|---|---|---|---|---|
collection_interval |
✅ (as period) |
✅ | ✅ | ✅ |
endpoint |
✅ | ✅ | ✅ | ✅ |
initial_delay |
❌ Missing | ✅ | ✅ | ✅ |
timeout |
✅ | N/A | N/A | ✅ |
api_version |
✅ | N/A | N/A | ✅ |
excluded_images |
✅ | N/A | N/A | ✅ |
metrics (yaml) |
❌ Missing | N/A | ✅ | ✅ |
container_labels_to_metric_labels |
✅ | N/A | N/A | ✅ |
env_vars_to_metric_labels |
✅ | N/A | N/A | ✅ |
provide_per_core_cpu_metrics |
N/A | N/A | ❌ Removed | |
source.license |
❌ Missing | ✅ | ✅ | N/A |
type: duration for time fields |
❌ type: text |
✅ | ✅ | N/A |
📁 Missing Package Structure Elements
Based on other merged packages, consider adding:
_dev/build/build.yml- Build configuration (present inprometheus_input,sql_input, etc.)- System tests - More comprehensive test policies (see
kubeletstats_input_otelpattern with multiple test configs)
✅ What's Done Well
- Good documentation in
docs/README.md - Core configuration options are covered
- Package structure follows the basic pattern
- Uses
otelcolinput type correctly - Includes resourcedetection processor in the pipeline
Recommended Changes
- Add
metricsyaml field to enable/disable specific metrics - Remove
provide_per_core_cpu_metrics(deprecated upstream) - Add
initial_delayfield for consistency - Change
type: texttotype: durationfor time-based fields - Add
source.license: "Elastic-2.0"to manifest - Consider renaming
periodtocollection_intervalto match upstream naming
--- |
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
There was a problem hiding this comment.
The package structure follows the OTel input pattern well. A few items need attention:
Policy testing: The test-docker-stats.yml needs a corresponding .expected file to verify the rendered policy output (see hostmetrics_input_otel and iis_input_otel for examples).
Consistency with other packages: The period variable is marked required but has a fallback in the template. Other OTel input packages use required: false with a default value, which also simplifies the template.
Please also verify that CI passes with the policy tests once the expected file is added.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
packages/docker_otel_input/_dev/test/policy/test-docker-stats.yml
Outdated
Show resolved
Hide resolved
| description: Mapping of environment variables to metric labels (YAML format) | ||
| required: false | ||
| owner: | ||
| github: elastic/obs-infraobs-integrations |
There was a problem hiding this comment.
Missing to update the .github/CODEOWNERS file , and probably this should be owned for the time being by elastic/ecosystem ?
There was a problem hiding this comment.
It was present on the prior PR, just synced the older changes on top of this one.
However, I added the owner as packages/docker_input_otel @elastic/obs-infraobs-integrations since it seems to match the remaining otel input packages.
Do you know how this is decided?
There was a problem hiding this comment.
It was mentioned in the description that ecosystem should be the codeowners of these input packages for now.
#17131
Later on, I think these packages will change owners and probably to the team you mentioned.
packages/docker_otel_input/_dev/test/policy/test-docker-stats.yml
Outdated
Show resolved
Hide resolved
|
@claude Review the PR for any discrepancies, any existing comments, compare against existing packages and make a TODO list with all the action items. |
There was a problem hiding this comment.
The package structure follows the established OTel input package patterns. The build and lint checks pass locally.
Existing feedback that still needs attention:
periodvariable hasrequired: truewith a default value. Other OTel input packages userequired: falsesince the default makes it optional.- Documentation should include a Configuration section linking to upstream dockerstatsreceiver configuration to avoid duplication and stay current.
The source.license field and changelog link have been addressed since earlier comments. CODEOWNERS has been updated as discussed.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
There was a problem hiding this comment.
Several issues need to be addressed before merge:
New issue found:
- Variable name mismatch in system test (see inline comment)
Previously flagged issues (unresolved):
- manifest.yml line 37:
collection_intervalshould userequired: falsewith default value - manifest.yml line 18: Missing
source.licensefield (LOW priority) - Documentation should follow established patterns by pointing to upstream OTel receiver docs for metrics reference and configuration, rather than duplicating content that can become outdated
The package structure and test files otherwise look good and follow the established patterns for OTel input packages.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
packages/docker_input_otel/_dev/test/system/test-default-config.yml
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Reviewed the Docker OpenTelemetry Input Package. The package structure follows established patterns from other OTel input packages (hostmetrics_input_otel, nginx_input_otel), passes lint validation, and includes appropriate test configurations.
The existing review feedback from @mrodm regarding documentation style (referencing upstream docs rather than duplicating configuration details) is valid and should be addressed for consistency with other OTel input packages.
No new blocking issues found.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
There was a problem hiding this comment.
Previously flagged items requiring attention:
-
manifest.yml line 37:
collection_intervalusesrequired: truewhile other OTel input packages userequired: falsewith a default value. The current approach works but is inconsistent with the pattern innginx_input_otel,kubeletstats_input_otel, etc. -
Documentation: @mrodm's feedback about adding a Configuration section that references upstream dockerstatsreceiver documentation is valid for maintainability.
Clarification on source.license: An earlier automated comment suggested this field was missing, but it is present at lines 5-6 in manifest.yml. That comment can be disregarded.
The package otherwise follows established OTel input patterns correctly. CI is passing.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
There was a problem hiding this comment.
The implementation is well-structured and follows the established patterns from other OTel input packages (hostmetrics_input_otel, nginx_input_otel). The package passes linting, has correct test coverage, and the input template properly handles all configuration variables.
One existing thread remains unresolved: the reviewer has requested simplifying the documentation to follow the pattern of other OTel input packages by having a brief Configuration section that points to the upstream Docker Stats Receiver documentation rather than duplicating configuration details that could become outdated. See the thread at _dev/build/docs/README.md line 19.
No new technical issues identified. The package is ready to merge once the documentation feedback is addressed.
Why is Claude responding? | Type @claude to interact further
Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.
jmmcorreia
left a comment
There was a problem hiding this comment.
From my side, everything looks good. Will address additional comments, if any pop up.
|
Claude finished @strawgate's task in 1m 25s —— View job Final Review: Comparing Against Guide PRs
Compliance SummaryI've compared this package against the guidelines in PR #17396 (OTel Input Packages Guide) and PR #17397 (CONTRIBUTING.md updates). ✅ Submission Checklist from Guide (PR #17396)
✅ Variable Types (from Guide)
✅ Template Development (from Guide)
✅ Documentation (from Guide)
✅ PR Submission Requirements (from PR #17397)
Result: ✅ Package Fully Complies with GuidelinesThis package follows all the recommendations from both guide PRs:
The package is ready for merge from a guidelines compliance perspective. --- | Branch: Why is Claude responding? | Type Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not. |
| description: Mapping of environment variables to metric labels (YAML format) | ||
| required: false | ||
| owner: | ||
| github: elastic/obs-infraobs-integrations |
There was a problem hiding this comment.
It was mentioned in the description that ecosystem should be the codeowners of these input packages for now.
#17131
Later on, I think these packages will change owners and probably to the team you mentioned.
There was a problem hiding this comment.
Could you update this logo to include the OpenTelemetry in the right side corner ?
Some examples:
https://github.com/elastic/integrations/blob/main/packages/kubeletstats_input_otel/img/kubeletstats-logo.svg
https://github.com/elastic/integrations/blob/main/packages/iis_input_otel/img/iis_otellogo.svg
There was a problem hiding this comment.
Good catch, thanks for raising this!
I tried to update the logo as best as I could by trying to modify the svg code. Let me know if it looks ok to you or if you spot something that could be improved.
💚 Build Succeeded
History
|
mrodm
left a comment
There was a problem hiding this comment.
LGTM!
But it would be useful that the owners of the other docker packages do a review to this Pull Request too before merging if possible @elastic/obs-ds-hosted-services
|
Package docker_input_otel - 0.1.0 containing this change is available at https://epr.elastic.co/package/docker_input_otel/0.1.0/ |
* Add docker_otel_input package following OpenTelemetry input pattern This package implements a Docker Stats input using the OpenTelemetry Collector's dockerstats receiver, following the pattern established in PR elastic#14315. Key features: - Type: integration with otelcol input (not content package) - Configurable collection interval, endpoint, and filtering - Comprehensive field definitions for container metrics - Full documentation and test policy Resolves: elastic#15731 Co-authored-by: William Easton <strawgate@users.noreply.github.com> * updates to match httpcheck * Update manifest * Add docker container stats input package * Apply suggestion from @jsoriano Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * Address review comments, add UT * Update codeowners * Fix package name and UT * Fix doc and nitpicks * Modify deprecated attribute and added readme * Fix PR link Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Add integration test and allow support of metrics configuration * Fix var * Update README * Change resource detection to system only * Do not use Note that --------- Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com> Co-authored-by: William Easton <strawgate@users.noreply.github.com> Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> Co-authored-by: Joao <joao.correia@elastic.co> Co-authored-by: João Correia <marquescorreiajoao@gmail.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This package implements a Docker Stats input using the OpenTelemetry
Collector's dockerstats receiver, following the pattern established
in PR #14315.
Key features:
Type: integration with otelcol input (not content package)
Configurable collection interval, endpoint, and filtering
Comprehensive field definitions for container metrics
Full documentation and test policy
Resolves: #15731