protected void cleanDb() {
processEngineConfiguration.getCommandExecutorTxRequired()
.execute(new Command<Void>() {
public Void execute(CommandContext commandContext) {
final List<EventSubscription> subscriptions = new EventSubscriptionQueryImpl(commandContext).list();
for (EventSubscription eventSubscriptionEntity : subscriptions) {
((EventSubscriptionEntity) eventSubscriptionEntity).delete();
}
return null;
}