[ 
https://issues.apache.org/jira/browse/CASSANDRA-18180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17702345#comment-17702345
 ] 

Ekaterina Dimitrova commented on CASSANDRA-18180:
-------------------------------------------------

I just noticed that in the latest trunk runs with JDK17 the test fails with:
{code:java}
14:15:18,910 Connection.java:1327 - Connection[/127.0.0.1:9042-1, inFlight=0, 
closed=false] connection error 
com.datastax.shaded.netty.handler.codec.DecoderException: 
javax.net.ssl.SSLException: Received fatal alert: internal_error at 
com.datastax.shaded.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:461)
 at 
com.datastax.shaded.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:356)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:335)
 at 
com.datastax.shaded.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1304)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:356)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
 at 
com.datastax.shaded.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:921)
 at 
com.datastax.shaded.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:135)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:646)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKeysPlain(NioEventLoop.java:546)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:500)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:460) 
at 
com.datastax.shaded.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:131)
 at 
com.datastax.shaded.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
 at java.base/java.lang.Thread.run(Thread.java:833) Caused by: 
javax.net.ssl.SSLException: Received fatal alert: internal_error at 
java.base/sun.security.ssl.Alert.createSSLException(Alert.java:133) at 
java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117) at 
java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:358) at 
java.base/sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:293) at 
java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:204) 
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:172) at 
java.base/sun.security.ssl.SSLEngineImpl.decode(SSLEngineImpl.java:736) at 
java.base/sun.security.ssl.SSLEngineImpl.readRecord(SSLEngineImpl.java:691) at 
java.base/sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:506) at 
java.base/sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:482) at 
java.base/javax.net.ssl.SSLEngine.unwrap(SSLEngine.java:679) at 
com.datastax.shaded.netty.handler.ssl.SslHandler$SslEngineType$3.unwrap(SslHandler.java:283)
 at 
com.datastax.shaded.netty.handler.ssl.SslHandler.unwrap(SslHandler.java:1205) 
at 
com.datastax.shaded.netty.handler.ssl.SslHandler.decodeJdkCompatible(SslHandler.java:1108)
 at 
com.datastax.shaded.netty.handler.ssl.SslHandler.decode(SslHandler.java:1151) 
at 
com.datastax.shaded.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:491)
 at 
com.datastax.shaded.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:430)
 ... 16 common frames omitted DEBUG [cluster1-nio-worker-0] <main> 2023-03-17 
14:15:18,911 Connection.java:601 - Defuncting Connection[/127.0.0.1:9042-1, 
inFlight=0, closed=false] because: [localhost/127.0.0.1:9042] Unexpected 
exception triggered (com.datastax.shaded.netty.handler.codec.DecoderException: 
javax.net.ssl.SSLException: Received fatal alert: internal_error) DEBUG 
[cluster1-nio-worker-0] <main> 2023-03-17 14:15:18,911 
ConvictionPolicy.java:118 - [localhost/127.0.0.1:9042] preventing new 
connections for the next 1000 ms DEBUG [cluster1-nio-worker-0] <main> 
2023-03-17 14:15:18,911 ConvictionPolicy.java:102 - [localhost/127.0.0.1:9042] 
Connection[/127.0.0.1:9042-1, inFlight=0, closed=false] failed, remaining = 0 
DEBUG [cluster1-nio-worker-0] <main> 2023-03-17 14:15:18,911 
Connection.java:892 - Connection[/127.0.0.1:9042-1, inFlight=0, closed=true] 
closing connection DEBUG [cluster1-nio-worker-0] <main> 2023-03-17 14:15:18,912 
Connection.java:950 - Not terminating Connection[/127.0.0.1:9042-1, inFlight=0, 
closed=true]: there are still pending requests DEBUG [main] <main> 2023-03-17 
14:15:18,912 ControlConnection.java:285 - [Control connection] error on 
localhost/127.0.0.1:9042 connection, no more host to try 
com.datastax.driver.core.exceptions.TransportException: 
[localhost/127.0.0.1:9042] Connection has been closed at 
com.datastax.driver.core.Connection$ConnectionCloseFuture.force(Connection.java:1458)
 at 
com.datastax.driver.core.Connection$ConnectionCloseFuture.force(Connection.java:1439)
 at com.datastax.driver.core.Connection.defunct(Connection.java:622) at 
com.datastax.driver.core.Connection$Dispatcher.exceptionCaught(Connection.java:1361)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelInboundHandlerAdapter.exceptionCaught(ChannelInboundHandlerAdapter.java:131)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelHandlerAdapter.exceptionCaught(ChannelHandlerAdapter.java:88)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelInboundHandlerAdapter.exceptionCaught(ChannelInboundHandlerAdapter.java:131)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelHandlerAdapter.exceptionCaught(ChannelHandlerAdapter.java:88)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelInboundHandlerAdapter.exceptionCaught(ChannelInboundHandlerAdapter.java:131)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelInboundHandlerAdapter.exceptionCaught(ChannelInboundHandlerAdapter.java:131)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelHandlerAdapter.exceptionCaught(ChannelHandlerAdapter.java:88)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.channel.ChannelInboundHandlerAdapter.exceptionCaught(ChannelInboundHandlerAdapter.java:131)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:259)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:251)
 at 
com.datastax.shaded.netty.handler.ssl.SslHandler.exceptionCaught(SslHandler.java:979)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:280)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.notifyHandlerException(AbstractChannelHandlerContext.java:843)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:358)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:335)
 at 
com.datastax.shaded.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1304)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:356)
 at 
com.datastax.shaded.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
 at 
com.datastax.shaded.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:921)
 at 
com.datastax.shaded.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:135)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:646)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKeysPlain(NioEventLoop.java:546)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:500)
 at 
com.datastax.shaded.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:460) 
at 
com.datastax.shaded.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:131)
 at 
com.datastax.shaded.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
 at java.base/java.lang.Thread.run(Thread.java:833) DEBUG [main] <main> 
2023-03-17 14:15:18,913 Cluster.java:1915 - Shutting down WARN 14:15:18 Unknown 
exception in client networking io.netty.handler.codec.DecoderException: 
javax.net.ssl.SSLException: Fail to unwrap network record at 
io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:478)
 at 
io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276)
 at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
 at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
 at 
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
 at 
io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
 at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
 at 
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
 at 
io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
 at 
io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
 at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:719) 
at 
io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:655)
 at 
io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:581) at 
io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) at 
io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
 at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) 
at 
io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
 at java.base/java.lang.Thread.run(Thread.java:833) Caused by: 
javax.net.ssl.SSLException: Fail to unwrap network record at 
java.base/sun.security.ssl.Alert.createSSLException(Alert.java:133) at 
java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:371) at 
java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:314) at 
java.base/sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:522) at 
java.base/sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:482) at 
java.base/javax.net.ssl.SSLEngine.unwrap(SSLEngine.java:679) at 
io.netty.handler.ssl.SslHandler$SslEngineType$3.unwrap(SslHandler.java:282) at 
io.netty.handler.ssl.SslHandler.unwrap(SslHandler.java:1387) at 
io.netty.handler.ssl.SslHandler.decodeJdkCompatible(SslHandler.java:1282) at 
io.netty.handler.ssl.SslHandler.decode(SslHandler.java:1329) at 
io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:508)
 at 
io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:447)
 ... 17 common frames omitted Caused by: java.lang.ClassCastException: class 
org.apache.cassandra.utils.concurrent.Ref cannot be cast to class 
sun.nio.ch.DirectBuffer (org.apache.cassandra.utils.concurrent.Ref is in 
unnamed module of loader 
org.apache.cassandra.distributed.shared.InstanceClassLoader @2a0ce342; 
sun.nio.ch.DirectBuffer is in module java.base of loader 'bootstrap') at 
java.base/com.sun.crypto.provider.GaloisCounterMode$GCMEngine.overlapDetection(GaloisCounterMode.java:865)
 at 
java.base/com.sun.crypto.provider.GaloisCounterMode$GCMDecrypt.doFinal(GaloisCounterMode.java:1502)
 at 
java.base/com.sun.crypto.provider.GaloisCounterMode.engineDoFinal(GaloisCounterMode.java:447)
 at java.base/javax.crypto.Cipher.doFinal(Cipher.java:2500) at 
java.base/sun.security.ssl.SSLCipher$T12GcmReadCipherGenerator$GcmReadCipher.decrypt(SSLCipher.java:1659)
 at 
java.base/sun.security.ssl.SSLEngineInputRecord.decodeInputRecord(SSLEngineInputRecord.java:239)
 at 
java.base/sun.security.ssl.SSLEngineInputRecord.decode(SSLEngineInputRecord.java:196)
 at 
java.base/sun.security.ssl.SSLEngineInputRecord.decode(SSLEngineInputRecord.java:159)
 at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:111) at 
java.base/sun.security.ssl.SSLEngineImpl.decode(SSLEngineImpl.java:736) at 
java.base/sun.security.ssl.SSLEngineImpl.readRecord(SSLEngineImpl.java:691) at 
java.base/sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:506) ... 25 
common frames omitte{code}
Now I see:
{code:java}
(org.apache.cassandra.utils.concurrent.Ref is in unnamed module of loader 
org.apache.cassandra.distributed.shared.InstanceClassLoader @2a0ce342; 
sun.nio.ch.DirectBuffer is in module java.base of loader 'bootstrap') at {code}
in [this 
run|https://app.circleci.com/pipelines/github/ekaterinadimitrova2/cassandra/2321/workflows/de1f521d-c5cb-4ddd-bc45-9ec71b577bf3/jobs/19932/tests]

But I did not find the previous class cast exception... to be investigated

> bulkLoaderSuccessfullyStreamsOverSsl fails with ClassCastException on JDK17
> ---------------------------------------------------------------------------
>
>                 Key: CASSANDRA-18180
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-18180
>             Project: Cassandra
>          Issue Type: Bug
>          Components: CI
>            Reporter: Ekaterina Dimitrova
>            Priority: Normal
>
> While working on CASSANDRA-17992 we hit: 
> {code:java}
> java.lang.ClassCastException: class 
> org.apache.cassandra.utils.memory.BufferPool$Chunk cannot be cast to class 
> sun.nio.ch.DirectBuffer (org.apache.cassandra.utils.memory.BufferPool$Chunk 
> is in unnamed module of loader 'app'; sun.nio.ch.DirectBuffer is in module 
> java.base of loader 'bootstrap')\n\tat 
> java.base/com.sun.crypto.provider.GaloisCounterMode$GCMEngine.overlapDetection(GaloisCounterMode.java:865)\n\tat
>  
> java.base/com.sun.crypto.provider.GaloisCounterMode$GCMDecrypt.doFinal(GaloisCounterMode.java:1502)\n\tat
>  
> java.base/com.sun.crypto.provider.GaloisCounterMode.engineDoFinal(GaloisCounterMode.java:447)\n\tat
>  
> {code}
> The issue is exposed with JDK 17, trunk; if interested, ping [~e.dimitrova] 
> for current branch as there is no feature branch at the moment
>  
> CC [~benedict] 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to