Support Questions

Find answers, ask questions, and share your expertise

Getting ClassNotFound Exception while running java code via ECMA script in executeScript processor

New Contributor

Hello Team,

Need to execute one java class from jar using below lline of code in executeScript

logger = org.apache.log4j.Logger.getLogger("Test");
loggger.info("config------>"+config.databaseConfigMap);
loggger.info("before----->Packages.service---->"+Packages.services)
var service = Packages.services;
var df = new service.LDMService(logger); --getting below error on this line as per SC
df.runLegacyDataFlow(); 

abhiCoder_1-1642748386227.png

nifi executeScript property 
Jar file added to below Module Directory

abhiCoder_2-1642748456572.png

 

 

2 REPLIES 2

Expert Contributor

Have you verified if class name "services.LDMService" is present in provided jar file?

New Contributor

@ckumar Yes its exist in the JAR

Take a Tour of the Community
Don't have an account?
Your experience may be limited. Sign in to explore more.