So I am trying to connect to FTPClient from my JavaCompute node in Integration Bus v10.0.0.8.
The problem occurs because my runtime don’t see the imported jar.
Exception that happens :
java.lang.NoClassDefFoundError: org/apache/commons/net/ftp/FTPClient
Can anyone help me?
2
Answers
So the problem was that my RUNTIME did not see the jar (hence the exception) and what i did was that i imported the jar in shared-classes folder:
C:ProgramDataIBMMQSIconfigOracleDatabaseshared-classes
You probably did not add the JAR files as dependencies of the Java project in your Toolkit.
lib
subdirectory in your Java project and copy the JAR files there.Add JARs...
and add the libraries from thelib
directory.See also the Knowledge Center.
To read a file from an FTP server, you can also use the File Input or File Read nodes and configure the FTP section. In case you use SFTP, please look at IT23379 as well.