Discuss (FTP) and (SFTP, FTPS and SCP), our Java file transfer clients.

Java 5 no longer supported?

no avatar
User

Voltron

Posts

3

Joined

Thu Aug 21, 2014 2:28 am

Java 5 no longer supported?

by Voltron » Thu Aug 21, 2014 3:12 am

I am using edtFTPj/PRO v4.5.0 in a WebLogic 10.0 application server, which is only certified for Java 5. I have a thin wrapper class that extends SecureFileTransferClient. My user made a mistake and called setServerValidationEnabled(true) but never called getAdvancedSSHSettings().getSSHServerValidator().addKnownHost(server, path). As could be expected, the connection failed. What was unexpected though was this exception:

E:\Test>C:\PF64\Java\jdk1.5.0_16\bin\java -cp ".;edtftpj-pro.jar;license.jar" FtpClient
INFO: OPEN scsapq27.mydomain.com:22 using edtFTPj/PRO 4.5.0
ERROR: Unable to connect to SFTP server scsapq27.mydomain.com
ERROR: com.enterprisedt.net.ftp.FTPException: java.io.IOException: method <init>(Ljava/lang/String;Ljava/lang/Throwable;)V not found

That constructor for java.io.IOException was introduced in Java 6, which is why the "method not found" exception is being thrown. When I run the exact same code against edtFTPj/PRO v4.2.0 I get a much nicer exception:

E:\Test>C:\PF64\Java\jdk1.5.0_16\bin\java -cp ".;edtftpj-pro.jar;license.jar" FtpClient
INFO: OPEN scsapq27.mydomain.com:22 using edtFTPj/PRO 4.2.0
ERROR: Caught IOException connecting to SFTP server scsapq27.mydomain.com
ERROR: com.enterprisedt.net.j2ssh.transport.kex.KeyExchangeException: The host signature is invalid or the host key was not accepted!

The release history for edtFTPj/PRO does not mention that support for Java 5 has been dropped. Was this intended? I'd like to use the latest version of the product that still runs under Java 5. Is that 4.2.0? If it's 4.3.0 or 4.4.0 can someone post download links?
no avatar
User

support2

Posts

3987

Joined

Tue May 18, 2004 8:30 am

Re: Java 5 no longer supported?

by support2 » Thu Aug 21, 2014 3:54 am

It's not intentional. If you post the stack trace that may tell us more about where the exception originates.
no avatar
User

Voltron

Posts

3

Joined

Thu Aug 21, 2014 2:28 am

Re: Java 5 no longer supported?

by Voltron » Thu Aug 21, 2014 6:55 am

Thanks for the prompt reply! This is with the 4.6.1 JAR.

E:\Test>C:\PF64\Java\jdk1.5.0_16\bin\java -cp ".;edtftpj-pro.4.6.1.jar;license.jar" FtpClient
INFO: OPEN scsapq27.mydomain.com:22 using edtFTPj/PRO 4.6.1
ERROR: Unable to connect to SFTP server scsapq27.mydomain.com
com.enterprisedt.net.ftp.FTPException: java.io.IOException: method <init>(Ljava/lang/String;Ljava/lang/Throwable;)V not found
at com.enterprisedt.net.ftp.async.AsyncResult.endAsyncInternal(AsyncResult.java:315)
at com.enterprisedt.net.ftp.async.ConnectResult.endAsync(ConnectResult.java:116)
at com.enterprisedt.net.ftp.SecureFileTransferClient.connect(SecureFileTransferClient.java:765)
at FtpClient.connect(FtpClient.java:71)
at FtpClient.main(FtpClient.java:139)
no avatar
User

Voltron

Posts

3

Joined

Thu Aug 21, 2014 2:28 am

Re: Java 5 no longer supported?

by Voltron » Thu Sep 04, 2014 5:54 am


Who is online

Users browsing this forum: Bing [Bot] and 15 guests

Powered by phpBB ® | phpBB3 Style by KomiDesign
cron