Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-03 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 17: Code-Review+2

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 81: def _editOtherLoggers(self, edit):
Line 82: 
Line 83: add/remove upgrade handler to/from all non-upgrade loggers
Line 84: 
Line 85: loggers = dict(logging.Logger.manager.loggerDict.items() +
Seems like an overkill to me, but let it be.
Line 86:[('root', logging.getLogger())])
Line 87: for name, logger in loggers.iteritems():
Line 88: if name != 'upgrade':
Line 89: for handler in logging.getLogger('upgrade').handlers:


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 17
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-03 Thread danken
Dan Kenigsberg has submitted this change and it was merged.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Unified network persistence [4.1/4.*] - Upgrade mechanism

Unified network persistence feature:
http://www.ovirt.org/Feature/NetworkReloaded#Unified_persistence

This patch is the first of two patches that implement an upgrade
that is run the first time VDSM that uses unified network
persistence is started. The goal is to look at the current
host networking configuration and populate the running
and persistent configurations.

Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Signed-off-by: Assaf Muller amul...@redhat.com
Reviewed-on: http://gerrit.ovirt.org/17726
Reviewed-by: Dan Kenigsberg dan...@redhat.com
---
M debian/vdsm-python.install
M lib/vdsm/tool/Makefile.am
A lib/vdsm/tool/upgrade.py
M vdsm.spec.in
M vdsm/Makefile.am
M vdsm/logger.conf.in
6 files changed, 149 insertions(+), 2 deletions(-)

Approvals:
  Assaf Muller: Verified
  Dan Kenigsberg: Looks good to me, approved



-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 18
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-03 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 18:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_master_install_rpm_sanity_gerrit/77/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 18
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-02 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 16: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5849/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5941/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/5053/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_install_rpm_sanity_gerrit/71/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 16
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-02 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 16:

There's still outstanding comments by Yaniv (I haven't forgotten them).

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 16
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-02 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 15:

(6 comments)


File lib/vdsm/tool/upgrade.py
Line 41: 
Line 42: To get more functionality you may use this module's 'upgrade'
Line 43: decorator. It removes all boilerplate code, makes sure to run
Line 44: the upgrade only if needed and to automatically call 'seal'
Line 45: if no exception was thrown.
Done
Line 46: 
Line 47: def __init__(self, upgradeName):
Line 48: self.upgradeName = upgradeName
Line 49: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,


Line 45: if no exception was thrown.
Line 46: 
Line 47: def __init__(self, upgradeName):
Line 48: self.upgradeName = upgradeName
Line 49: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
Done
Line 50: upgrade, 
self.upgradeName)
Line 51: try:
Line 52: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 53: self.log = logging.getLogger('upgrade')


Line 51: try:
Line 52: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 53: self.log = logging.getLogger('upgrade')
Line 54: except Exception:
Line 55: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Done
Line 56: level=logging.DEBUG)
Line 57: logging.error(Could not init proper logging, 
exc_info=True)
Line 58: self.log = logging
Line 59: 


Line 63: def seal(self):
Line 64: 
Line 65: Mark the upgrade as a success
Line 66: 
Line 67: touchFile(self.upgradeFilePath)
Done
Line 68: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 69: 
Line 70: def __enter__(self):
Line 71: 


Line 73: will still be output to that logger. However, logging done by 
accessing
Line 74: logging directly (Thus using the root logger) will be 
'hijacked'
Line 75: to the Upgrade's log instead.
Line 76: 
Line 77: self.oldRoot = logging.root
New approach implemented in the following patch sets.
Line 78: logging.root = self.log
Line 79: return self
Line 80: 
Line 81: def __exit__(self, type, value, traceback):


Line 91: upgrade.log.debug(Running upgrade %s % 
upgradeName)
Line 92: try:
Line 93: f(*args, **kwargs)
Line 94: except Exception:
Line 95: upgrade.log.exception(Failed to run %s %
Done
Line 96:   upgradeName)
Line 97: return 1
Line 98: else:
Line 99: upgrade.seal()


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 15
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-02 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 17: Verified+1

All outstanding comments handled.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 17
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-02 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 17: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5854/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5947/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/5058/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_install_rpm_sanity_gerrit/73/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 17
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-01 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 15: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5843/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5936/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/5048/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_master_install_rpm_sanity_gerrit/69/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 15
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-01 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 15:

(6 comments)


File lib/vdsm/tool/upgrade.py
Line 41: 
Line 42: To get more functionality you may use this module's 'upgrade'
Line 43: decorator. It removes all boilerplate code, makes sure to run
Line 44: the upgrade only if needed and to automatically call 'seal'
Line 45: if no exception was thrown.
put that part above the decorator imp
Line 46: 
Line 47: def __init__(self, upgradeName):
Line 48: self.upgradeName = upgradeName
Line 49: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,


Line 45: if no exception was thrown.
Line 46: 
Line 47: def __init__(self, upgradeName):
Line 48: self.upgradeName = upgradeName
Line 49: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
privates with underscore
Line 50: upgrade, 
self.upgradeName)
Line 51: try:
Line 52: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 53: self.log = logging.getLogger('upgrade')


Line 51: try:
Line 52: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 53: self.log = logging.getLogger('upgrade')
Line 54: except Exception:
Line 55: logging.basicConfig(filename='/dev/stdout', filemode='w+',
stdout? if its important enough it should be out to syslog imo
Line 56: level=logging.DEBUG)
Line 57: logging.error(Could not init proper logging, 
exc_info=True)
Line 58: self.log = logging
Line 59: 


Line 63: def seal(self):
Line 64: 
Line 65: Mark the upgrade as a success
Line 66: 
Line 67: touchFile(self.upgradeFilePath)
can throws exception. do you need to handle it?
Line 68: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 69: 
Line 70: def __enter__(self):
Line 71: 


Line 73: will still be output to that logger. However, logging done by 
accessing
Line 74: logging directly (Thus using the root logger) will be 
'hijacked'
Line 75: to the Upgrade's log instead.
Line 76: 
Line 77: self.oldRoot = logging.root
im sorry.. i don't understand this part
Line 78: logging.root = self.log
Line 79: return self
Line 80: 
Line 81: def __exit__(self, type, value, traceback):


Line 91: upgrade.log.debug(Running upgrade %s % 
upgradeName)
Line 92: try:
Line 93: f(*args, **kwargs)
Line 94: except Exception:
Line 95: upgrade.log.exception(Failed to run %s %
with , instead of %. same for all log usages
Line 96:   upgradeName)
Line 97: return 1
Line 98: else:
Line 99: upgrade.seal()


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 15
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-01 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 15:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 73: will still be output to that logger. However, logging done by 
accessing
Line 74: logging directly (Thus using the root logger) will be 
'hijacked'
Line 75: to the Upgrade's log instead.
Line 76: 
Line 77: self.oldRoot = logging.root
What I need is for all of the logging done as part of the upgrade to be 
redirected to upgrade.log - That is the end goal. 

For example: the unified persistence upgrade runs code that also runs as part 
of normal VDSM operation. That code uses logging.error/debug(...), which will 
be handled by the root logger and thus log to vdsm.log. During the upgrade I 
want all of that logging that normally goes to vdsm.log to go instead to 
upgrade.log, but only if the code was ran as an upgrade.

The solution I came up with is to hijack logging.root.

This approach has a shortcoming. If code explicitly uses 
logging.getLogger('vds') then I won't see that logging which can be a future 
issue. Ideally I'd want ALL logging (Regardless of the logger used) to be 
redirected to upgrade.log.
Line 78: logging.root = self.log
Line 79: return self
Line 80: 
Line 81: def __exit__(self, type, value, traceback):


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 15
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-12-01 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 15:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 73: will still be output to that logger. However, logging done by 
accessing
Line 74: logging directly (Thus using the root logger) will be 
'hijacked'
Line 75: to the Upgrade's log instead.
Line 76: 
Line 77: self.oldRoot = logging.root
Thinking about this again, it could be possible to use logging.addHandler on 
__enter__ and logging.removeHandler on __exit__. I'll see tomorrow if it works. 
That way everything logged to vdsm.log during an upgrade should ALSO be logged 
to upgrade.log.
Line 78: logging.root = self.log
Line 79: return self
Line 80: 
Line 81: def __exit__(self, type, value, traceback):


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 15
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-24 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 14:

(3 comments)


File lib/vdsm/utils.py
Line 103: return stat.S_ISBLK(os.stat(path).st_mode)
Line 104: 
Line 105: 
Line 106: def touchFile(filePath, ignoreExceptions=False):
Line 107: 
Done
Line 108: Subset of POSIX touch functionality
Line 109: :param filePath: The file to touch
Line 110: :param ignoreExceptions: Should file handling exceptions be 
ignored?
Line 111: 



File vdsm/logger.conf.in
Line 1: [loggers]
Line 2: keys=root,vds,Storage,metadata
I need to get my eyes checked... Thanks.
Line 3: 
Line 4: [handlers]
Line 5: keys=console,syslog,logfile,metadata
Line 6: 


Line 1: [loggers]
Line 2: keys=root,vds,Storage,metadata
Line 3: 
Line 4: [handlers]
Line 5: keys=console,syslog,logfile,metadata
Done
Line 6: 
Line 7: [formatters]
Line 8: keys=long,simple,none,sysform
Line 9: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-22 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 14: Code-Review-1

(3 comments)


File lib/vdsm/utils.py
Line 103: return stat.S_ISBLK(os.stat(path).st_mode)
Line 104: 
Line 105: 
Line 106: def touchFile(filePath, ignoreExceptions=False):
Line 107: 
ohh love it, Thanks! :) but.. can you please separate this to another patch and 
I'll comment there?
Line 108: Subset of POSIX touch functionality
Line 109: :param filePath: The file to touch
Line 110: :param ignoreExceptions: Should file handling exceptions be 
ignored?
Line 111: 



File vdsm/logger.conf.in
Line 1: [loggers]
Line 2: keys=root,vds,Storage,metadata
you need to define your new logger
Line 3: 
Line 4: [handlers]
Line 5: keys=console,syslog,logfile,metadata
Line 6: 


Line 1: [loggers]
Line 2: keys=root,vds,Storage,metadata
Line 3: 
Line 4: [handlers]
Line 5: keys=console,syslog,logfile,metadata
and your new handler..
Line 6: 
Line 7: [formatters]
Line 8: keys=long,simple,none,sysform
Line 9: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-19 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13:

(9 comments)

Pushing new patch set in a second...

I had an offline session with Yaniv and we came to an understanding about the 
logger. I answered the rest of the comments.


Commit Message
Line 9: Unified network persistence feature:
Line 10: http://www.ovirt.org/Feature/NetworkReloaded#Unified_persistence
Line 11: 
Line 12: This patch is the first of two patches that implement an upgrade
Line 13: that is the ran the first time VDSM that uses unified network
Done
Line 14: persistence is started. The goal is to look at the current
Line 15: host networking configuration and populate the running config.
Line 16: 
Line 17: Please see the next patch in the series:


Line 9: Unified network persistence feature:
Line 10: http://www.ovirt.org/Feature/NetworkReloaded#Unified_persistence
Line 11: 
Line 12: This patch is the first of two patches that implement an upgrade
Line 13: that is the ran the first time VDSM that uses unified network
Done
Line 14: persistence is started. The goal is to look at the current
Line 15: host networking configuration and populate the running config.
Line 16: 
Line 17: Please see the next patch in the series:


Line 16: 
Line 17: Please see the next patch in the series:
Line 18: http://gerrit.ovirt.org/#/c/18425/
Line 19: 
Line 20: To better understand how this patch is used.
Done
Line 21: 
Line 22: Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9



File lib/vdsm/tool/upgrade.py
Line 25: 
Line 26: LOGGER_CONF_FILE = constants.P_VDSM_CONF + 'vdsm-tool.logger.conf'
Line 27: 
Line 28: 
Line 29: class Upgrade(object):
Done
Line 30: def __init__(self, upgradeName):
Line 31: self.upgradeName = upgradeName
Line 32: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
Line 33: upgrade, 
self.upgradeName)


Line 32: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
Line 33: upgrade, 
self.upgradeName)
Line 34: try:
Line 35: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 36: self.log = logging.getLogger('vdsm-tool')
Done
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)


Line 45: def seal(self):
Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Done


Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
I don't know why it would be helpful.


Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
Done


Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
Done


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-19 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 14:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4728/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5528/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5609/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-14 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13:

I thought about it more and I prefer no to have logger at all. if you want, you 
can make --verbos option and use that for additional outputs to stdout or 
syslog.

I don't understand the usage for logger in a command line tool. if you use it 
during run, you can catch exceptions and print them to vdsm.log near the usage.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-12 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13:

(3 comments)

Assaf, Yaniv Bronhaim wrote on Oct 24 15:44 (UTC+1)

Patch Set 10: Code-Review-1

I like the vdsm-tool logger idea, but do it separately to your feature please.


I suppose you could comply with this request; it makes more sense to set up 
logging when vdsm-tool starts rather in a particular module thereof.


Commit Message
Line 9: Unified network persistence feature:
Line 10: http://www.ovirt.org/Feature/NetworkReloaded#Unified_persistence
Line 11: 
Line 12: This patch is the first of two patches that implement an upgrade
Line 13: that is the ran the first time VDSM that uses unified network
... and fix the past participle form of run.
Line 14: persistence is started. The goal is to look at the current
Line 15: host networking configuration and populate the running config.
Line 16: 
Line 17: Please see the next patch in the series:



File lib/vdsm/tool/upgrade.py
Line 45: def seal(self):
Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
log only AFTER the seal() has succeeded.


Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
If I recall ancient discussions, haven't we find a reason to write vdsm's 
version into that file? (don't add it unless the reason was really good, and 
explain it.)


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-11 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13: Code-Review-1

(5 comments)

Looks like all (or at least most) of this patch is about the logger that I 
don't want


Commit Message
Line 9: Unified network persistence feature:
Line 10: http://www.ovirt.org/Feature/NetworkReloaded#Unified_persistence
Line 11: 
Line 12: This patch is the first of two patches that implement an upgrade
Line 13: that is the ran the first time VDSM that uses unified network
remove the the
Line 14: persistence is started. The goal is to look at the current
Line 15: host networking configuration and populate the running config.
Line 16: 
Line 17: Please see the next patch in the series:


Line 16: 
Line 17: Please see the next patch in the series:
Line 18: http://gerrit.ovirt.org/#/c/18425/
Line 19: 
Line 20: To better understand how this patch is used.
the link to the wiki is enough .. you don't need to mention the next patch imo
Line 21: 
Line 22: Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9



File lib/vdsm/tool/upgrade.py
Line 22: import os
Line 23: 
Line 24: from vdsm import constants
Line 25: 
Line 26: LOGGER_CONF_FILE = constants.P_VDSM_CONF + 'vdsm-tool.logger.conf'
Please don't add this logger. I don't see the reason for it

I don't mind if you want to submit it in separate patch and chat about it there
Line 27: 
Line 28: 
Line 29: class Upgrade(object):
Line 30: def __init__(self, upgradeName):


Line 45: def seal(self):
Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
use sys.stdout.write for that


Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
can't be exception in this line? like permission errors and etc..


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-11 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 46: 
Line 47: Mark the upgrade as a success
Line 48: 
Line 49: self.log.debug(Upgrade %s successfully performed % 
self.upgradeName)
Line 50: open(self.upgradeFilePath, 'w').close()
please create def touch(f, perm) in utils.py if you can.. that does exactly 
that, set permissions if specified and treat errors.


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-09 Thread danken
Dan Kenigsberg has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13: Code-Review-1

(2 comments)


File lib/vdsm/tool/upgrade.py
Line 25: 
Line 26: LOGGER_CONF_FILE = constants.P_VDSM_CONF + 'vdsm-tool.logger.conf'
Line 27: 
Line 28: 
Line 29: class Upgrade(object):
A docstring could help.
Line 30: def __init__(self, upgradeName):
Line 31: self.upgradeName = upgradeName
Line 32: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
Line 33: upgrade, 
self.upgradeName)


Line 32: self.upgradeFilePath = os.path.join(constants.P_VDSM_LIB,
Line 33: upgrade, 
self.upgradeName)
Line 34: try:
Line 35: logging.config.fileConfig(LOGGER_CONF_FILE)
Line 36: self.log = logging.getLogger('vdsm-tool')
Self.log is uninitialized on exception.
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-07 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 12:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4478/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5278/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5356/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 12
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-07 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 13:

Build Successful 

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4479/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5279/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5357/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-06 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 11: Verified+1

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 11
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-06 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 11: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4456/ : FAILURE

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/5258/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/5336/ : SUCCESS

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 11
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-06 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 11:

Jenkins failure unrelated to patch's code.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 11
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-11-03 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 36: self.log = logging.getLogger('vdsm-tool')
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)
I don't care much if upgrades are ran as part of vdsm-tool or by some other 
mechanism. I don't think the comparison to vdsClient is valid. Either case, I'd 
still want logs of successful / failed upgrades, what did they do and when they 
were ran. If we just log to /var/log/messages the data might be lost by the 
time the user reports a bug or asks for help.
Line 41: 
Line 42: def isNeeded(self):
Line 43: return not os.path.exists(self.upgradeFilePath)
Line 44: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-27 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 36: self.log = logging.getLogger('vdsm-tool')
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)
could be nice to have logging though, but you should report to stderr anyway, 
so the user will know about the fail, or raise RuntimeError

logging can be nice alright, but not needed in a tool.. its like having a 
logger to vdsClient instead of printing out the errors. where will you use it?  
all stderr will be flushed to /var/log/messages, that's enough as it seems to me
Line 41: 
Line 42: def isNeeded(self):
Line 43: return not os.path.exists(self.upgradeFilePath)
Line 44: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-24 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10: Code-Review-1

I like the vdsm-tool logger idea, but do it separately to your feature please.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-24 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10:

(1 comment)


File lib/vdsm/tool/upgrade.py
Line 36: self.log = logging.getLogger('vdsm-tool')
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)
frankly, we don't use logger in vdsm-tool at all, we don't need to.. it runs as 
deamon context, you should print whatever you want to stderr and stdout and 
you'll see it under /var/log/messages. why isn't it enough?

Don't forget the \n :)
Line 41: 
Line 42: def isNeeded(self):
Line 43: return not os.path.exists(self.upgradeFilePath)
Line 44: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-24 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10:

(1 comment)

Will do.


File lib/vdsm/tool/upgrade.py
Line 36: self.log = logging.getLogger('vdsm-tool')
Line 37: except Exception:
Line 38: logging.basicConfig(filename='/dev/stdout', filemode='w+',
Line 39: level=logging.DEBUG)
Line 40: logging.error(Could not init proper logging, 
exc_info=True)
In another comment you said that you like the idea but here you say that you 
don't. Anyway, I think it's extremely useful as we'll have a log of attempted 
and possibly failed upgrades. I think that'd be critically useful in a 
debugging / bug report situation.
Line 41: 
Line 42: def isNeeded(self):
Line 43: return not os.path.exists(self.upgradeFilePath)
Line 44: 


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-07 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 9: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4734/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4810/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3925/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 9
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-10-07 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 10: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4740/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4816/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3931/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-30 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

@Saggi:

Even *if* the Upgrade class isn't reusable, there's an advantage to keeping it 
separate from UnifiedPersistence which is separation of concerns. The 
UnifiedPersistence class already has a well defined role - It'd be bad practice 
to squash the Upgrade class into it as well (Thus giving UnifiedPersistence a 
2nd role). If I understand you correctly, you're in favor of remodeling Upgrade 
so that it is not inherited but composed, even though it is clearly a 'is-a' 
relationship and not a 'has-a' relationship. I can live with that because the 
inheritance in this case is a means to an end and not the point.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-30 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

@Saggi:

On a more meta-programming note: Python is not Java. We avoid creating 
needless base classes for things for no real gain.

While certain functional elements of Python are Pythonic by consensus, VDSM 
developers' styling choice of avoiding object-oriented modeling is not Pythonic 
by nature and is under heavy debate outside of VDSM-land.
The enormously controversial:
http://www.youtube.com/watch?v=o9pEzgHorH0

Is a testament.

Don't get caught up by one side of the debate is all I'm saying.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-30 Thread smizrahi
Saggi Mizrahi has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

I never said to squash the upgrade class in.

I said it upgrade() should be converted to a method.

As for the file check. I said it's not good to assume it's the way every 
upgrade target is going test itself. I don't mind if you move it out to a 
separate function\class or put it in the UnifiedUpgrade class.

Changing lead classes is painless so I don't care what you do in it. Changing 
base classes is hard so I just don't want to have them in code.

is-a relationships are never clear. Saggi is-a Developer and saggi is-an 
Annoying Guy, Saggi is a Truck-enthusiast.

Non of them should be base classes for Saggi

Saggi's profession is Developer
One of Saggi's traits is Annoying
One of Saggi's interests is Trucks

is-a relationship is needless taxonomy. Identity is meaningless in software. 
Traits are the only thing that matters.

By saying something is-a something you say that it answers a group of 
arbitrary traits in your perception of the world. 
I'm just trying to avoid cementing anyone's individual perception in the code. 
Just use a group of traits and compose identities as needed. It easy to say:
In order to be and UpgradeTarget you need to be able to check() and 
performUpgrade(). You have the code and that is all it uses. To try an 
philosophize about what makes something an Upgrade, truly, is well beyond my 
tiny brains abilities.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-30 Thread smizrahi
Saggi Mizrahi has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

*leaf classes

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-29 Thread smizrahi
Saggi Mizrahi has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8: Code-Review-1

(3 comments)

You probably don't want to design this that way.

You want to have a method called Upgrade() (and UpgradeIfNeeded() if you so 
choose) the hint is that Upgrade is not really a name for a class. You want to 
have in implicit interface for the parameter which is obj.run() obj.isNeeded(). 
I will call them UpgradeTarget objects.

Since it's improbable to think that all upgrades will use a simple file to 
check if they are comitted it's best to either put the check file logic in a 
reusable class of it's own or implement it inside the single user which is the 
UnifiedPersistence(object) class.

Python is not Java. We avoid creating needless base classes for things for no 
real gain.

Favor 'object composition' over 'class inheritance'. (Gang of Four 1995:20)

https://en.wikipedia.org/wiki/Composition_over_inheritance#Benefits


File lib/vdsm/tool/upgrade.py
Line 24: 
Line 25: 
Line 26: class Upgrade(object):
Line 27: def __init__(self):
Line 28: self.upgradeName = self.__class__.__name__
I smell inheritance in the near future
Line 29: self.upgradeFilePath = constants.P_VDSM_LIB + upgrade/%s % \
Line 30: self.upgradeName
Line 31: self.log = logging.getLogger('vds')
Line 32: 


Line 25: 
Line 26: class Upgrade(object):
Line 27: def __init__(self):
Line 28: self.upgradeName = self.__class__.__name__
Line 29: self.upgradeFilePath = constants.P_VDSM_LIB + upgrade/%s % \
os.path.jon()?
Line 30: self.upgradeName
Line 31: self.log = logging.getLogger('vds')
Line 32: 
Line 33: def runIfNeeded(self):


Line 39: def isNeeded(self):
Line 40: return not os.path.exists(self.upgradeFilePath)
Line 41: 
Line 42: def run(self):
Line 43: raise NotImplementedError
You raise an instance not a type. NotImplementedError()
Line 44: 
Line 45: def _finished(self):


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-28 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

What if the running version is newer than the version written in the upgrade 
file? How do we check if one version is 'newer' than another. What happens if 
we change the versioning scheme (Integration has wanted to do this for quite a 
while).

More importantly - What added functionality do we get from the added 
complexity? How can we know *when* to run all of the upgrades? Before VDSM 
first boots? Why? What if an upgrade wants to run at a different time? This is 
why I wanted to keep the mechanism as simple as possible. But if you can keep 
it still just as general while adding functionality then I'm all for it :)

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: No
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-27 Thread asegurap
Antoni Segura Puimedon has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8: Code-Review-1

(2 comments)

NOTE: The following is a proposal, @Assaf, @Dan, @Yaniv and others, please 
review and if necessary I'll flip the vote.

I have the sensation that instead of checking if a file exists, we should 
probably use dsaversion to check if the upgrade file exists and if it does, 
that the version it upgraded to is the one we are running.

Then run would have an ordered dictionary of version number - upgrade method. 
It would loop running the missing upgrade methods (if any). For this to be 
good, installation should write to the upgrade file its version if the file 
does not exist.


File lib/vdsm/tool/upgrade.py
Line 36: self.run()
Line 37: self._finished()
Line 38: 
Line 39: def isNeeded(self):
Line 40: return not os.path.exists(self.upgradeFilePath)
See general comment. version checking.
Line 41: 
Line 42: def run(self):
Line 43: raise NotImplementedError
Line 44: 


Line 42: def run(self):
Line 43: raise NotImplementedError
Line 44: 
Line 45: def _finished(self):
Line 46: open(self.upgradeFilePath, 'w').close()
See general comment. version writing.


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-23 Thread ybronhei
Yaniv Bronhaim has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

(2 comments)


Commit Message
Line 3: AuthorDate: 2013-08-04 11:08:51 +0300
Line 4: Commit: Assaf Muller amul...@redhat.com
Line 5: CommitDate: 2013-09-22 17:05:05 +0300
Line 6: 
Line 7: Unified network persistence [4.1/4.*] - Upgrade mechanism
you explain the whole mechanism here, you don't explain the upgrade.py usage 
and why is it under vdsm-tool in separate module.

Better explaining the specific part here and put link to feature wiki page in 
each part.
Line 8: 
Line 9: First half of unified network persistence upgrade.
Line 10: Unified network persistence: For each setupNetworks that
Line 11: we get from the engine, we store the parameters for each



File lib/vdsm/tool/upgrade.py
Line 27: def __init__(self):
Line 28: self.upgradeName = self.__class__.__name__
Line 29: self.upgradeFilePath = constants.P_VDSM_LIB + upgrade/%s % \
Line 30: self.upgradeName
Line 31: self.log = logging.getLogger('vds')
you don't have logging conf loaded here. set default handler to a new 
vdsm-tool.log file, or use syslog\stderr
Line 32: 
Line 33: def runIfNeeded(self):
Line 34: if self.isNeeded():
Line 35: self.log.debug(Running upgrade %s % self.upgradeName)


-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
Gerrit-HasComments: Yes
___
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches


Change in vdsm[master]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-22 Thread oVirt Jenkins CI Server
oVirt Jenkins CI Server has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8: Verified-1

Build Failed 

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4568/ : FAILURE

http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4490/ : SUCCESS

http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3682/ : FAILURE

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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]: Unified network persistence [4.1/4.*] - Upgrade mechanism

2013-09-22 Thread amuller
Assaf Muller has posted comments on this change.

Change subject: Unified network persistence [4.1/4.*] - Upgrade mechanism
..


Patch Set 8:

Yaniv, Saggi: Updated the commit message to give some context.

-- 
To view, visit http://gerrit.ovirt.org/17726
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Iba3c9c34f03134c192db1c2add31084824e195d9
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Alon Bar-Lev alo...@redhat.com
Gerrit-Reviewer: Antoni Segura Puimedon asegu...@redhat.com
Gerrit-Reviewer: Assaf Muller amul...@redhat.com
Gerrit-Reviewer: Barak Azulay bazu...@redhat.com
Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com
Gerrit-Reviewer: Giuseppe Vallarelli gvall...@redhat.com
Gerrit-Reviewer: Mark Wu wu...@linux.vnet.ibm.com
Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com
Gerrit-Reviewer: Yaniv Bronhaim ybron...@redhat.com
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