Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 11: * Update tracker: IGNORE, no Bug-Url found * Set MODIFIED::IGNORE, no Bug-Url found. -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 11 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has submitted this change and it was merged. Change subject: monitor: Convert valid to read-only property .. monitor: Convert valid to read-only property Status.valid was a duplicate of Status.error. This could lead to inconsistent state if one of the attributes is not synced with the other. Now valid is a property based on Status.error. Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Signed-off-by: Nir Soffer Reviewed-on: https://gerrit.ovirt.org/39088 Reviewed-by: Liron Aravot Continuous-Integration: Jenkins CI --- M tests/storageMonitorTests.py M vdsm/storage/monitor.py 2 files changed, 21 insertions(+), 3 deletions(-) Approvals: Nir Soffer: Verified; Looks good to me, approved Jenkins CI: Passed CI tests Liron Aravot: Looks good to me, but someone else must approve -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 11 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 10: Verified+1 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 10 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 10: Code-Review+2 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 10 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 10: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 10 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 6: Continuous-Integration+1 Jenkins failed to build this after rebase - ignoring it. -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 6: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 5: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Liron Aravot has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 4: -Continuous-Integration -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 4: Continuous-Integration+1 Jenkins failed to run the tests, ignoring it. -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 4: This version updates the tests, addressing Liron comments. -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 4: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: (1 comment) https://gerrit.ovirt.org/#/c/39088/3/tests/storageMonitorTests.py File tests/storageMonitorTests.py: Line 41: def test_deleting_attribute_raises(self): Line 42: for name in self.status.__slots__: Line 43: self.assertRaises(AssertionError, delattr, self.frozen, name) Line 44: Line 45: def test_valid(self): > ok, so it seems that what we should verify here is that frozen.valid equals Yes, that would be even better. Line 46: self.assertTrue(self.frozen.valid) Line 47: Line 48: Line 49: class StatusValidTests(VdsmTestCase): -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Liron Aravot has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: (1 comment) https://gerrit.ovirt.org/#/c/39088/3/tests/storageMonitorTests.py File tests/storageMonitorTests.py: Line 41: def test_deleting_attribute_raises(self): Line 42: for name in self.status.__slots__: Line 43: self.assertRaises(AssertionError, delattr, self.frozen, name) Line 44: Line 45: def test_valid(self): > valid is a property, so copying values is not related. This verify that it ok, so it seems that what we should verify here is that frozen.valid equals to status.valid Line 46: self.assertTrue(self.frozen.valid) Line 47: Line 48: Line 49: class StatusValidTests(VdsmTestCase): -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: (2 comments) https://gerrit.ovirt.org/#/c/39088/3/tests/storageMonitorTests.py File tests/storageMonitorTests.py: Line 41: def test_deleting_attribute_raises(self): Line 42: for name in self.status.__slots__: Line 43: self.assertRaises(AssertionError, delattr, self.frozen, name) Line 44: Line 45: def test_valid(self): > I don't see how this test is needed, the FrozenStatusTests is about making valid is a property, so copying values is not related. This verify that it works for frozen status, so if we change frozen status implementation, we know we did not broke it. Line 46: self.assertTrue(self.frozen.valid) Line 47: Line 48: Line 49: class StatusValidTests(VdsmTestCase): Line 49: class StatusValidTests(VdsmTestCase): Line 50: Line 51: def test_valid(self): Line 52: s = monitor.Status() Line 53: self.assertTrue(s.valid) > lets add assertion that verifies that error is None OK Line 54: Line 55: def test_invalid(self): Line 56: s = monitor.Status() Line 57: s.error = Exception() -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Liron Aravot has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: Code-Review-1 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Liron Aravot has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: (2 comments) https://gerrit.ovirt.org/#/c/39088/3/tests/storageMonitorTests.py File tests/storageMonitorTests.py: Line 41: def test_deleting_attribute_raises(self): Line 42: for name in self.status.__slots__: Line 43: self.assertRaises(AssertionError, delattr, self.frozen, name) Line 44: Line 45: def test_valid(self): I don't see how this test is needed, the FrozenStatusTests is about making sure that the FrozenStatus is created properly. The frozen attribute will be checked with the rest of the attributes in test_copy_attributes Line 46: self.assertTrue(self.frozen.valid) Line 47: Line 48: Line 49: class StatusValidTests(VdsmTestCase): Line 49: class StatusValidTests(VdsmTestCase): Line 50: Line 51: def test_valid(self): Line 52: s = monitor.Status() Line 53: self.assertTrue(s.valid) lets add assertion that verifies that error is None Line 54: Line 55: def test_invalid(self): Line 56: s = monitor.Status() Line 57: s.error = Exception() -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 3: * Update tracker: IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has restored this change. Change subject: monitor: Convert valid to read-only property .. Restored -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: restore Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
gerrit-hooks has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 2: * Update tracker: IGNORE, no Bug-Url found -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Jenkins CI RO has abandoned this change. Change subject: monitor: Convert valid to read-only property .. Abandoned Abandoned due to no activity - please restore if still relevant -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: abandon Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Jenkins CI RO has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 2: Abandoned due to no activity - please restore if still relevant -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Jenkins CI RO Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: gerrit-hooks Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
automat...@ovirt.org has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 2: * Update tracker::IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Candace Sheremeta Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: automat...@ovirt.org Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 2: Verified+1 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Candace Sheremeta Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: automat...@ovirt.org Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
oVirt Jenkins CI Server has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 1: Build Successful http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/17082/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/17256/ : SUCCESS -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Candace Sheremeta Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
oVirt Jenkins CI Server has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 1: Build Started (2/2) -> http://jenkins.ovirt.org/job/vdsm_master_unit-tests_created/17256/ -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Candace Sheremeta Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Ala Hino has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: Adam Litke Gerrit-Reviewer: Ala Hino Gerrit-Reviewer: Allon Mureinik Gerrit-Reviewer: Candace Sheremeta Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Freddy Rolland Gerrit-Reviewer: Liron Aravot Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
oVirt Jenkins CI Server has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 1: Build Started (1/2) -> http://jenkins.ovirt.org/job/vdsm_master_pep8_gerrit/17082/ -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
automat...@ovirt.org has posted comments on this change. Change subject: monitor: Convert valid to read-only property .. Patch Set 1: * Update tracker::IGNORE, no Bug-Url found * Check Bug-Url::WARN, no bug url found, make sure header matches 'Bug-Url: ' and is a valid url. * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.5', 'ovirt-3.4', 'ovirt-3.3']) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer Gerrit-Reviewer: automat...@ovirt.org Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: monitor: Convert valid to read-only property
Nir Soffer has uploaded a new change for review. Change subject: monitor: Convert valid to read-only property .. monitor: Convert valid to read-only property Status.valid was a duplicate of Status.error. This could lead to inconsistent state if one of the attributes is not synced with the other. Now valid is a property based on Status.error. Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Signed-off-by: Nir Soffer --- M tests/storageMonitorTests.py M vdsm/storage/monitor.py 2 files changed, 20 insertions(+), 3 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/88/39088/1 diff --git a/tests/storageMonitorTests.py b/tests/storageMonitorTests.py index bbd152f..9518239 100644 --- a/tests/storageMonitorTests.py +++ b/tests/storageMonitorTests.py @@ -41,3 +41,18 @@ def test_deleting_attribute_raises(self): for name in self.status.__slots__: self.assertRaises(AssertionError, delattr, self.frozen, name) + +def test_valid(self): +self.assertTrue(self.frozen.valid) + + +class StatusValidTests(VdsmTestCase): + +def test_valid(self): +s = monitor.Status() +self.assertTrue(s.valid) + +def test_invalid(self): +s = monitor.Status() +s.error = Exception() +self.assertFalse(s.valid) diff --git a/vdsm/storage/monitor.py b/vdsm/storage/monitor.py index 053897b..6aea29b 100644 --- a/vdsm/storage/monitor.py +++ b/vdsm/storage/monitor.py @@ -33,7 +33,7 @@ class Status(object): __slots__ = ( -"error", "checkTime", "valid", "readDelay", "masterMounted", +"error", "checkTime", "readDelay", "masterMounted", "masterValid", "diskUtilization", "vgMdUtilization", "vgMdHasEnoughFreeSpace", "vgMdFreeBelowThreashold", "hasHostId", "isoPrefix", "version", "actual", @@ -43,7 +43,6 @@ self.actual = actual self.error = None self.checkTime = time.time() -self.valid = True self.readDelay = 0 self.diskUtilization = (None, None) self.masterMounted = False @@ -61,6 +60,10 @@ # report its prefix (it might be unreachable). self.isoPrefix = None self.version = -1 + +@property +def valid(self): +return self.error is None class FrozenStatus(Status): @@ -250,7 +253,6 @@ nextStatus.error = e nextStatus.checkTime = time.time() -nextStatus.valid = (nextStatus.error is None) if self._statusDidChange(nextStatus): self._notifyStatusChanges(nextStatus) -- To view, visit https://gerrit.ovirt.org/39088 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iff27081041bbaa1e319539df67abb31f38367e7d Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Nir Soffer ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches