Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

java.lang.NoClassDefFoundError: com/enterprisedt/net/ftp/FTPException

Hi all
I am trying to set up a tFTPConnection, with FTPS Support, using the below setup

However I am left with the following error when I try and run it:
java.lang.NoClassDefFoundError: com/enterprisedt/net/ftp/FTPException
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2570)
at java.lang.Class.getMethod0(Class.java:2813)
at java.lang.Class.getMethod(Class.java:1663)
at sun.launcher.LauncherHelper.getMainMethod(LauncherHelper.java:494)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:486)
Caused by: java.lang.ClassNotFoundException: com.enterprisedt.net.ftp.FTPException
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 6 more
Exception in thread "main"


Any ideas what is wrong?
I am running this:
"Talend Open Studio for Data Integration"
Version: 5.6.1
Build id: V5.6.1_20141207_1530
On a windows 8 64bit machine.
Labels (3)
31 Replies
Anonymous
Not applicable
Author

THanks for your input. I'll check whether this rule still makes sense.
Anonymous
Not applicable
Author

Hey all again
Right, so I did a clean install of Talend 6.0, created just a TFTPConnection with FTPS support, and have received the following error message:
Starting job Bentley_FTP at 13:07 28/07/2015.
connecting to socket on port 3918
connected
java.io.FileNotFoundException:
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:146)
at java.io.FileInputStream.<init>(FileInputStream.java:101)
at local_project.bentley_ftp_0_1.Bentley_FTP$1MyTrust_tFTPConnection_1.getTrustManagers(Bentley_FTP.java:311)
at local_project.bentley_ftp_0_1.Bentley_FTP$1MyTrust_tFTPConnection_1.access$0(Bentley_FTP.java:299)
at local_project.bentley_ftp_0_1.Bentley_FTP.tFTPConnection_1Process(Bentley_FTP.java:330)
at local_project.bentley_ftp_0_1.Bentley_FTP.runJobInTOS(Bentley_FTP.java:611)
at local_project.bentley_ftp_0_1.Bentley_FTP.main(Bentley_FTP.java:468)
disconnected
Job Bentley_FTP ended at 13:07 28/07/2015.

This is a completely clean install and I am getting the above error.
Any ideas?!
Anonymous
Not applicable
Author

This is down to your job configuration. You are pointing to a file which doesn't exist. Go to line 311 in your Bentley_FTP job's source code (see image below to see how to see the source) and you should be able to see what component has this issue.
0683p000009MB0e.png
Anonymous
Not applicable
Author

Rich Talend 6.0 doesn't have the lines for code (quite annoyingly!) but it appears to be:
ks.load(new java.io.FileInputStream("")
Anonymous
Not applicable
Author

That sucks, but we can change that. Go to Windows--> Preferences --> General --> Editors --> Text Editors (as below)
0683p000009MB9L.png
Then tick "Show Line Numbers".
You will then see the line numbers.
A FileInputStream is used for reading a file. It looks like your job is looking to read a file called "". You will need to set this. Hopefully the line numbers will point you to the actual component.
Anonymous
Not applicable
Author

Rich
I think I have worked out the issue of this one....
I am trying to connect to FTPS with no keystore file or password.
I don't have these and don't need them. Is there anyway to bypass this?
Many thanks
Anonymous
Not applicable
Author

I can't say I have tried this to be honest. It would appear that Talend requires you have these for FTPS. Maybe you could create an empty keystore and password and try use those to get round this. That is what I would try.
gorotman
Creator II
Creator II

Usign tFTPConnection i have this error "com.enterprisedt cannot be resolved to a type", from this source code:
com.enterprisedt.net.ftp.FTPClient ftp_tFTPFileList_1 = null;
ftp_tFTPFileList_1 = (com.enterprisedt.net.ftp.FTPClient) globalMap.get("conn_tFTPConnection_1");

I fixed using tLibraryLoad to manually load "edtftpj-2.4.0.jar" (but if I can't find jar file in TOS plugin folder).
But now when I use tFTPFileList (that refer to tFTPConnection), this hangs for "java.lang.ClassCastException: it.sauronsoftware.ftp4j.FTPClient cannot be cast to com.enterprisedt.net.ftp.FTPClient" at this point:
ftp_tFTPFileList_1 = (com.enterprisedt.net.ftp.FTPClient) globalMap.get("conn_tFTPConnection_1");

I'm using a sftp connection, with implicit option.
bye
Anonymous
Not applicable
Author

Are you sure you have downloaded and installed all so called modules which the studio at the beginning expects?
gorotman
Creator II
Creator II

yes, quite sure. I downloaded modules required after the 6.1.1 fresh installation.
Indeed tLibraryLoad already shows edtftpj-2.4.0, I hadn't added to TOS when I used.
But if I open modules view, I don't find edtftpj dependecies by ftp component.