[node-patches] Change in ovirt-node[master]: app: Move plugins into their own namespace

mburns at redhat.com mburns at redhat.com
Fri May 24 16:39:20 UTC 2013


Michael Burns has submitted this change and it was merged.

Change subject: app: Move plugins into their own namespace
......................................................................


app: Move plugins into their own namespace

Previously all plugins had to put the UI .py fies into the same
directory. This could lead to collisions and could became messy on the
long term. Now each plugin can create it's own folder in the base plugin
dirs for the setup and installer (their own namespace) to keep all
relevant files (wrt to the plugin) in one place and avoid collisions
with other plugins.

Now the discovery and initialization happens as follows:
1. Import all packages below a basepackage (e.g. ovirt.node.installer)
2. If the package has a function called 'createPlugins(application)'
then it is called. It is expected that this function creates all plugins
which shall be activated.

This way only the package is imported, the package/plugin itself is
responsible for all other imports.

Change-Id: Icaf10816d1c87d9d0404130f496f0f6cad13149a
Signed-off-by: Fabian Deutsch <fabiand at fedoraproject.org>
---
M ovirt-node.spec.in
M src/Makefile.am
M src/ovirt/node/app.py
M src/ovirt/node/config/__init__.py
M src/ovirt/node/installer/__init__.py
M src/ovirt/node/installer/__main__.py
A src/ovirt/node/installer/core/__init__.py
R src/ovirt/node/installer/core/boot_device_page.py
R src/ovirt/node/installer/core/installation_device_page.py
R src/ovirt/node/installer/core/keyboard_page.py
R src/ovirt/node/installer/core/password_page.py
R src/ovirt/node/installer/core/progress_page.py
R src/ovirt/node/installer/core/storage_vol_page.py
R src/ovirt/node/installer/core/upgrade_page.py
R src/ovirt/node/installer/core/welcome_page.py
M src/ovirt/node/plugins.py
M src/ovirt/node/setup/__init__.py
A src/ovirt/node/setup/cim/__init__.py
R src/ovirt/node/setup/cim/cim_model.py
R src/ovirt/node/setup/cim/cim_page.py
A src/ovirt/node/setup/core/__init__.py
R src/ovirt/node/setup/core/diagnostics_page.py
R src/ovirt/node/setup/core/kdump_page.py
R src/ovirt/node/setup/core/keyboard_page.py
R src/ovirt/node/setup/core/logging_page.py
R src/ovirt/node/setup/core/monitoring_page.py
R src/ovirt/node/setup/core/network_page.py
R src/ovirt/node/setup/core/ping.py
R src/ovirt/node/setup/core/plugins_page.py
R src/ovirt/node/setup/core/remote_storage_page.py
R src/ovirt/node/setup/core/security_page.py
R src/ovirt/node/setup/core/status_page.py
R src/ovirt/node/setup/core/support_page.py
A src/ovirt/node/setup/snmp/__init__.py
R src/ovirt/node/setup/snmp/snmp_model.py
R src/ovirt/node/setup/snmp/snmp_page.py
36 files changed, 332 insertions(+), 108 deletions(-)

Approvals:
  Alon Bar-Lev: Looks good to me, but someone else must approve
  Michael Burns: Verified; Looks good to me, approved


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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icaf10816d1c87d9d0404130f496f0f6cad13149a
Gerrit-PatchSet: 13
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Fabian Deutsch <fabiand at fedoraproject.org>
Gerrit-Reviewer: Alon Bar-Lev <alonbl at redhat.com>
Gerrit-Reviewer: Douglas Schilling Landgraf <dougsland at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fabiand at fedoraproject.org>
Gerrit-Reviewer: Michael Burns <mburns at redhat.com>



More information about the node-patches mailing list