Yair Zaslavsky has posted comments on this change. Change subject: core: CompensationContext - add support for updated entity only. ......................................................................
Patch Set 1: (2 comments) http://gerrit.ovirt.org/#/c/25231/1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java File backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java: Line 457: } else { Line 458: daoForEntity.update(entitySnapshot); Line 459: } Line 460: break; Line 461: case UPDATED_ENTITY: please select a different term, its too similar to CHANGED. Line 462: daoForEntity.update((BusinessEntity<Serializable>)snapshotData); Line 463: break; Line 464: case NEW_ENTITY_ID: Line 465: daoForEntity.remove(snapshotData); Line 458: daoForEntity.update(entitySnapshot); Line 459: } Line 460: break; Line 461: case UPDATED_ENTITY: Line 462: daoForEntity.update((BusinessEntity<Serializable>)snapshotData); use case is not clear. I assume that if update is called on the dao , it means that you have the record in db, hence daoForEntity.get(entitySnapshot.getid() will not return null, hence the daoForEntity.update(entitySnapshot) will be called (the case of CHANGED_ENTITY). Line 463: break; Line 464: case NEW_ENTITY_ID: Line 465: daoForEntity.remove(snapshotData); Line 466: break; -- To view, visit http://gerrit.ovirt.org/25231 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I527d8b95b82f76fb4ce0db7e6ec967c23b759524 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Liron Ar <[email protected]> Gerrit-Reviewer: Allon Mureinik <[email protected]> Gerrit-Reviewer: Maor Lipchuk <[email protected]> Gerrit-Reviewer: Tal Nisan <[email protected]> Gerrit-Reviewer: Yair Zaslavsky <[email protected]> Gerrit-Reviewer: [email protected] Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
