Execution Listener is not working in Spring boot camunda project

Hi ,

I need to call one Execution Listener class at the end of a particular Task.
but at runtime its giving me cannot Instantiate the class . cannot load class. error is there

public class Boundary implements ExecutionListener {

@Override
public void notify(DelegateExecution delegateTask) {
	system.out.println("Test Execution Listener");
	}

}

please help me on this

Make it a bean and use delegate expression.

I also tried using delegate Expression like In bpmn I gave
#{BoundaryConfig}

and in java class.

@Service(“BoundaryConfig”)
public class Boundary implements ExecutionListener {

@Override
public void notify(DelegateExecution delegateTask) {
	system.out.println("Test Execution Listener");
	}

}

but it was giving cannot resolve expression : BoundaryConfig and cannot load class

configure like ${BoundaryConfig} in bpmn model.