class AAIUpdateTasks {

    public void updateHeatStackIdVfModule(BuildingBlockExecution execution) {
        try {
            String heatStackId = execution.getVariable("heatStackId");
            if (heatStackId == null) {
                heatStackId = "";
            }
            VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID);
            GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID);
            vfModule.setHeatStackId(heatStackId);
            aaiVfModuleResources.updateHeatStackIdVfModule(vfModule, vnf);
        } catch (Exception ex) {
            logger.error("Exception occurred in AAIUpdateTasks updateHeatStackIdVfModule", ex);
            exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
        }
    }

}