I'm developing a web-app based ETL too (with Kettle engine), using Java.
I'm running into issues, while trying to stop a running Job. I'm not sure if using the CarteSingleton.java is correct. I'm using a custom singleton map.
My code is as below
Job job = new Job(null, jobMeta);
job.setLogLevel(LogLevel.DETAILED);
job.setGatheringMetrics(true);
job.start();
Once job.start() is invoked, I'm trying to store that job object in a custom singleton map and retrieve the exact Job object that was stored in map, and on invocation of stopAll() (see code below) with another REST call, while the Job's status is RUNNING, to stop it. But that doesn't stop the running job. Kettle Engine is not getting notified of this! Job Execution continues. The .kjb / .ktr was creating using SPOON, although I'm not using SPOON to run/stop execution.
Is there any Kettle API config I've to change, to be able to use
same job object
job.stopAll();
Could you please enlighten on the API and sample example, if any to stop a running JOB or transformation using Java?
Any pointers or help here would be great! Thanks, again.
Regards, Sanjeev