How to fix the “Found Netty's native epoll transport in the classpath, but epoll is not available. Using NIO instead” warning?

后端 未结 1 1341
别跟我提以往
别跟我提以往 2020-12-03 21:03

I am using Cassandra and, during startup, Netty prints a warning with a stack trace:

Found Netty\'s native epoll transport in the classpath, but epoll

1条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-03 22:03

    If you are running on Linux, you can use the native Linux driver. For instance, if you are using Maven, add a dependency like this:

    
      io.netty
      netty-transport-native-epoll
      4.0.27.Final
      linux-x86_64
    
    

    An alternative, you can suppress the warning by setting -Dcom.datastax.driver.FORCE_NIO=true. As it is only a performance optimization, it is a viable option to ignore it.

    For more background, refer to the Netty documentation about native transports.

    0 讨论(0)
提交回复
热议问题