Replaces uuid.uuid4 with uuidutils.generate_uuid()
Openstack common has a wrapper for generating uuids.We should use that function when generating uuids for consistency. Change-Id: Ifb7b15fc8634338fc535de8043053e41aa93968a Closes-Bug: #1082248
This commit is contained in:
parent
2c751474e5
commit
ef6c1cb9ce
@ -16,14 +16,15 @@ import collections
|
||||
import functools
|
||||
import inspect
|
||||
import threading
|
||||
import uuid
|
||||
|
||||
from oslo_log import log
|
||||
from oslo_utils import uuidutils
|
||||
import six
|
||||
|
||||
from ironic_python_agent import encoding
|
||||
from ironic_python_agent import errors
|
||||
|
||||
|
||||
LOG = log.getLogger()
|
||||
|
||||
|
||||
@ -48,7 +49,7 @@ class BaseCommandResult(encoding.SerializableComparable):
|
||||
:param command_params: parameters passed to command
|
||||
"""
|
||||
|
||||
self.id = six.text_type(uuid.uuid4())
|
||||
self.id = uuidutils.generate_uuid()
|
||||
self.command_name = command_name
|
||||
self.command_params = command_params
|
||||
self.command_status = AgentCommandStatus.RUNNING
|
||||
|
Loading…
Reference in New Issue
Block a user