add allowlist to awsentity processor for container insights to fix service names
Description of the issue
We added the awsentity processor to the container insights pipeline including the add_entity flag for the emfexporter.
This causes a problem where the entity processor tries to get the service name and now it overrides the EMF log's Service field which is unintended. This creates the wrong metric dimension and high cardinality metrics.
Bad: "Service": "busybox-service-jn9tc"
Good: "Service": "busybox-service"
Description of changes
Add an allow list to the awsentity processor to only allow entity attributes to be appended to the telemetry. For container insights we will only append the platform type:
"com.amazonaws.cloudwatch.entity.internal.platform.type"
License
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Tests
make test
Requirements
Before commit the code, please do the following steps.
- Run
make fmtandmake fmt-sh - Run
make lint
This PR was marked stale due to lack of activity.