Skip to content

Class Instrumentation breaks when local variable set to null #4

@paulseawa

Description

@paulseawa

If you initialize a local variable to null, then call an await() within a try catch block, you get ClassNotFoundException on the class in which you did that, during that classes initialization.

Simply by removing the null initialization works around the issue.

  @Async
  public Task<Void> doStuff(Task<Void> otherStuff) {

    String x = null;        //bad
    //String x;             //ok

    try {
      await(otherStuff);
    } catch (Exception e) {
      throw e;
    }
    return Task.done();

  }

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions