jglobus / JGlobus

jGlobus is a collection of Java client libraries for Globus® Toolkit security, GRAM, and GridFTP.
http://www.globus.org/toolkit/jglobus/
Apache License 2.0
24 stars 44 forks source link

NoSuchMethodError while running JGlobus #178

Open hsapkota opened 3 years ago

hsapkota commented 3 years ago

Hi, I was trying to run transfer between stampede2 to comet and was able to run transfer using globus-url-copy but when I try JGlobus implementation of transfer, I get the following error. [WARNING] java.lang.NoSuchMethodError: java.nio.ByteBuffer.clear()Ljava/nio/ByteBuffer; at org.globus.gsi.gssapi.GlobusGSSContextImpl.initSecContext (GlobusGSSContextImpl.java:970) at org.globus.ftp.extended.GridFTPControlChannel.authenticate (GridFTPControlChannel.java:209) at org.globus.ftp.extended.GridFTPControlChannel.authenticate (GridFTPControlChannel.java:140) at transfer_protocol.module.ChannelModule$ControlChannel.<init> (ChannelModule.java:243) at transfer_protocol.module.ChannelModule$ChannelPair.<init> (ChannelModule.java:446) at transfer_protocol.module.FTPClient.<init> (FTPClient.java:38) at transfer_protocol.module.GridFTPClient.process (GridFTPClient.java:173) at transfer_protocol.module.GridFTPClient.run (GridFTPClient.java:210) at java.lang.Thread.run (Thread.java:748) When I search on the internet about ByteBuffer method not found issue, many people were saying it was the issue with jdk version and I tried using jdk 1.8 and still results the same error.

kofemann commented 3 years ago

You should compile with java8. Java9 have introduced new methods to ByteBuffer class that brakes compatibility.