Change in vdsm[master]: API: remove now-useless _getStats method
by Code Review
From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has posted comments on this change.
Change subject: API: remove now-useless _getStats method
......................................................................
Patch Set 1:
Francesco, could you remind me which commit dropped the non-default usage of runHooks?
--
To view, visit https://gerrit.ovirt.org/66019
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Iea6d215f2e1318c06741da44e7092ccff1c4e52f
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Irit Goihman <igoihman(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski(a)gmail.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>
Gerrit-HasComments: No
7 years, 4 months
Change in vdsm[master]: net: acquire ifcfg files to be used by VDSM - refactoring
by Code Review
From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has posted comments on this change.
Change subject: net: acquire ifcfg files to be used by VDSM - refactoring
......................................................................
Patch Set 4:
(1 comment)
https://gerrit.ovirt.org/#/c/65996/4/lib/vdsm/network/configurators/ifcfg.py
File lib/vdsm/network/configurators/ifcfg.py:
Line 343: def _collect_device_files(device):
Line 344: device_files = []
Line 345: paths = glob.iglob(NET_CONF_PREF + '*')
Line 346: for ifcfg_file in paths:
Line 347: with open(ifcfg_file) as f:
I should have asked this long ago, but why don't we use getIfaceCfg from netinfo.misc ?
Line 348: for line in f:
Line 349: if len(line) < 2 and line.startswith('#'):
Line 350: continue
Line 351: key, value = line.rstrip().split('=', 1)
--
To view, visit https://gerrit.ovirt.org/65996
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ieeac4075fbb3869a99e94de04953a5ade0db26ef
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Edward Haas <edwardh(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Petr Horáček <phoracek(a)redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>
Gerrit-HasComments: Yes
7 years, 4 months
Change in vdsm[master]: migration: use system thread names
by fromani@redhat.com
Francesco Romani has uploaded a new change for review.
Change subject: migration: use system thread names
......................................................................
migration: use system thread names
Add migration thread names.
Unfortunately, we need to shorten 'migration' - which is going to
eat 10 out of 15 ASCII chars available for the name.
https://bugzilla.redhat.com/1141422
Change-Id: Ie03f19f75cb9430cd3a267817df269df776fa6a3
Signed-off-by: Francesco Romani <fromani(a)redhat.com>
---
M vdsm/virt/migration.py
1 file changed, 3 insertions(+), 3 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/03/65503/1
diff --git a/vdsm/virt/migration.py b/vdsm/virt/migration.py
index ea43174..8a254c8 100644
--- a/vdsm/virt/migration.py
+++ b/vdsm/virt/migration.py
@@ -125,7 +125,7 @@
'code': 0,
'message': 'Migration in progress'}}
self._progress = 0
- self._thread = concurrent.thread(self.run)
+ self._thread = concurrent.thread(self.run, name='migr/source')
self._preparingMigrationEvt = True
self._migrationCanceledEvt = threading.Event()
self._monitorThread = None
@@ -556,7 +556,7 @@
# we need the first value to support set_initial_downtime
self._initial_downtime = next(self._downtimes)
- self._thread = concurrent.thread(self.run)
+ self._thread = concurrent.thread(self.run, name='migr/downtime')
def start(self):
self._thread.start()
@@ -622,7 +622,7 @@
self._conv_schedule = conv_schedule
self._use_conv_schedule = use_conv_schedule
self.downtime_thread = _FakeThreadInterface()
- self._thread = concurrent.thread(self.run)
+ self._thread = concurrent.thread(self.run, name='migr/monitor')
self._log = vm.get_logger(self._raw_log)
def start(self):
--
To view, visit https://gerrit.ovirt.org/65503
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie03f19f75cb9430cd3a267817df269df776fa6a3
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani(a)redhat.com>
7 years, 4 months
Change in vdsm[master]: build: use tox's python during `make check`
by Code Review
From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has uploaded a new change for review.
Change subject: build: use tox's python during `make check`
......................................................................
build: use tox's python during `make check`
This commit
- simplifies run_tests*.sh to use python2 from the PATH created by
tox
- requests tox to inherite site packages already pulled via RPMs
- reverts commit 2165bd0a399bbff as there is no longer need to pull nose
RPM
Change-Id: Icae1ab07ed1fb542359348ff8064ba75e92cc672
---
M automation/check-merged.packages.el7
M automation/check-merged.packages.fc24
M automation/check-patch.packages.el7
M automation/check-patch.packages.fc24
M tests/run_tests.sh.in
M tests/run_tests_local.sh.in
M tox.ini
7 files changed, 3 insertions(+), 6 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/99/65999/1
diff --git a/automation/check-merged.packages.el7 b/automation/check-merged.packages.el7
index 44bf93a..1c43150 100644
--- a/automation/check-merged.packages.el7
+++ b/automation/check-merged.packages.el7
@@ -17,7 +17,6 @@
python-ioprocess
python-mock
python-netaddr
-python-nose
python-pthreading
python-rtslib
python-six
diff --git a/automation/check-merged.packages.fc24 b/automation/check-merged.packages.fc24
index 52d1dcf..83cccaa 100644
--- a/automation/check-merged.packages.fc24
+++ b/automation/check-merged.packages.fc24
@@ -21,7 +21,6 @@
python-ioprocess
python-mock
python-netaddr
-python-nose
python-pthreading
python-rtslib
python-six
diff --git a/automation/check-patch.packages.el7 b/automation/check-patch.packages.el7
index 90f8f37..35151e4 100644
--- a/automation/check-patch.packages.el7
+++ b/automation/check-patch.packages.el7
@@ -18,7 +18,6 @@
python-ioprocess
python-mock
python-netaddr
-python-nose
python-pthreading
python-rtslib
python-setuptools
diff --git a/automation/check-patch.packages.fc24 b/automation/check-patch.packages.fc24
index 32482f0..c3817fd 100644
--- a/automation/check-patch.packages.fc24
+++ b/automation/check-patch.packages.fc24
@@ -19,7 +19,6 @@
python-ioprocess
python-mock
python-netaddr
-python-nose
python-pthreading
python-setuptools
python-six
diff --git a/tests/run_tests.sh.in b/tests/run_tests.sh.in
index 5245f4e..5f9a531 100644
--- a/tests/run_tests.sh.in
+++ b/tests/run_tests.sh.in
@@ -1,6 +1,6 @@
#!/bin/sh
if [ -z "$PYTHON_EXE" ]; then
- PYTHON_EXE="@PYTHON@"
+ PYTHON_EXE="python2"
fi
prefix="@prefix@"
diff --git a/tests/run_tests_local.sh.in b/tests/run_tests_local.sh.in
index 9906090..17b8487 100644
--- a/tests/run_tests_local.sh.in
+++ b/tests/run_tests_local.sh.in
@@ -1,6 +1,6 @@
#!/bin/sh
if [ -z "$PYTHON_EXE" ]; then
- PYTHON_EXE="@PYTHON@"
+ PYTHON_EXE="python2"
fi
export \
diff --git a/tox.ini b/tox.ini
index 9511f68..27cf88c 100644
--- a/tox.ini
+++ b/tox.ini
@@ -9,6 +9,7 @@
# TODO: remove this option after the failing tests are fixed.
setenv =
PYTHONHASHSEED = 0
+sitepackages = True
deps =
nose==1.3.7
commands =
--
To view, visit https://gerrit.ovirt.org/65999
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Icae1ab07ed1fb542359348ff8064ba75e92cc672
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Dan Kenigsberg <danken(a)redhat.com>
7 years, 4 months
Change in vdsm[master]: tests: Require python-nose for automation
by Code Review
From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has submitted this change and it was merged.
Change subject: tests: Require python-nose for automation
......................................................................
tests: Require python-nose for automation
In commit 195937c2da59 (build: Disable tests during build) we removed
python-nose requirement, because we install nose using tox. Turns out
that we still need nose, since our testing infrastructure is not using
the virtual environment created by tox, and the nose version we install
with tox is actually unused.
The issue was probably hidden because we merged a patch without rebasing
in and running the tests again.
This patch is only the minimal fix to get the build working again, we
need more work to run the tests using tox virtual environment.
Change-Id: I8e6bfd4c1b06239b640baa13b72a2147ca664b07
Signed-off-by: Nir Soffer <nsoffer(a)redhat.com>
Reviewed-on: https://gerrit.ovirt.org/65986
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg <danken(a)redhat.com>
---
M automation/check-merged.packages.el7
M automation/check-merged.packages.fc24
M automation/check-patch.packages.el7
M automation/check-patch.packages.fc24
4 files changed, 4 insertions(+), 0 deletions(-)
Approvals:
Nir Soffer: Verified
Jenkins CI: Passed CI tests
Dan Kenigsberg: Looks good to me, approved
--
To view, visit https://gerrit.ovirt.org/65986
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I8e6bfd4c1b06239b640baa13b72a2147ca664b07
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>
7 years, 4 months
Change in vdsm[master]: tests: Require python-nose for automation
by Code Review
From Dan Kenigsberg <danken(a)redhat.com>:
Dan Kenigsberg has posted comments on this change.
Change subject: tests: Require python-nose for automation
......................................................................
Patch Set 3: Code-Review+2
--
To view, visit https://gerrit.ovirt.org/65986
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I8e6bfd4c1b06239b640baa13b72a2147ca664b07
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Edward Haas <edwardh(a)redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski(a)gmail.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>
Gerrit-HasComments: No
7 years, 4 months
Change in vdsm[ovirt-4.0]: jsonrpcvdscli: add default value to request queue argument
by Code Review
From Yaniv Bronhaim <ybronhei(a)redhat.com>:
Yaniv Bronhaim has posted comments on this change.
Change subject: jsonrpcvdscli: add default value to request queue argument
......................................................................
Patch Set 1:
do we have a bug for 4.0?
--
To view, visit https://gerrit.ovirt.org/65971
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I226e7a66a06ac6d7ce57f1b2733609b0fd7a4d67
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-4.0
Gerrit-Owner: Jenny Tokar <jtokar(a)redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Irit Goihman <igoihman(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Jenny Tokar <jtokar(a)redhat.com>
Gerrit-Reviewer: Martin Sivák <msivak(a)redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski(a)gmail.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei(a)redhat.com>
Gerrit-HasComments: No
7 years, 4 months
Change in vdsm[master]: tests: Ensure nose 1.3.7 is used for tests
by Nir Soffer
Nir Soffer has uploaded a new change for review.
Change subject: tests: Ensure nose 1.3.7 is used for tests
......................................................................
tests: Ensure nose 1.3.7 is used for tests
Run the tests via tox, installing the correct version of nose in a
virtual environment.
Since correct version is nose is always available, the warning about
nose version is not needed now.
Change-Id: I245a171940a5e869fd719a6410024ee77e8ad86c
Signed-off-by: Nir Soffer <nsoffer(a)redhat.com>
---
M Makefile.am
M automation/check-patch.sh
M tox.ini
3 files changed, 9 insertions(+), 8 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/04/65404/1
diff --git a/Makefile.am b/Makefile.am
index 354c6b3..3b3e11c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -131,12 +131,7 @@
.PHONY: tests
tests:
- @version=`nosetests --version | cut -d' ' -f3`; \
- if build-aux/vercmp $$version "1.3.7"; then \
- echo "Error: NOSE is too old, please install NOSE 1.3.7 or later"; \
- exit 1; \
- fi
- @$(MAKE) -C tests/ check
+ tox -e tests
all-local: \
vdsm.spec
diff --git a/automation/check-patch.sh b/automation/check-patch.sh
index 3284e2b..0877046 100755
--- a/automation/check-patch.sh
+++ b/automation/check-patch.sh
@@ -8,7 +8,7 @@
export VDSM_AUTOMATION=1
easy_install pip
-pip install -U nose==1.3.7 tox==2.1.1
+pip install -U tox==2.1.1
./autogen.sh --system --enable-hooks --enable-vhostmd
diff --git a/tox.ini b/tox.ini
index 8686eb2..fb86cb7 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,7 +1,13 @@
[tox]
-envlist = flake8
+envlist = flake8,tests
skipsdist = true
+[testenv:tests]
+deps =
+ nose==1.3.7
+commands =
+ make -C tests check
+
[testenv:flake8]
deps =
flake8
--
To view, visit https://gerrit.ovirt.org/65404
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I245a171940a5e869fd719a6410024ee77e8ad86c
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer(a)redhat.com>
7 years, 4 months
Change in vdsm[ovirt-4.0]: net: remove default route before adding a new one
by phoracek@redhat.com
Hello Dan Kenigsberg,
I'd like you to do a code review. Please visit
https://gerrit.ovirt.org/65056
to review the following change.
Change subject: net: remove default route before adding a new one
......................................................................
net: remove default route before adding a new one
Change-Id: Ie59c07845898630404ce517e5cc52048e50ed2dd
Signed-off-by: Petr Horáček <phoracek(a)redhat.com>
Reviewed-on: https://gerrit.ovirt.org/63220
Continuous-Integration: Jenkins CI
Reviewed-by: Edward Haas <edwardh(a)redhat.com>
Reviewed-by: Dan Kenigsberg <danken(a)redhat.com>
---
M lib/vdsm/network/ip/address.py
1 file changed, 22 insertions(+), 6 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/56/65056/1
diff --git a/lib/vdsm/network/ip/address.py b/lib/vdsm/network/ip/address.py
index 634925a..04aec93 100644
--- a/lib/vdsm/network/ip/address.py
+++ b/lib/vdsm/network/ip/address.py
@@ -18,6 +18,8 @@
#
from __future__ import absolute_import
+from contextlib import contextmanager
+import logging
import socket
import struct
@@ -173,28 +175,42 @@
def add(iface, ipv4, ipv6):
if ipv4.address:
- ipwrapper.addrAdd(iface, ipv4.address, ipv4.netmask)
- if ipv4.gateway and ipv4.defaultRoute:
- ipwrapper.routeAdd(['default', 'via', ipv4.gateway])
+ _add_ipv4_address(iface, ipv4)
if ipv6:
_add_ipv6_address(iface, ipv6)
elif ipv6_supported():
sysctl.disable_ipv6(iface)
+def _add_ipv4_address(iface, ipv4):
+ ipwrapper.addrAdd(iface, ipv4.address, ipv4.netmask)
+ if ipv4.gateway and ipv4.defaultRoute:
+ _set_default_route(ipv4.gateway, family=4)
+
+
def _add_ipv6_address(iface, ipv6):
if ipv6.address:
ipv6addr, ipv6netmask = ipv6.address.split('/')
ipwrapper.addrAdd(iface, ipv6addr, ipv6netmask, family=6)
- if ipv6.gateway:
- ipwrapper.routeAdd(['default', 'via', ipv6.gateway],
- dev=iface, family=6)
+ if ipv6.gateway and ipv6.defaultRoute:
+ _set_default_route(ipv6.gateway, family=6, dev=iface)
if ipv6.ipv6autoconf is not None:
with open('/proc/sys/net/ipv6/conf/%s/autoconf' % iface,
'w') as ipv6_autoconf:
ipv6_autoconf.write('1' if ipv6.ipv6autoconf else '0')
+@contextmanager
+def _set_default_route(gateway, family, dev=None):
+ try:
+ ipwrapper.routeAdd(['default', 'via', gateway], family=family, dev=dev)
+ except ipwrapper.IPRoute2Error: # there already is a default route
+ logging.warning(
+ 'Existing default route will be removed so a new one can be set.')
+ ipwrapper.routeDel('default', family=family)
+ ipwrapper.routeAdd(['default', 'via', gateway], family=family, dev=dev)
+
+
def flush(iface, family='both'):
ipwrapper.addrFlush(iface, family)
--
To view, visit https://gerrit.ovirt.org/65056
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie59c07845898630404ce517e5cc52048e50ed2dd
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-4.0
Gerrit-Owner: Petr Horáček <phoracek(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
7 years, 4 months