Change in vdsm[master]: Fixed scratchpad hook's image permissions and virtio device ...

2015-06-27 Thread eedri
Eyal Edri has posted comments on this change.

Change subject: Fixed scratchpad hook's image permissions and virtio device name
..


Patch Set 2: Code-Review+1

Danken,
this patch has a potential of dramatically improving the ci performance, and 
its getting blocked for too long,

What do we need to do to push it forward asap?

-- 
To view, visit https://gerrit.ovirt.org/42573
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I4e0e2b09eddeb020ac380bfb9b5d9be73ce5377b
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Anton Marchukov amarc...@redhat.com
Gerrit-Reviewer: Amador Pahim apa...@redhat.com
Gerrit-Reviewer: Anton Marchukov amarc...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Doron Fediuck dfedi...@redhat.com
Gerrit-Reviewer: Eyal Edri ee...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Shahar Havivi shav...@redhat.com
Gerrit-Reviewer: Wenyi Gao we...@linux.vnet.ibm.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: ceph: Clear all secrets during startup and shutdown

2015-06-27 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: ceph: Clear all secrets during startup and shutdown
..


Patch Set 13: Code-Review+2

-- 
To view, visit https://gerrit.ovirt.org/40968
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I5c5aa36ed752642745b7febc785750b438c102bb
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
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]: ceph: Clear all secrets during startup and shutdown

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: ceph: Clear all secrets during startup and shutdown
..


Patch Set 14:

* Update tracker::IGNORE, no Bug-Url found
* Set MODIFIED::IGNORE, no Bug-Url found.

-- 
To view, visit https://gerrit.ovirt.org/40968
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I5c5aa36ed752642745b7febc785750b438c102bb
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
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]: ceph: Clear only ovirt secrets

2015-06-27 Thread danken
Dan Kenigsberg has submitted this change and it was merged.

Change subject: ceph: Clear only ovirt secrets
..


ceph: Clear only ovirt secrets

When clearing other secrets, unregister only ovirt secrets. This allow
the administrator to add other secrets to libvirt. This is not strictly
needed since we kind of own libvirt, but is more polite.

Change-Id: I8b86bd43a6d33a31ef2ee638a16f46657113316d
Signed-off-by: Nir Soffer nsof...@redhat.com
Reviewed-on: https://gerrit.ovirt.org/41302
Tested-by: Daniel Erez de...@redhat.com
Reviewed-by: Daniel Erez de...@redhat.com
Reviewed-by: Francesco Romani from...@redhat.com
Reviewed-by: Adam Litke ali...@redhat.com
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg dan...@redhat.com
---
M tests/vmSecretTests.py
M vdsm/virt/secret.py
2 files changed, 30 insertions(+), 16 deletions(-)

Approvals:
  Nir Soffer: Verified
  Adam Litke: Looks good to me, but someone else must approve
  Jenkins CI: Passed CI tests
  Daniel Erez: Verified; Looks good to me, but someone else must approve
  Dan Kenigsberg: Looks good to me, approved
  Francesco Romani: Looks good to me, but someone else must approve



-- 
To view, visit https://gerrit.ovirt.org/41302
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8b86bd43a6d33a31ef2ee638a16f46657113316d
Gerrit-PatchSet: 12
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: ceph: Clear only ovirt secrets

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: ceph: Clear only ovirt secrets
..


Patch Set 12:

* Update tracker::IGNORE, no Bug-Url found
* Set MODIFIED::IGNORE, no Bug-Url found.

-- 
To view, visit https://gerrit.ovirt.org/41302
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I8b86bd43a6d33a31ef2ee638a16f46657113316d
Gerrit-PatchSet: 12
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
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]: ceph: Clear all secrets during startup and shutdown

2015-06-27 Thread danken
Dan Kenigsberg has submitted this change and it was merged.

Change subject: ceph: Clear all secrets during startup and shutdown
..


ceph: Clear all secrets during startup and shutdown

Libvirt secrets are needed only when vdsm is connected to engine. To
ensure that we don't leave stale secrets or secrets which are not needed
by the active storage domains, we clear all secrets when the service
starting or stopping. Engine will register the required secrets when
connecting to the host or when activating or deactivating storage
domains.

Change-Id: I5c5aa36ed752642745b7febc785750b438c102bb
Signed-off-by: Nir Soffer nsof...@redhat.com
Reviewed-on: https://gerrit.ovirt.org/40968
Reviewed-by: Daniel Erez de...@redhat.com
Tested-by: Daniel Erez de...@redhat.com
Reviewed-by: Francesco Romani from...@redhat.com
Reviewed-by: Adam Litke ali...@redhat.com
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg dan...@redhat.com
---
M tests/vmSecretTests.py
M vdsm/clientIF.py
M vdsm/virt/secret.py
3 files changed, 42 insertions(+), 0 deletions(-)

Approvals:
  Adam Litke: Looks good to me, but someone else must approve
  Nir Soffer: Verified
  Jenkins CI: Passed CI tests
  Daniel Erez: Verified; Looks good to me, but someone else must approve
  Dan Kenigsberg: Looks good to me, approved
  Francesco Romani: Looks good to me, but someone else must approve



-- 
To view, visit https://gerrit.ovirt.org/40968
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5c5aa36ed752642745b7febc785750b438c102bb
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: ceph: Clear only ovirt secrets

2015-06-27 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: ceph: Clear only ovirt secrets
..


Patch Set 11: Code-Review+2

-- 
To view, visit https://gerrit.ovirt.org/41302
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I8b86bd43a6d33a31ef2ee638a16f46657113316d
Gerrit-PatchSet: 11
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Daniel Erez de...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Francesco Romani from...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
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]: rwlock: Support timed acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support timed acquire
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42909
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Idd9b11452d74b566b8989f41244f2d0534327214
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: rwlock: Add simpler RWLock

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Add simpler RWLock
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42908
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I2466c137c89598772fb46347eb02195916883cac
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: concurrent: Add CountedEvent class

2015-06-27 Thread nsoffer
Nir Soffer has uploaded a new change for review.

Change subject: concurrent: Add CountedEvent class
..

concurrent: Add CountedEvent class

CountedEvent is like a threading.Event, but it notifies waiters only
after it was set multiple times.

CountedEvent is useful for waiting until multiple threads are ready.
Currently we are synchronizing multiple threads in the tests using
timeouts, which make the tests slower and break randomly on overloaded
CI slaves.

Change-Id: I68525e18f6b3774d7e10af1226a7bc3404c68ae9
Signed-off-by: Nir Soffer nsof...@redhat.com
---
M lib/vdsm/concurrent.py
M tests/concurrentTests.py
2 files changed, 79 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/27/42927/1

diff --git a/lib/vdsm/concurrent.py b/lib/vdsm/concurrent.py
index 3865873..20d0e09 100644
--- a/lib/vdsm/concurrent.py
+++ b/lib/vdsm/concurrent.py
@@ -21,6 +21,51 @@
 from __future__ import absolute_import
 import threading
 from collections import namedtuple
+from . import utils
+
+
+class Timeout(Exception):
+ Raised when operation timedout 
+
+
+class CountedEvent(object):
+
+An Event like object that notify waiters only after it was set multiple
+times.
+
+Typical usage:
+
+ready = CountedEvent(5)
+
+def thread():
+ready.set()
+
+for i in range(5):
+threading.Thread(target=thread).start()
+
+# Will block until all 5 threads invoke ready.set()
+ready.wait()
+
+
+
+def __init__(self, count):
+self._count = count
+self._cond = threading.Condition(threading.Lock())
+
+def set(self):
+with self._cond:
+self._count -= 1
+if self._count = 0:
+self._cond.notify_all()
+
+def wait(self, timeout):
+deadline = utils.monotonic_time() + timeout
+with self._cond:
+while self._count  0:
+now = utils.monotonic_time()
+if now = deadline:
+raise Timeout(Timeout waiting for counted event)
+self._cond.wait(deadline - now)
 
 
 Result = namedtuple(Result, [succeeded, value])
diff --git a/tests/concurrentTests.py b/tests/concurrentTests.py
index 307e397..6bd6496 100644
--- a/tests/concurrentTests.py
+++ b/tests/concurrentTests.py
@@ -20,12 +20,46 @@
 
 import time
 import random
+import threading
 
 from testlib import VdsmTestCase
+from testValidation import slowtest
 
 from vdsm import concurrent
 
 
+class CountedEventTests(VdsmTestCase):
+
+def test_wait_until_set_multiple_times(self):
+event = concurrent.CountedEvent(2)
+self.assertRaises(concurrent.Timeout, event.wait, 0.0)
+event.set()
+self.assertRaises(concurrent.Timeout, event.wait, 0.0)
+event.set()
+event.wait(0)
+
+@slowtest
+def test_timeout(self):
+event = concurrent.CountedEvent(1)
+with self.assertElapsed(1.0, tolerance=0.5):
+self.assertRaises(concurrent.Timeout, event.wait, 1.0)
+
+def test_wait_for_multiple_threads(self):
+count = 5
+event = concurrent.CountedEvent(count)
+threads = []
+try:
+for i in range(count):
+t = threading.Thread(target=event.set)
+t.daemon = True
+t.start()
+threads.append(t)
+event.wait(2)
+finally:
+for t in threads:
+t.join()
+
+
 class TMapTests(VdsmTestCase):
 
 def test_results(self):


-- 
To view, visit https://gerrit.ovirt.org/42927
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I68525e18f6b3774d7e10af1226a7bc3404c68ae9
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: tests: Add RWLock tests

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: tests: Add RWLock tests
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42907
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If404f0e8c68fcdb2f7643bdd6d5c1f97f230a227
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: concurrent: Add CountedEvent class

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: concurrent: Add CountedEvent class
..


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/42927
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I68525e18f6b3774d7e10af1226a7bc3404c68ae9
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
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]: tests: Add RWLock tests

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: tests: Add RWLock tests
..


Patch Set 4: Verified+1

-- 
To view, visit https://gerrit.ovirt.org/42907
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If404f0e8c68fcdb2f7643bdd6d5c1f97f230a227
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: concurrent: Add CountedEvent class

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: concurrent: Add CountedEvent class
..


Patch Set 1: Verified+1

-- 
To view, visit https://gerrit.ovirt.org/42927
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I68525e18f6b3774d7e10af1226a7bc3404c68ae9
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: rwlock: Support non-blocking acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support non-blocking acquire
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42928
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iec721a07087349050bfe9aa11aacf3be9695fb85
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
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]: Live Merge: Prevent merge when base volume is too small

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: Live Merge: Prevent merge when base volume is too small
..


Patch Set 1:

(1 comment)

https://gerrit.ovirt.org/#/c/42836/1/vdsm/virt/vm.py
File vdsm/virt/vm.py:

Line 4686: # plus a bit more to accommodate additional writes to 'top' 
during the
Line 4687: # live merge operation.
Line 4688: if drive.chunked:
Line 4689: capacity, alloc, physical = self._getExtendInfo(drive)
Line 4690: topAllocSize = int(topInfo['apparentsize'])
 Because we collect topInfo in all cases and the libvirt info is only availa
ok
Line 4691: self.extendDriveVolume(drive, baseVolUUID, topAllocSize, 
capacity)
Line 4692: 
Line 4693: # Trigger the collection of stats before returning so that 
callers
Line 4694: # of getVmStats after this returns will see the new job


-- 
To view, visit https://gerrit.ovirt.org/42836
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ibf77a7c5108b500c6ec34653ef7570a841def1b4
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Greg Padgett gpadg...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Liron Aravot lara...@redhat.com
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Live merge: Update base size after live merge

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: Live merge: Update base size after live merge
..


Patch Set 2:

(3 comments)

https://gerrit.ovirt.org/#/c/42921/2/vdsm/virt/vm.py
File vdsm/virt/vm.py:

Line 4928: # we are removing, the size of the top volume might be 
larger than the
Line 4929: # size of the base volume.  In that case libvirt has 
enlarged the base
Line 4930: # volume automatically as part of the blockCommit operation. 
 Update
Line 4931: # our metadata to reflect this change.
Line 4932: topVolUUID = self.job['topVolume']
Lets add also baseVolUUID temporary, which will make _setVolumeSize() little 
more clear and the code will be more consistent.
Line 4933: info = self.vm._getVolumeInfo(self.drive.domainID, 
self.drive.poolID,
Line 4934:   self.drive.imageID, topVolUUID)
Line 4935: self.vm._setVolumeSize(self.drive.domainID, 
self.drive.poolID,
Line 4936:self.drive.imageID, 
self.job['baseVolume'],


Line 4929: # size of the base volume.  In that case libvirt has 
enlarged the base
Line 4930: # volume automatically as part of the blockCommit operation. 
 Update
Line 4931: # our metadata to reflect this change.
Line 4932: topVolUUID = self.job['topVolume']
Line 4933: info = self.vm._getVolumeInfo(self.drive.domainID, 
self.drive.poolID,
Lets call it topVolInfo, to make it more clear that we copy the capacity from 
the top volume to the base volume.
Line 4934:   self.drive.imageID, topVolUUID)
Line 4935: self.vm._setVolumeSize(self.drive.domainID, 
self.drive.poolID,
Line 4936:self.drive.imageID, 
self.job['baseVolume'],
Line 4937:info['capacity'])


Line 4996: else:
Line 4997: self.vm.log.error(Bad volume chain found for drive 
%s. 
Line 4998:   Previous chain: %s, Expected 
chain: %s, 
Line 4999:   Actual chain: %s, alias, 
origVols,
Line 5000:   expectedVols, curVols)
This fix is not related to this patch - right? Can you separate it to another 
patch?
Line 5001: raise RuntimeError(Bad volume chain found)
Line 5002: 
Line 5003: 
Line 5004: def _devicesWithAlias(domXML):


-- 
To view, visit https://gerrit.ovirt.org/42921
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iae354de36db63ae3bf4b4fc7f72df5e306035784
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: rwlock: Support non-blocking acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support non-blocking acquire
..


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/42928
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iec721a07087349050bfe9aa11aacf3be9695fb85
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Jenkins CI
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]: rwlock: Support timed acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support timed acquire
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42909
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Idd9b11452d74b566b8989f41244f2d0534327214
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: tests: Add RWLock tests

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: tests: Add RWLock tests
..


Patch Set 3:

(1 comment)

Thanks for the review Adam! I will explore removing the fragile sleeps where we 
can.

https://gerrit.ovirt.org/#/c/42907/3/tests/rwlock_test.py
File tests/rwlock_test.py:

Line 34: def test_concurrent_readers(self):
Line 35: lock = RWLock()
Line 36: readers = []
Line 37: log = []
Line 38: with self.assertElapsed(0.1, 0.1):
 But this test could take a little longer on a loaded system which would cau
This is why this tests is marked as @slowtest - these tests are disable in the 
ci. But it will be nice to replace the fragile timeouts, I will try this 
direction.
Line 39: for i in range(5):
Line 40: t = start_thread(reader, lock, log, hold=0.1)
Line 41: readers.append(t)
Line 42: for t in readers:


-- 
To view, visit https://gerrit.ovirt.org/42907
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If404f0e8c68fcdb2f7643bdd6d5c1f97f230a227
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: rwlock: Support timed acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support timed acquire
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42909
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Idd9b11452d74b566b8989f41244f2d0534327214
Gerrit-PatchSet: 6
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: tests: Add RWLock tests

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: tests: Add RWLock tests
..


Patch Set 3:

(1 comment)

https://gerrit.ovirt.org/#/c/42907/3/tests/rwlock_test.py
File tests/rwlock_test.py:

Line 34: def test_concurrent_readers(self):
Line 35: lock = RWLock()
Line 36: readers = []
Line 37: log = []
Line 38: with self.assertElapsed(0.1, 0.1):
 This is why this tests is marked as @slowtest - these tests are disable in 
Version 4 removes some of the fragile waits using events, eliminating @slowtest 
for some tests.

We still need to wait when we want to check that a blocked thread is woke up. 
Instead of sleeping, we use Event.wait(timeout) to ensure that a thread is 
block on the lock.

I'm using now bigger timeouts so these tests should (practically) never fail.

In the next patches adding non-blocking or timed  acquire, some more waits are 
replaces with non-blocking acquire.

Please review again the latest versions of this series.
Line 39: for i in range(5):
Line 40: t = start_thread(reader, lock, log, hold=0.1)
Line 41: readers.append(t)
Line 42: for t in readers:


-- 
To view, visit https://gerrit.ovirt.org/42907
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If404f0e8c68fcdb2f7643bdd6d5c1f97f230a227
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: tests: Add basic tests for RWLock

2015-06-27 Thread nsoffer
Nir Soffer has posted comments on this change.

Change subject: tests: Add basic tests for RWLock
..


Patch Set 1:

(3 comments)

https://gerrit.ovirt.org/#/c/42772/1/tests/miscTests.py
File tests/miscTests.py:

Line 1274: 
Line 1275: def test_multiple_acquire(self):
Line 1276: lock = misc.RWLock()
Line 1277: self.assertTrue(lock.acquire(exclusive=True))
Line 1278: self.assertTrue(lock.acquire(exclusive=True))
I don't think these tests are correct without the next patch - lock.acquire() 
returns always None.
Line 1279: 
Line 1280: def test_demote(self):
Line 1281: lock = misc.RWLock()
Line 1282: self.assertTrue(lock.acquire(exclusive=True))


Line 1279: 
Line 1280: def test_demote(self):
Line 1281: lock = misc.RWLock()
Line 1282: self.assertTrue(lock.acquire(exclusive=True))
Line 1283: self.assertTrue(lock.acquire(exclusive=False))
Same
Line 1284: 
Line 1285: def test_promote(self):
Line 1286: lock = misc.RWLock()
Line 1287: self.assertTrue(lock.acquire(False))


Line 1283: self.assertTrue(lock.acquire(exclusive=False))
Line 1284: 
Line 1285: def test_promote(self):
Line 1286: lock = misc.RWLock()
Line 1287: self.assertTrue(lock.acquire(False))
Same


-- 
To view, visit https://gerrit.ovirt.org/42772
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I77b9ea1cd6d378738fbf14de119c88bf0ebc94e2
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: rwlock: Support non-blocking acquire

2015-06-27 Thread nsoffer
Nir Soffer has uploaded a new change for review.

Change subject: rwlock: Support non-blocking acquire
..

rwlock: Support non-blocking acquire

This patch adds non-blocking acquire suggested in
https://gerrit.ovirt.org/42773. This is a simpler alternative to timed
acquire, suggested in https://gerrit.ovirt.org/42909.

Change-Id: Iec721a07087349050bfe9aa11aacf3be9695fb85
Signed-off-by: Nir Soffer nsof...@redhat.com
---
M lib/vdsm/rwlock.py
M tests/rwlock_test.py
2 files changed, 30 insertions(+), 48 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/28/42928/1

diff --git a/lib/vdsm/rwlock.py b/lib/vdsm/rwlock.py
index c6ce1ea..2281851 100644
--- a/lib/vdsm/rwlock.py
+++ b/lib/vdsm/rwlock.py
@@ -32,17 +32,23 @@
 self._readers = set()
 self._writer = None
 
-def acquireWrite(self):
+def acquireWrite(self, block=True):
 with self._lock:
 if self._writer or self._readers or self._waiters:
+if not block:
+return False
 self._wait(True)
 self._writer = threading.current_thread()
+return True
 
-def acquireRead(self):
+def acquireRead(self, block=True):
 with self._lock:
 if self._writer or self._waiters:
+if not block:
+return False
 self._wait(False)
 self._readers.add(threading.current_thread())
+return True
 
 def release(self):
 me = threading.current_thread()
diff --git a/tests/rwlock_test.py b/tests/rwlock_test.py
index 1c28f26..7ef5aa6 100644
--- a/tests/rwlock_test.py
+++ b/tests/rwlock_test.py
@@ -121,54 +121,30 @@
 for t in threads:
 t.stop()
 
-@slowtest
-def test_shared_context_blocks_writer(self):
-lock = RWLock()
-writer = RWThread(lock.exclusive)
-try:
-with lock.shared:
-writer.start()
-if not writer.ready.wait(2):
-raise RuntimeError(Timeout waiting for writer thread)
-# Writer must block
-self.assertFalse(writer.acquired.wait(1))
-finally:
-writer.stop()
-
-def test_shared_context_allows_reader(self):
-lock = RWLock()
-with lock.shared:
-reader = RWThread(lock.shared)
-with utils.running(reader):
-self.assertTrue(reader.acquired.wait(1))
-
-@slowtest
-def test_exclusive_context_blocks_writer(self):
-lock = RWLock()
-writer = RWThread(lock.exclusive)
-try:
-with lock.exclusive:
-writer.start()
-if not writer.ready.wait(2):
-raise RuntimeError(Timeout waiting for writer thread)
-# Reader must block
-self.assertFalse(writer.acquired.wait(1))
-finally:
-writer.stop()
-
-@slowtest
-def test_exclusive_context_blocks_reader(self):
+def test_reader_blocks_writer(self):
 lock = RWLock()
 reader = RWThread(lock.shared)
-try:
-with lock.exclusive:
-reader.start()
-if not reader.ready.wait(2):
-raise RuntimeError(Timeout waiting for reader thread)
-# Reader must block
-self.assertFalse(reader.acquired.wait(1))
-finally:
-reader.stop()
+with utils.running(reader):
+if not reader.acquired.wait(2):
+raise RuntimeError(Timeout waiting for reader thread)
+self.assertFalse(lock.acquireWrite(block=False))
+
+def test_writer_blocks_writer(self):
+lock = RWLock()
+writer = RWThread(lock.exclusive)
+with utils.running(writer):
+if not writer.acquired.wait(2):
+raise RuntimeError(Timeout waiting for writer thread)
+self.assertFalse(lock.acquireWrite(block=False))
+
+
+def test_writer_blocks_reader(self):
+lock = RWLock()
+writer = RWThread(lock.exclusive)
+with utils.running(writer):
+if not writer.acquired.wait(2):
+raise RuntimeError(Timeout waiting for writer thread)
+self.assertFalse(lock.acquireRead(block=False))
 
 
 @expandPermutations


-- 
To view, visit https://gerrit.ovirt.org/42928
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iec721a07087349050bfe9aa11aacf3be9695fb85
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: rwlock: Support timed acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support timed acquire
..


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.5', 
'ovirt-3.4', 'ovirt-3.3'])

-- 
To view, visit https://gerrit.ovirt.org/42909
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Idd9b11452d74b566b8989f41244f2d0534327214
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
Gerrit-Reviewer: Adam Litke ali...@redhat.com
Gerrit-Reviewer: Ala Hino ah...@redhat.com
Gerrit-Reviewer: Allon Mureinik amure...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Dima Kuznetsov dkuzn...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Freddy Rolland froll...@redhat.com
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: rwlock: Support non-blocking acquire

2015-06-27 Thread automation
automat...@ovirt.org has posted comments on this change.

Change subject: rwlock: Support non-blocking acquire
..


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/42928
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iec721a07087349050bfe9aa11aacf3be9695fb85
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer nsof...@redhat.com
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