<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Nifi : groovy: 32: unable to resolve class JSch in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288323#M213573</link>
    <description>&lt;P&gt;Here are the standard steps for debugging scripts that fail in Nifi.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Please make sure the script works in general.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Then make sure that in your test you are on the same machine with the same rights and such.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Usually this suffices, if it really fails we can dig more to search about this kind of problem.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 26 Jan 2020 12:11:25 GMT</pubDate>
    <dc:creator>DennisJaheruddi</dc:creator>
    <dc:date>2020-01-26T12:11:25Z</dc:date>
    <item>
      <title>Nifi : groovy: 32: unable to resolve class JSch</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288302#M213557</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I'm running a groovy script which handles SFTP&lt;/P&gt;&lt;P&gt;My Apache NiFi version&amp;nbsp; is 1.5.0.3.1.2.0-7&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My script starts with this:&lt;/P&gt;&lt;P&gt;import com.jcraft.jsch.*&lt;/P&gt;&lt;P&gt;def flowFile = session.get()&lt;BR /&gt;if(!flowFile) {&lt;BR /&gt;return&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I receive the file to process and move I see them in the queue but also the following is appear in the in the nifi-app.log&lt;/P&gt;&lt;P&gt;2020-01-25 19:00:00,041 ERROR [Timer-Driven Process Thread-8] o.a.nifi.processors.script.ExecuteScript ExecuteScript[id=56c17bab-81ba-313c-9a00-aa82d48c3ea0] ExecuteScript[id=56c17bab-81ba-313c-9a00-aa82d48c3ea0] failed to process due to org.apache.nifi.processor.exception.ProcessException: javax.script.ScriptException: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:&lt;BR /&gt;Script10025.groovy: 32: unable to resolve class JSch&lt;BR /&gt;@ line 32, column 6.&lt;BR /&gt;JSch ssh = new JSch()&lt;BR /&gt;^&lt;/P&gt;&lt;P&gt;Script10025.groovy: 32: unable to resolve class JSch&lt;BR /&gt;@ line 32, column 12.&lt;BR /&gt;JSch ssh = new JSch()&lt;BR /&gt;^&lt;/P&gt;&lt;P&gt;Script10025.groovy: 33: unable to resolve class Session&lt;BR /&gt;@ line 33, column 9.&lt;BR /&gt;Session sshSession = ssh.getSession(sftpUser, sftpHost, sftpPort)&lt;BR /&gt;^&lt;/P&gt;&lt;P&gt;Script10025.groovy: 35: unable to resolve class Channel&lt;BR /&gt;@ line 35, column 10.&lt;BR /&gt;Channel channel&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The script is using the following bundle&lt;/P&gt;&lt;P&gt;org.apache.nifi - nifi-scripting-nar&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can find the above bundle here&lt;/P&gt;&lt;P&gt;/hadoop/nifi/work/nar/extensions/nifi-standard-nar-1.5.0.3.1.2.0-7.nar-unpacked&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please suggest what should I check to fix the problem ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Sat, 25 Jan 2020 17:36:42 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288302#M213557</guid>
      <dc:creator>Galapow</dc:creator>
      <dc:date>2020-01-25T17:36:42Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi : groovy: 32: unable to resolve class JSch</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288323#M213573</link>
      <description>&lt;P&gt;Here are the standard steps for debugging scripts that fail in Nifi.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Please make sure the script works in general.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Then make sure that in your test you are on the same machine with the same rights and such.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Usually this suffices, if it really fails we can dig more to search about this kind of problem.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 26 Jan 2020 12:11:25 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288323#M213573</guid>
      <dc:creator>DennisJaheruddi</dc:creator>
      <dc:date>2020-01-26T12:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi : groovy: 32: unable to resolve class JSch</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288333#M213578</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/31428"&gt;@DennisJaheruddi&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your suggestions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The scripts works in general.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Based on the error message I dont think this is problem with rights but I compared the good one with the problematic one.&lt;/P&gt;&lt;P&gt;From OS level perspective&lt;/P&gt;&lt;P&gt;I'm using nifi user to run the nifi process and the user is the owner /hadoop/nifi which is the working directory for nifi and has all the read/write/execute permission.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Did you mean other rights and such?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Sun, 26 Jan 2020 17:56:25 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288333#M213578</guid>
      <dc:creator>Galapow</dc:creator>
      <dc:date>2020-01-26T17:56:25Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi : groovy: 32: unable to resolve class JSch</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288359#M213594</link>
      <description>&lt;P&gt;Problem is solved&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The module directory field was incorrect.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 16:47:02 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-groovy-32-unable-to-resolve-class-JSch/m-p/288359#M213594</guid>
      <dc:creator>Galapow</dc:creator>
      <dc:date>2020-01-27T16:47:02Z</dc:date>
    </item>
  </channel>
</rss>

