class AAIDeleteTasks {

    public void deleteNetwork(BuildingBlockExecution execution) throws Exception {
        try {
            L3Network l3network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID);
            aaiNetworkResources.deleteNetwork(l3network);
            execution.setVariable("isRollbackNeeded", true);
        } catch (Exception ex) {
            logger.error("Exception occurred in AAIDeleteTasks deleteNetwork process", ex);
            exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
        }
    }

}