Skip to content

Unclear javadoc in Instrumentation regarding return value #2806

Closed

Description

@andimarek

The Instrumentation docs seem to imply that you can return null InstrumentationContext, while in fact it will cause a NPE.

We should reference the

    private static final InstrumentationContext<Object> NO_OP = new SimpleInstrumentationContext<>();

as the preferred return value if you don't need a context.

Activity

  1. andimarek commented on Apr 26, 2022

    @andimarek
    MemberAuthor

    Related to that: #2769

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions