diff --git a/manila/scheduler/host_manager.py b/manila/scheduler/host_manager.py index 286c0fb584..9bb3f40d3b 100644 --- a/manila/scheduler/host_manager.py +++ b/manila/scheduler/host_manager.py @@ -455,6 +455,7 @@ class PoolState(HostState): provisioned_capacity += instance['size'] or 0 return provisioned_capacity + @utils.synchronized("update_from_share_capability") def update_from_share_capability( self, capability, service=None, context=None): """Update information about a pool from its share_node info.""" diff --git a/releasenotes/notes/fix-issue-about-provisioned_capaciti_gb-is_None-d700c0544a8a88e8.yaml b/releasenotes/notes/fix-issue-about-provisioned_capaciti_gb-is_None-d700c0544a8a88e8.yaml new file mode 100644 index 0000000000..d3550a02eb --- /dev/null +++ b/releasenotes/notes/fix-issue-about-provisioned_capaciti_gb-is_None-d700c0544a8a88e8.yaml @@ -0,0 +1,8 @@ +--- +fixes: + - | + Added synchronized lock to fix issue where provisioned_capacity_gb value + was initialized to None immediately on another thread while checking + capacity filter, causing shared creation to fail due to conflicting + provisioned_capacity_gb updates. + please refer to `launchpad bug #1871768 `_.