Search in sources :

Example 1 with EvalInstanceExpirationRegistryTask

use of org.bf2.srs.fleetmanager.execution.impl.tasks.deprovision.EvalInstanceExpirationRegistryTask in project srs-fleet-manager by bf2fc6cc711aee1a0c2a.

the class EvalInstanceExpirationRegistryWorker method execute.

@Transactional
@Override
public void execute(Task aTask, WorkerContext ctx) {
    EvalInstanceExpirationRegistryTask task = (EvalInstanceExpirationRegistryTask) aTask;
    // Nothing to do, the heavy lifting is done by the deprovisioning task.
    log.debug("Initiating deprovisioning of an eval instance, registry id = '{}'", task.getRegistryId());
    ctx.delay(() -> tasks.submit(DeprovisionRegistryTask.builder().registryId(task.getRegistryId()).build()));
}
Also used : EvalInstanceExpirationRegistryTask(org.bf2.srs.fleetmanager.execution.impl.tasks.deprovision.EvalInstanceExpirationRegistryTask) Transactional(javax.transaction.Transactional)

Aggregations

Transactional (javax.transaction.Transactional)1 EvalInstanceExpirationRegistryTask (org.bf2.srs.fleetmanager.execution.impl.tasks.deprovision.EvalInstanceExpirationRegistryTask)1