Alon Bar-Lev has posted comments on this change.
Change subject: packaging: engine-cleanup-2: backup DB before removing
......................................................................
Patch Set 4: (2 inline comments)
....................................................
File packaging/setup/plugins/ovirt-engine-common/db/backup.py
Line 38: """DB backup plugin."""
Line 39: def __init__(self, context):
Line 40: super(Plugin, self).__init__(context=context)
Line 41:
Line 42: def _pgpass(self):
this belongs to its own plugin... other components will require that
(validations).
Line 43: fd, pgpass = tempfile.mkstemp(
Line 44: prefix='pgpass',
Line 45: suffix='.tmp',
Line 46: )
Line 104: )
Line 105: def _setup(self):
Line 106: self.command.detect('pg_dump')
Line 107:
Line 108: @plugin.event(
I think this is way too complex... much simpler is to call to wrap it up in
utilties and call it when needed together with appropriate parameters such as
log prefix...
If you want I can perform that.
Line 109: stage=plugin.Stages.STAGE_MISC,
Line 110: name=osetupcons.Stages.DB_BACKUP,
Line 111: condition=lambda self: (
Line 112: self.environment[osetupcons.DBEnv.PASSWORD] is not None
and
--
To view, visit http://gerrit.ovirt.org/14703
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I89635b7bf6e86fb3bf3657717a903b1efb127b9a
Gerrit-PatchSet: 4
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Sandro Bonazzola <[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]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches