{ repository.deleteAll(); } @EventHandler public void on(TransferRequestStarted event) { var data = new TransferRequestDataModel(); data.setTransferRequestId(event.transferRequestId().asString()); data.setStatus(TransferRequestStatus.CREATED); repository.save(data); } }