"""Delete a target."""
raise NotImplementedError()
- def _show_target(self, tid, **kwargs):
+ def show_target(self, tid, iqn=None, **kwargs):
"""Query the given target ID."""
raise NotImplementedError()
os.unlink(volume_path)
- def show_target(self, tid, **kwargs):
- iqn = kwargs.get('iqn', None)
-
+ def show_target(self, tid, iqn=None, **kwargs):
if iqn is None:
raise exception.InvalidParameterValue(
err=_('valid iqn needed for show_target'))
def _new_target(self, name, tid, **kwargs):
self._run('--op', 'new',
- '--tid=%s' % tid,
- '--params', 'Name=%s' % name,
- **kwargs)
+ '--tid=%s' % tid,
+ '--params', 'Name=%s' % name,
+ **kwargs)
def _delete_target(self, tid, **kwargs):
self._run('--op', 'delete',
'--tid=%s' % tid,
**kwargs)
- def show_target(self, tid, **kwargs):
+ def show_target(self, tid, iqn=None, **kwargs):
self._run('--op', 'show',
'--tid=%s' % tid,
**kwargs)