Federico Simoncelli has posted comments on this change.
Change subject: core: allow current master domain to be selected as the new
master
......................................................................
Patch Set 7: Code-Review+1
(2 comments)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/storage/ReconstructMasterDomainCommand.java
Line 95: protected boolean reconstructMaster() {
Line 96: proceedStorageDomainTreatmentByDomainType(true);
Line 97:
Line 98: // To issue a reconstructMaster you need to set the domain
inactive unless the selected domain is the current master
Line 99: if (getParameters().isInactive() &&
!getStorageDomain().getId().equals(_newMasterStorageDomainId)) {
We don't mind about the canChooseCurrentMasterAsNewMaster value here?
Line 100: executeInNewTransaction(new TransactionMethod<Void>() {
Line 101: @Override
Line 102: public Void runInTransaction() {
Line 103:
setStorageDomainStatus(StorageDomainStatus.InActive, getCompensationContext());
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/storage/StorageDomainCommandBase.java
Line 320: for (StorageDomain dbStorageDomain : storageDomains) {
Line 321: if ((storageDomain == null || (duringReconstruct
|| !dbStorageDomain.getId()
Line 322: .equals(storageDomain.getId())))
Line 323: &&
((dbStorageDomain.getStorageDomainType() == StorageDomainType.Data)
Line 324: ||
Indentation here is misleading.
Line 325: (canChooseCurrentMasterAsNewMaster &&
dbStorageDomain.getStorageDomainType() == StorageDomainType.Master))) {
Line 326: if (dbStorageDomain.getStatus() ==
StorageDomainStatus.Active
Line 327: || dbStorageDomain.getStatus() ==
StorageDomainStatus.Unknown) {
Line 328: newMaster = dbStorageDomain;
--
To view, visit http://gerrit.ovirt.org/22016
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I705298d4f94b4afacc3ca028bb0a4e6080ac5a46
Gerrit-PatchSet: 7
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Liron Ar <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Federico Simoncelli <[email protected]>
Gerrit-Reviewer: Liron Ar <[email protected]>
Gerrit-Reviewer: Sergey Gotliv <[email protected]>
Gerrit-Reviewer: Tal Nisan <[email protected]>
Gerrit-Reviewer: Vered Volansky <[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