I Created a custom workflow process step by implementing
Inside my custom workflow process step. I want to call sling scheduler and add a job
This is my custom workflow step class :
class MyStep implements WorkflowProcess
public void execute(WorkItem item, WorkflowSession session, MetaDataMap args) throws WorkflowException
// Here I am scheduling the job using Sling scheduler.
// it throws NullPointer Exception at this line.
This is my job class:
class MyJobClass implements Runnable
public void run()
//blah blah //blah
CreateVersionProcess cp = new CreateVersionProcess();
cp.execute(workitem, session, metadata);
ActivatePageProcess ap = new ActivatePageProcess();
Basically What I am trying to do is, I want to schedule the Versioning and Activation of the page at a later date, depending on some conditions. Is it possible to call CreateVersionProcess and ActivatePageProcess like this?? Also, if there is any better advice/solution for this scenario, I would love to take it.