Merge "fix case sensitivity"
This commit is contained in:
commit
d1ce6c79e0
@ -170,24 +170,24 @@ class InUse(ManilaException):
|
|||||||
|
|
||||||
|
|
||||||
class ShareNetworkNotFound(NotFound):
|
class ShareNetworkNotFound(NotFound):
|
||||||
message = _("Share Network %(share_network_id)s could not be found.")
|
message = _("Share network %(share_network_id)s could not be found.")
|
||||||
|
|
||||||
|
|
||||||
class ShareServerNotFound(NotFound):
|
class ShareServerNotFound(NotFound):
|
||||||
message = _("Share Server %(share_server_id)s could not be found.")
|
message = _("Share server %(share_server_id)s could not be found.")
|
||||||
|
|
||||||
|
|
||||||
class ShareServerNotFoundByFilters(ShareServerNotFound):
|
class ShareServerNotFoundByFilters(ShareServerNotFound):
|
||||||
message = _("Share Server could not be found by "
|
message = _("Share server could not be found by "
|
||||||
"filters: %(filters_description)s.")
|
"filters: %(filters_description)s.")
|
||||||
|
|
||||||
|
|
||||||
class ShareServerInUse(InUse):
|
class ShareServerInUse(InUse):
|
||||||
message = _("Share Server %(share_server_id)s is in use.")
|
message = _("Share server %(share_server_id)s is in use.")
|
||||||
|
|
||||||
|
|
||||||
class ShareServerNotCreated(ManilaException):
|
class ShareServerNotCreated(ManilaException):
|
||||||
message = _("Share Server %(share_server_id)s failed on creation.")
|
message = _("Share server %(share_server_id)s failed on creation.")
|
||||||
|
|
||||||
|
|
||||||
class ServiceNotFound(NotFound):
|
class ServiceNotFound(NotFound):
|
||||||
@ -199,11 +199,11 @@ class HostNotFound(NotFound):
|
|||||||
|
|
||||||
|
|
||||||
class SchedulerHostFilterNotFound(NotFound):
|
class SchedulerHostFilterNotFound(NotFound):
|
||||||
message = _("Scheduler Host Filter %(filter_name)s could not be found.")
|
message = _("Scheduler host filter %(filter_name)s could not be found.")
|
||||||
|
|
||||||
|
|
||||||
class SchedulerHostWeigherNotFound(NotFound):
|
class SchedulerHostWeigherNotFound(NotFound):
|
||||||
message = _("Scheduler Host Weigher %(weigher_name)s could not be found.")
|
message = _("Scheduler host weigher %(weigher_name)s could not be found.")
|
||||||
|
|
||||||
|
|
||||||
class HostBinaryNotFound(NotFound):
|
class HostBinaryNotFound(NotFound):
|
||||||
@ -303,7 +303,7 @@ class QuotaError(ManilaException):
|
|||||||
|
|
||||||
class ShareSizeExceedsAvailableQuota(QuotaError):
|
class ShareSizeExceedsAvailableQuota(QuotaError):
|
||||||
message = _("Requested share or snapshot exceeds "
|
message = _("Requested share or snapshot exceeds "
|
||||||
"allowed Gigabytes quota.")
|
"allowed gigabytes quota.")
|
||||||
|
|
||||||
|
|
||||||
class ShareLimitExceeded(QuotaError):
|
class ShareLimitExceeded(QuotaError):
|
||||||
@ -412,17 +412,17 @@ class VolumeTypeNotFoundByName(VolumeTypeNotFound):
|
|||||||
|
|
||||||
|
|
||||||
class VolumeTypeExtraSpecsNotFound(NotFound):
|
class VolumeTypeExtraSpecsNotFound(NotFound):
|
||||||
message = _("Volume Type %(volume_type_id)s has no extra specs with "
|
message = _("Volume type %(volume_type_id)s has no extra specs with "
|
||||||
"key %(extra_specs_key)s.")
|
"key %(extra_specs_key)s.")
|
||||||
|
|
||||||
|
|
||||||
class VolumeTypeInUse(ManilaException):
|
class VolumeTypeInUse(ManilaException):
|
||||||
message = _("Volume Type %(volume_type_id)s deletion is not allowed with "
|
message = _("Volume type %(volume_type_id)s deletion is not allowed with "
|
||||||
"volumes present with the type.")
|
"volumes present with the type.")
|
||||||
|
|
||||||
|
|
||||||
class VolumeTypeExists(ManilaException):
|
class VolumeTypeExists(ManilaException):
|
||||||
message = _("Volume Type %(id)s already exists.")
|
message = _("Volume type %(id)s already exists.")
|
||||||
|
|
||||||
|
|
||||||
class VolumeTypeCreateFailed(ManilaException):
|
class VolumeTypeCreateFailed(ManilaException):
|
||||||
@ -443,7 +443,7 @@ class ServiceInstanceException(ManilaException):
|
|||||||
|
|
||||||
|
|
||||||
class ServiceInstanceUnavailable(ServiceInstanceException):
|
class ServiceInstanceUnavailable(ServiceInstanceException):
|
||||||
message = _("Service Instance is not available.")
|
message = _("Service instance is not available.")
|
||||||
|
|
||||||
|
|
||||||
class NetAppException(ManilaException):
|
class NetAppException(ManilaException):
|
||||||
|
@ -512,12 +512,12 @@ class VNXStorageConnection(driver.StorageConnection):
|
|||||||
# Refresh DataMover/VDM by the configuration
|
# Refresh DataMover/VDM by the configuration
|
||||||
moverRef = self.get_mover_ref_by_name(self._mover_name)
|
moverRef = self.get_mover_ref_by_name(self._mover_name)
|
||||||
if not self._vdm_exist(vdm_name):
|
if not self._vdm_exist(vdm_name):
|
||||||
LOG.debug('Share Server %s not found. Creating', vdm_name)
|
LOG.debug('Share server %s not found, creating.', vdm_name)
|
||||||
self._create_vdm(vdm_name, moverRef)
|
self._create_vdm(vdm_name, moverRef)
|
||||||
|
|
||||||
status, vdmRef = self._XMLAPI_helper.get_vdm_by_name(vdm_name)
|
status, vdmRef = self._XMLAPI_helper.get_vdm_by_name(vdm_name)
|
||||||
if constants.STATUS_OK != status:
|
if constants.STATUS_OK != status:
|
||||||
message = (_('Could not get Share Server by name %(name)s. '
|
message = (_('Could not get share server by name %(name)s. '
|
||||||
'Reason: %(err)s.')
|
'Reason: %(err)s.')
|
||||||
% {'name': vdm_name,
|
% {'name': vdm_name,
|
||||||
'err': vdmRef})
|
'err': vdmRef})
|
||||||
@ -901,7 +901,7 @@ class VNXStorageConnection(driver.StorageConnection):
|
|||||||
|
|
||||||
if (service_number > 1 or
|
if (service_number > 1 or
|
||||||
security_services[0]['type'] != 'active_directory'):
|
security_services[0]['type'] != 'active_directory'):
|
||||||
return False, _("Unsupported Security Services. "
|
return False, _("Unsupported security services. "
|
||||||
"Only support single security service and "
|
"Only support single security service and "
|
||||||
"only support type 'active_directory'")
|
"only support type 'active_directory'")
|
||||||
|
|
||||||
|
@ -387,7 +387,7 @@ class RestHelper():
|
|||||||
fileparam['ALLOCTYPE'] = 0
|
fileparam['ALLOCTYPE'] = 0
|
||||||
else:
|
else:
|
||||||
err_msg = (_(
|
err_msg = (_(
|
||||||
'Config file is wrong. Filesystem Type must be "Thin"'
|
'Config file is wrong. Filesystem type must be "Thin"'
|
||||||
' or "Thick". AllocType:%(fetchtype)s') %
|
' or "Thick". AllocType:%(fetchtype)s') %
|
||||||
{'fetchtype': fstype})
|
{'fetchtype': fstype})
|
||||||
LOG.error(err_msg)
|
LOG.error(err_msg)
|
||||||
|
@ -96,9 +96,9 @@ class ZFSSAApi(object):
|
|||||||
self.verify_project(pool, project)
|
self.verify_project(pool, project)
|
||||||
avail = self.get_project_stats(pool, project)
|
avail = self.get_project_stats(pool, project)
|
||||||
if avail < size:
|
if avail < size:
|
||||||
exception_msg = (_('Error Creating '
|
exception_msg = (_('Error creating '
|
||||||
'Share: %(share)s on '
|
'share: %(share)s on '
|
||||||
'Pool: %(pool)s. '
|
'pool: %(pool)s. '
|
||||||
'Not enough space.')
|
'Not enough space.')
|
||||||
% {'share': share,
|
% {'share': share,
|
||||||
'pool': pool})
|
'pool': pool})
|
||||||
@ -112,18 +112,18 @@ class ZFSSAApi(object):
|
|||||||
svc = self.pool_path % pool
|
svc = self.pool_path % pool
|
||||||
ret = self.rclient.get(svc)
|
ret = self.rclient.get(svc)
|
||||||
if ret.status != restclient.Status.OK:
|
if ret.status != restclient.Status.OK:
|
||||||
exception_msg = (_('Error Getting Pool Stats: '
|
exception_msg = (_('Error getting pool stats: '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'pool': pool,
|
% {'pool': pool,
|
||||||
'ret.status': ret.status,
|
'ret.status': ret.status,
|
||||||
'ret.data': ret.data})
|
'ret.data': ret.data})
|
||||||
raise exception.InvalidInput(reason=exception_msg)
|
raise exception.InvalidInput(reason=exception_msg)
|
||||||
val = jsonutils.loads(ret.data)
|
val = jsonutils.loads(ret.data)
|
||||||
if not self._is_pool_owned(val):
|
if not self._is_pool_owned(val):
|
||||||
exception_msg = (_('Error Pool ownership: '
|
exception_msg = (_('Error pool ownership: '
|
||||||
'Pool %(pool)s is not owned '
|
'pool %(pool)s is not owned '
|
||||||
'by %(host)s.')
|
'by %(host)s.')
|
||||||
% {'pool': pool,
|
% {'pool': pool,
|
||||||
'host': self.host})
|
'host': self.host})
|
||||||
@ -141,11 +141,11 @@ class ZFSSAApi(object):
|
|||||||
svc = self.project_path % (pool, project)
|
svc = self.project_path % (pool, project)
|
||||||
ret = self.rclient.get(svc)
|
ret = self.rclient.get(svc)
|
||||||
if ret.status != restclient.Status.OK:
|
if ret.status != restclient.Status.OK:
|
||||||
exception_msg = (_('Error Getting Project Stats: '
|
exception_msg = (_('Error getting project stats: '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Project: %(project)s '
|
'project: %(project)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'pool': pool,
|
% {'pool': pool,
|
||||||
'project': project,
|
'project': project,
|
||||||
'ret.status': ret.status,
|
'ret.status': ret.status,
|
||||||
@ -164,11 +164,11 @@ class ZFSSAApi(object):
|
|||||||
svc = self.projects_path % pool
|
svc = self.projects_path % pool
|
||||||
ret = self.rclient.post(svc, arg)
|
ret = self.rclient.post(svc, arg)
|
||||||
if ret.status != restclient.Status.CREATED:
|
if ret.status != restclient.Status.CREATED:
|
||||||
exception_msg = (_('Error Creating Project: '
|
exception_msg = (_('Error creating project: '
|
||||||
'%(project)s on '
|
'%(project)s on '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s .')
|
'message: %(ret.data)s.')
|
||||||
% {'project': project,
|
% {'project': project,
|
||||||
'pool': pool,
|
'pool': pool,
|
||||||
'ret.status': ret.status,
|
'ret.status': ret.status,
|
||||||
@ -195,10 +195,10 @@ class ZFSSAApi(object):
|
|||||||
svc = self.shares_path % (pool, project)
|
svc = self.shares_path % (pool, project)
|
||||||
ret = self.rclient.post(svc, share)
|
ret = self.rclient.post(svc, share)
|
||||||
if ret.status != restclient.Status.CREATED:
|
if ret.status != restclient.Status.CREATED:
|
||||||
exception_msg = (_('Error Creating '
|
exception_msg = (_('Error creating '
|
||||||
'Share: %(name)s '
|
'share: %(name)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'name': share['name'],
|
% {'name': share['name'],
|
||||||
'ret.status': ret.status,
|
'ret.status': ret.status,
|
||||||
'ret.data': ret.data})
|
'ret.data': ret.data})
|
||||||
@ -234,12 +234,12 @@ class ZFSSAApi(object):
|
|||||||
svc = self.share_path % (pool, project, share)
|
svc = self.share_path % (pool, project, share)
|
||||||
ret = self.rclient.delete(svc)
|
ret = self.rclient.delete(svc)
|
||||||
if ret.status != restclient.Status.NO_CONTENT:
|
if ret.status != restclient.Status.NO_CONTENT:
|
||||||
exception_msg = (_LE('Error Deleting '
|
exception_msg = (_LE('Error deleting '
|
||||||
'Share: %(share)s to '
|
'share: %(share)s to '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Project: %(project)s '
|
'project: %(project)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.'),
|
'message: %(ret.data)s.'),
|
||||||
{'share': share,
|
{'share': share,
|
||||||
'pool': pool,
|
'pool': pool,
|
||||||
'project': project,
|
'project': project,
|
||||||
@ -253,13 +253,13 @@ class ZFSSAApi(object):
|
|||||||
arg = {'name': snapshot}
|
arg = {'name': snapshot}
|
||||||
ret = self.rclient.post(svc, arg)
|
ret = self.rclient.post(svc, arg)
|
||||||
if ret.status != restclient.Status.CREATED:
|
if ret.status != restclient.Status.CREATED:
|
||||||
exception_msg = (_('Error Creating '
|
exception_msg = (_('Error creating '
|
||||||
'Snapshot: %(snapshot)s on'
|
'snapshot: %(snapshot)s on '
|
||||||
'Share: %(share)s to '
|
'share: %(share)s to '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Project: %(project)s '
|
'project: %(project)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'snapshot': snapshot,
|
% {'snapshot': snapshot,
|
||||||
'share': share,
|
'share': share,
|
||||||
'pool': pool,
|
'pool': pool,
|
||||||
@ -273,13 +273,13 @@ class ZFSSAApi(object):
|
|||||||
svc = self.snapshot_path % (pool, project, share, snapshot)
|
svc = self.snapshot_path % (pool, project, share, snapshot)
|
||||||
ret = self.rclient.delete(svc)
|
ret = self.rclient.delete(svc)
|
||||||
if ret.status != restclient.Status.NO_CONTENT:
|
if ret.status != restclient.Status.NO_CONTENT:
|
||||||
exception_msg = (_('Error Deleting '
|
exception_msg = (_('Error deleting '
|
||||||
'Snapshot: %(snapshot)s on '
|
'snapshot: %(snapshot)s on '
|
||||||
'Share: %(share)s to '
|
'share: %(share)s to '
|
||||||
'Pool: %(pool)s '
|
'pool: %(pool)s '
|
||||||
'Project: %(project)s '
|
'project: %(project)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'snapshot': snapshot,
|
% {'snapshot': snapshot,
|
||||||
'share': share,
|
'share': share,
|
||||||
'pool': pool,
|
'pool': pool,
|
||||||
@ -297,13 +297,13 @@ class ZFSSAApi(object):
|
|||||||
snapshot['id'])
|
snapshot['id'])
|
||||||
ret = self.rclient.put(svc, arg)
|
ret = self.rclient.put(svc, arg)
|
||||||
if ret.status != restclient.Status.CREATED:
|
if ret.status != restclient.Status.CREATED:
|
||||||
exception_msg = (_('Error Cloning '
|
exception_msg = (_('Error cloning '
|
||||||
'Snapshot: %(snapshot)s on '
|
'snapshot: %(snapshot)s on '
|
||||||
'Share: %(share)s of '
|
'share: %(share)s of '
|
||||||
'Pool: %(pool)s '
|
'Pool: %(pool)s '
|
||||||
'Project: %(project)s '
|
'project: %(project)s '
|
||||||
'Return code: %(ret.status)d '
|
'return code: %(ret.status)d '
|
||||||
'Message: %(ret.data)s.')
|
'message: %(ret.data)s.')
|
||||||
% {'snapshot': snapshot['id'],
|
% {'snapshot': snapshot['id'],
|
||||||
'share': snapshot['share_id'],
|
'share': snapshot['share_id'],
|
||||||
'pool': pool,
|
'pool': pool,
|
||||||
@ -337,7 +337,7 @@ class ZFSSAApi(object):
|
|||||||
if sharenfs == 'off':
|
if sharenfs == 'off':
|
||||||
sharenfs = 'sec=sys'
|
sharenfs = 'sec=sys'
|
||||||
if ip in sharenfs:
|
if ip in sharenfs:
|
||||||
LOG.debug('Access to Share %(share)s via NFS '
|
LOG.debug('Access to share %(share)s via NFS '
|
||||||
'already granted to %(ip)s.',
|
'already granted to %(ip)s.',
|
||||||
{'share': share,
|
{'share': share,
|
||||||
'ip': ip})
|
'ip': ip})
|
||||||
|
Loading…
Reference in New Issue
Block a user