Adam Litke has uploaded a new change for review. Change subject: storage: Rename storageConstants.py to constants.py ......................................................................
storage: Rename storageConstants.py to constants.py The SDM work is beginning an effort to reorganize storage constants. Currently constants are peppered throughout the various storage modules. Getting access to these constants introduces complex module interdependencies which can lead to circular import dependencies. In this first step, rename storageConstants.py to constants.py and make necessary adjustments to the code which currently imports this module. The new name is shorter and does not have the redundant 'storage' as part of its name. Future patches will move constants into this module. Change-Id: I74684fdf63fb08573dc2068dcfb32ba5febac82b Signed-off-by: Adam Litke <ali...@redhat.com> --- M debian/vdsm.install M vdsm.spec.in M vdsm/storage/Makefile.am R vdsm/storage/constants.py M vdsm/storage/hsm.py M vdsm/storage/misc.py M vdsm/storage/sp.py 7 files changed, 7 insertions(+), 7 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/33/50633/1 diff --git a/debian/vdsm.install b/debian/vdsm.install index 8495a4c..efa6045 100644 --- a/debian/vdsm.install +++ b/debian/vdsm.install @@ -83,6 +83,7 @@ ./usr/share/vdsm/storage/blockSD.py ./usr/share/vdsm/storage/blockVolume.py ./usr/share/vdsm/storage/clusterlock.py +./usr/share/vdsm/storage/constants.py ./usr/share/vdsm/storage/curlImgWrap.py ./usr/share/vdsm/storage/devicemapper.py ./usr/share/vdsm/storage/dispatcher.py @@ -118,7 +119,6 @@ ./usr/share/vdsm/storage/securable.py ./usr/share/vdsm/storage/sp.py ./usr/share/vdsm/storage/spbackends.py -./usr/share/vdsm/storage/storageConstants.py ./usr/share/vdsm/storage/storageServer.py ./usr/share/vdsm/storage/storage_exception.py ./usr/share/vdsm/storage/storage_mailbox.py diff --git a/vdsm.spec.in b/vdsm.spec.in index d7b6ae8..4ca7827 100644 --- a/vdsm.spec.in +++ b/vdsm.spec.in @@ -899,6 +899,7 @@ %{_datadir}/%{vdsm_name}/storage/__init__.py* %{_datadir}/%{vdsm_name}/storage/blockSD.py* %{_datadir}/%{vdsm_name}/storage/blockVolume.py* +%{_datadir}/%{vdsm_name}/storage/constants.py* %{_datadir}/%{vdsm_name}/storage/curlImgWrap.py* %{_datadir}/%{vdsm_name}/storage/devicemapper.py* %{_datadir}/%{vdsm_name}/storage/dispatcher.py* @@ -933,7 +934,6 @@ %{_datadir}/%{vdsm_name}/storage/securable.py* %{_datadir}/%{vdsm_name}/storage/sp.py* %{_datadir}/%{vdsm_name}/storage/spbackends.py* -%{_datadir}/%{vdsm_name}/storage/storageConstants.py* %{_datadir}/%{vdsm_name}/storage/storage_exception.py* %{_datadir}/%{vdsm_name}/storage/storage_mailbox.py* %{_datadir}/%{vdsm_name}/storage/storageServer.py* diff --git a/vdsm/storage/Makefile.am b/vdsm/storage/Makefile.am index e183e80..9ed7e61 100644 --- a/vdsm/storage/Makefile.am +++ b/vdsm/storage/Makefile.am @@ -28,6 +28,7 @@ blockSD.py \ blockVolume.py \ clusterlock.py \ + constants.py \ curlImgWrap.py \ devicemapper.py \ dispatcher.py \ @@ -60,7 +61,6 @@ securable.py \ sp.py \ spbackends.py \ - storageConstants.py \ storage_exception.py \ storage_mailbox.py \ storageServer.py \ diff --git a/vdsm/storage/storageConstants.py b/vdsm/storage/constants.py similarity index 100% rename from vdsm/storage/storageConstants.py rename to vdsm/storage/constants.py diff --git a/vdsm/storage/hsm.py b/vdsm/storage/hsm.py index 33be84b..2397d27 100644 --- a/vdsm/storage/hsm.py +++ b/vdsm/storage/hsm.py @@ -63,8 +63,8 @@ import storage_exception as se from threadLocal import vars from vdsm import constants -from storageConstants import STORAGE -from storageConstants import SECTOR_SIZE +from constants import STORAGE +from constants import SECTOR_SIZE import resourceManager as rm from resourceFactories import IMAGE_NAMESPACE import devicemapper diff --git a/vdsm/storage/misc.py b/vdsm/storage/misc.py index c40b676..8fcffcd 100644 --- a/vdsm/storage/misc.py +++ b/vdsm/storage/misc.py @@ -49,7 +49,7 @@ from vdsm import concurrent from vdsm import constants from vdsm import utils -from storageConstants import SECTOR_SIZE +from constants import SECTOR_SIZE import storage_exception as se import logUtils diff --git a/vdsm/storage/sp.py b/vdsm/storage/sp.py index 311eb5f..45cd85e 100644 --- a/vdsm/storage/sp.py +++ b/vdsm/storage/sp.py @@ -47,7 +47,7 @@ from securable import secured, unsecured import image from resourceFactories import IMAGE_NAMESPACE -from storageConstants import STORAGE +from constants import STORAGE import resourceManager as rm import volume import mount -- To view, visit https://gerrit.ovirt.org/50633 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I74684fdf63fb08573dc2068dcfb32ba5febac82b Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Adam Litke <ali...@redhat.com> _______________________________________________ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches