# Java 17 JDBC Support

**URL:** https://community.dremio.com/t/java-17-jdbc-support/12746
**Category:** Uncategorized
**Created:** [February 4, 2025, 1:03pm UTC](https://community.dremio.com/t/java-17-jdbc-support/12746 "2025-02-04T13:03:19Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Praj11](https://avatars.discourse-cdn.com/v4/letter/p/f9ae1b/32.png) [@Praj11](https://community.dremio.com/u/Praj11)
#### Post date: [February 4, 2025, 1:03pm UTC](https://community.dremio.com/t/java-17-jdbc-support/12746/1 "2025-02-04T13:03:19Z")

</div>

Hi,  
I added your JDBC driver into my project (with version 25.2.0-202410241428100111-a963b970) and it has support for JDK 17 as per the release docs. While connecting, I am getting the below error, please if someone can help me with this

4-Feb-2025 10:53:55.850 SEVERE [Client-1] com.dremio.jdbc.shaded.com.dremio.exec.rpc.RpcExceptionHandler.exceptionCaught Exception in RPC communication. Connection: null ↔ null (user client). Closing connection.  
java.lang.UnsupportedOperationException: sun.misc.Unsafe or java.nio.DirectByteBuffer.(long, int) not available  
at com.dremio.jdbc.shaded.io.netty.util.internal.PlatformDependent.directBuffer(PlatformDependent.java:534)  
at com.dremio.jdbc.shaded.io.netty.buffer.NettyArrowBuf.getDirectBuffer(NettyArrowBuf.java:267)  
at com.dremio.jdbc.shaded.io.netty.buffer.NettyArrowBuf.nioBuffer(NettyArrowBuf.java:245)  
at com.dremio.jdbc.shaded.io.netty.buffer.NettyArrowBuf.nioBuffers(NettyArrowBuf.java:229)  
at com.dremio.jdbc.shaded.io.netty.buffer.NettyArrowBuf.setBytes(NettyArrowBuf.java:389)  
at com.dremio.jdbc.shaded.io.netty.buffer.MutableWrappedByteBuf.setBytes(MutableWrappedByteBuf.java:373)  
at com.dremio.jdbc.shaded.io.netty.buffer.ExpandableByteBuf.setBytes(ExpandableByteBuf.java:27)  
at com.dremio.jdbc.shaded.io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:1132)  
at com.dremio.jdbc.shaded.io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:356)  
at com.dremio.jdbc.shaded.io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:151)  
at com.dremio.jdbc.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788)  
at com.dremio.jdbc.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:724)  
at com.dremio.jdbc.shaded.io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:650)  
at com.dremio.jdbc.shaded.io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562)  
at com.dremio.jdbc.shaded.io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:994)  
at com.dremio.jdbc.shaded.io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)  
at java.base/java.lang.Thread.run(Thread.java:840)  
04-Feb-2025 10:53:55.860 INFO [Client-1] com.dremio.jdbc.shaded.com.dremio.exec.rpc.RpcBus$ChannelClosedHandler.operationComplete [USER]: Channel closed null ↔ null (user client)

---

<div class="post-metadata">

### Author: ![Benny\_Chow](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/benny_chow/32/5527_2.png) [@Benny\_Chow](https://community.dremio.com/u/Benny_Chow)
#### Post date: [February 19, 2025, 3:53am UTC](https://community.dremio.com/t/java-17-jdbc-support/12746/2 "2025-02-19T03:53:45Z")

</div>

> [@Praj11](#):
>
> java.lang.UnsupportedOperationException: sun.misc.Unsafe or java.nio.DirectByteBuffer

This might be JVM specific. Can you try this system property?

`-Dio.netty.tryReflectionSetAccessible=true`
