Skip to content

Add tracing for other annotations and config#311

Merged
tylerbenson merged 2 commits into
tyler/warningsfrom
tyler/additional-trace-annotations
May 7, 2018
Merged

Add tracing for other annotations and config#311
tylerbenson merged 2 commits into
tyler/warningsfrom
tyler/additional-trace-annotations

Conversation

@tylerbenson
Copy link
Copy Markdown
Contributor

Allows for specifying additional traced methods via env var or sys prop config.

@tylerbenson tylerbenson added the inst: others All other instrumentations label May 4, 2018
@tylerbenson tylerbenson added this to the 0.8.0 milestone May 4, 2018
@tylerbenson tylerbenson requested a review from realark May 4, 2018 07:37
public AgentBuilder apply(final AgentBuilder agentBuilder) {
ElementMatcher.Junction<NamedElement> methodTraceMatcher =
is(new TypeDescription.ForLoadedType(Trace.class));
for (final String annotationName : ADDITIONAL_ANNOTATIONS) {
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps we want a config to allow disabling the additional annotations? Maybe instead a config to set your own list?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's probably a good idea in case this causes unwanted traces to be created.

Copy link
Copy Markdown
Contributor

@realark realark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very cool. Nice work.

Copy link
Copy Markdown
Contributor

@realark realark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once there's a config to disable the list of additional traces (or specify a custom list) then I'm okay with merging.

@tylerbenson tylerbenson force-pushed the tyler/additional-trace-annotations branch from 35bdc4c to fc6f4c2 Compare May 7, 2018 00:34
@tylerbenson tylerbenson changed the base branch from tyler/jacoco to tyler/warnings May 7, 2018 00:34
tylerbenson and others added 2 commits May 7, 2018 13:27
Allows for specifying additional traced methods via env var or sys prop config.
List can be set to empty if needed.
@tylerbenson tylerbenson force-pushed the tyler/additional-trace-annotations branch from 7609892 to c81615b Compare May 7, 2018 03:27
@tylerbenson tylerbenson merged this pull request into tyler/warnings May 7, 2018
@tylerbenson tylerbenson deleted the tyler/additional-trace-annotations branch May 7, 2018 23:54
tylerbenson added a commit that referenced this pull request May 8, 2018
Add tracing for other annotations and config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

inst: others All other instrumentations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants