cachedproperty needs to be made thread-safe (by default)
Bug #1366156 reported by
Joshua Harlow
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
taskflow |
Fix Released
|
Medium
|
Joshua Harlow | ||
0.5 |
New
|
Undecided
|
Unassigned |
Bug Description
When the cachedproperty descriptor is used in multi-threaded situations we need to be careful about multiple threads attempting to fetch and set the property that should be only created once. Currently it seems like multiple threads could call into the property and attempt to set multiple of the properties (which would be bad). Due to how cachedproperty is used (not in multi-threaded regions) we are likely not at high risk but it would be great to correct this.
Changed in taskflow: | |
importance: | Undecided → Medium |
Changed in taskflow: | |
assignee: | nobody → Joshua Harlow (harlowja) |
status: | New → In Progress |
Changed in taskflow: | |
milestone: | none → next-juno |
Changed in taskflow: | |
milestone: | next-juno → next-kilo |
Changed in taskflow: | |
status: | Fix Committed → Fix Released |
Changed in taskflow: | |
milestone: | next-kilo → none |
To post a comment you must log in.
Reviewed: https:/ /review. openstack. org/119443 /git.openstack. org/cgit/ openstack/ taskflow/ commit/ ?id=a96f49b9a5c 73985187e75ba4e ba6b946875c92a
Committed: https:/
Submitter: Jenkins
Branch: master
commit a96f49b9a5c7398 5187e75ba4eba6b 946875c92a
Author: Joshua Harlow <email address hidden>
Date: Fri Sep 5 11:50:22 2014 -0700
Ensure the cachedproperty creation/setting is thread-safe
When the cachedproperty descriptor is attached to an object
that needs to be only created/set by one thread at a time we
should ensure that this is done safely by using a lock to
prevent multiple threads from creating and assigning the
associated attribute.
Fixes bug 1366156
Change-Id: I0545683f834020 97f54c34a6b7379 04e6edd85b3