Skip to content

Feature request: tracer feature improvements #275

Closed
@dreamorosi

Description

@dreamorosi

Description of the feature request

Problem statement
While an initial implementation of the Tracer core package has been done there are a handful of features that are missing when compared with the Python version. Some of these features were implemented recently while others, due to the language difference, need to be implemented differently and for this reason where left out in the initial implementation.

Summary of the feature

  • Cold start annotation present for every invocation (#851). At the moment Tracer annotates only ColdStart = true during the first invocation.
  • Service name is added as an annotation (#861). At the moment Tracer uses the service name only as default namespace when adding metadata to traces.
  • Automatic traces for HTTP requests (Python version captures all libraries). At the moment Tracer (supports this) only via explicit opt-in using the escape hatch mechanism.
  • Reusing tracer across your code (Python version implements Singleton pattern). At the moment every new Tracer() returns a completely new instance, JS/TS could implement it like so.
    ⬆️ We are opting to not introduce this feature in order to not force this pattern on every customer. See this comment.

Code examples
N/A

Benefits for you and the wider AWS community
Same behaviour as other Powertools libraries & better DX

Describe alternatives you've considered
N/A

Additional context

Related issues, RFCs

Metadata

Metadata

Assignees

Labels

completedThis item is complete and has been merged/shippedfeature-requestThis item refers to a feature request for an existing or new utilitytracerThis item relates to the Tracer Utility

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions