Alon Bar-Lev has posted comments on this change.
Change subject: packaging: setup: partial cleanup - db only
......................................................................
Patch Set 2:
(2 comments)
....................................................
File packaging/setup/plugins/ovirt-engine-setup/core/misc.py
Line 82: if (
Line 83: self.environment[osetupcons.DBEnv.NEW_DATABASE] and
Line 84: self.environment[
Line 85: osetupcons.CoreEnv.ACTION
Line 86: ] == osetupcons.Const.ACTION_UPGRADE
I thought of:
"Forcing ACTION to SETUP because we are creating"...
And remove this extra condition.
Better condition would be != SETUP, no?
Line 87: ):
Line 88: self.logger.debug(
Line 89: 'Changing ACTION from UPGRADE to SETUP because we are '
Line 90: 'creating a new database'
....................................................
File packaging/setup/plugins/ovirt-engine-setup/legacy/database.py
Line 87: if dbovirtutils.isNewDatabase():
Line 88: raise RuntimeError(
Line 89: _('Unexpected empty database during upgrade')
Line 90: )
Line 91: except (psycopg2.InterfaceError, RuntimeError) as e:
Do you suggest to wrap all postgres exception within RuntimeError?
This will hide issues like we test in tryDatabaseConnect()
Line 92: self.logger.debug(
Line 93: 'Database connection failed while trying to upgrade
from '
Line 94: 'legacy, creating a new database',
Line 95: exc_info=True,
--
To view, visit http://gerrit.ovirt.org/19689
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Id9aa1791eb7ccdbc8c679e72ed6eaa4f72ac29c6
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yedidyah Bar David <[email protected]>
Gerrit-Reviewer: Alex Lourie <[email protected]>
Gerrit-Reviewer: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Ofer Schreiber <[email protected]>
Gerrit-Reviewer: Sandro Bonazzola <[email protected]>
Gerrit-Reviewer: Yedidyah Bar David <[email protected]>
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches