Avoid npe in netty 4.1 instrumentation
MODIFY
instrumentation/netty/netty-4.1-common/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/netty/v4_1/InstrumentedAddressResolverGroup.java
instrumentation/netty/netty-4.1-common/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/netty/v4_1/InstrumentedAddressResolverGroup.java
@@ -22,7 +22,7 @@ public final class InstrumentedAddressResolverGroup<T extends SocketAddress>
public static <T extends SocketAddress> AddressResolverGroup<T> wrap(
NettyConnectionInstrumenter instrumenter, AddressResolverGroup<T> delegate) {
- if (delegate instanceof InstrumentedAddressResolverGroup) {
+ if (delegate == null || delegate instanceof InstrumentedAddressResolverGroup) {
return delegate;
}
return new InstrumentedAddressResolverGroup<>(instrumenter, delegate);

Avoid npe in netty 4.1 instrumentation (#5902)