Hi Team,
I have upgraded netty-handler jar version recently from 4.1.77.Final to 5.0.0.Alpha2 but looks like my GRPC call is getting failed in between because of this upgrade.
After upgrading the above jar below is flow where it is getting failed. Issue is with the method
toInternalLevel present in LogLevel class under netty-handler jar. In earlier version(4.1.77.Final) of this jar this method had access modifier as public but in current version(5.0.0.Alpha2) public access modifier has been removed and because of that I am getting below exception.
"stackTrace": "java.lang.IllegalAccessError: tried to access method io.netty.handler.logging.LogLevel.toInternalLevel()Lio/netty/util/internal/logging/InternalLogLevel; from class io.netty.handler.codec.http2.Http2FrameLogger\n\tat io.netty.handler.codec.http2.Http2FrameLogger.checkAndConvertLevel(Http2FrameLogger.java:63)\n\tat io.netty.handler.codec.http2.Http2FrameLogger.<init>(Http2FrameLogger.java:54)\n\tat io.grpc.netty.NettyClientHandler.newHandler(NettyClientHandler.java:201)\n\tat io.grpc.netty.NettyClientHandler.newHandler(NettyClientHandler.java:158)\n\tat io.grpc.netty.NettyClientTransport.start(NettyClientTransport.java:217)\n\t... 9 frames truncated\n\t... 3 common frames omitted\nWrapped by: io.grpc.StatusRuntimeException: INTERNAL: Panic! This is a bug!\n\tat io.grpc.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:271)\n\tat io.grpc.stub.ClientCalls.getUnchecked(ClientCalls.java:252)\n\tat
Code Flow:
NettyClientHandler(grpc-netty : 1.47.0):
Http2FrameLogger frameLogger = new Http2FrameLogger(LogLevel.DEBUG, NettyClientHandler.class);
|
|
Http2FrameLogger(netty-codec-http2 : 4.1.77.Final)
public Http2FrameLogger(LogLevel level, Class<?> clazz) {
this(checkAndConvertLevel(level), InternalLoggerFactory.getInstance(checkNotNull(clazz, "clazz")));
}
|
|
Http2FrameLogger(netty-codec-http2 : 4.1.77.Final)
private static InternalLogLevel checkAndConvertLevel(LogLevel level) {
return ((LogLevel)ObjectUtil.checkNotNull(level, "level")).toInternalLevel();
}
|
|
LogLevel(netty-handler : 5.0.0.Alpha2)
InternalLogLevel toInternalLevel() {
return internalLevel;
}
Thanks for any thoughts,
Vivek Baranwal