There's a movement to remove gen_uuid from the
openstack common. This change removes it's use
from Cinder and just puts the call inline.
Change-Id: I07329bab9553e15e498ddbda3848d50b8f48fd53
import abc
import threading
+import uuid as uuidlib
import six
-from cinder.openstack.common import uuidutils
from cinder.taskflow import decorators
from cinder.taskflow import exceptions as exc
if uuid:
self._id = str(uuid)
else:
- self._id = uuidutils.generate_uuid()
+ self._id = str(uuidlib.uuid4())
@property
def name(self):
import threading
import time
import types
+import uuid as uuidlib
-from cinder.openstack.common import uuidutils
from cinder.taskflow import decorators
self.runs_before = []
self.result = None
if not uuid:
- self._id = uuidutils.generate_uuid()
+ self._id = str(uuidlib.uuid4())
else:
self._id = str(uuid)
"""
import array
+import uuid
from cinder import exception
from cinder.keymgr import key
from cinder.keymgr import key_mgr
-from cinder.openstack.common import uuidutils
from cinder import utils
return self.store_key(ctxt, key)
def _generate_key_id(self):
- key_id = uuidutils.generate_uuid()
+ key_id = str(uuid.uuid4())
while key_id in self.keys:
- key_id = uuidutils.generate_uuid()
+ key_id = str(uuid.uuid4())
return key_id