Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

tJobRun with dynamic job run throws Exception on Karaf

Hi,
I have a problem with tRunJob component set to use dynamic job on Apache Karaf Server.

Project description:
I have one Camel route (named DummyRoute) with cTimer, sending messages from cSetBody to cTalendJob. cTalendJob calls job (named DummyJob) that performs a subjob (named DummySubJob) via tRunJob component. Important note here - tRunJob settings "Use Dynamic Job" is checked and dynamic job mapping active. Subjob makes logging and project ends here. Simple.

Issue description:
Project above works just fine in Talend Open Studio (both in Run and Debug mode). Runs every second and outputs the log message. Issue occures after deploying built .kar file to the Apache Karaf server. (OGSI container Apache Karaf). Camel Route is registered properly but execution fails and throws Exception on every run. Exception message is written below. Is says class file for DummySubJob couldn't be found, but .kar file includes ALL neccesarry files - also DummySubJob.class file. This issue can be fixed by changing dynamic job mapping to static by unchecking "Use Dynamic Job", but this behaviour is highly undesirable. It seems that the dynamically-called class loaded by tRunJob cannot be instantiated in OGSI container, because it is not exported in OGSI manifest.

I read the help for tRunJob component already but didn't find any useful information regarding this issue.

Exception in component tRunJob_1
java.lang.RuntimeException: Child job returns 1. It doesn't terminate normally.
Error: Could not find or load main class dummyproject.dummysubjob_0_1.DummySubJob



Software version:
Talend Open Studio for ESB v5.6.2.2.20150508_1414

Links to files:

Talend Project in zip archive

.kar file in archive, ready to deploy on Karaf

Java Exception

Dynamic Job Run settings in tJobRun

Unchecked "Dynamic Job Run", solution works OK deployed on Karaf
Labels (3)
2 Replies
Anonymous
Not applicable
Author

Hi,
Could you please take a  look at a jira issue: https://jira.talendforge.org/browse/TESB-10858?

Best regards
Sabrina
Anonymous
Not applicable
Author

Hello Sabrina,
I've read bug you sent carefully, but issue you've sent is different from mine. The problem I've described relates to checkbox "Use dynamic job" solely. With the "Use dynamic job" checked I my code fails on Karaf. Any ideas?