[Bug 1588462] Related fix merged to charm-rabbitmq-server (master)
OpenStack Infra
1588462 at bugs.launchpad.net
Fri Jun 17 21:45:37 UTC 2016
Reviewed: https://review.openstack.org/331150
Committed: https://git.openstack.org/cgit/openstack/charm-rabbitmq-server/commit/?id=406c8b69a3d71f2088bb9918831b5fe88c78c376
Submitter: Jenkins
Branch: master
commit 406c8b69a3d71f2088bb9918831b5fe88c78c376
Author: Alex Kavanagh <alex at ajkavanagh.co.uk>
Date: Fri Jun 17 13:53:34 2016 +0000
Fix for multiple status_set() in assess_status()
This fixes a multiple status_set() bug in the implementation of assess_status()
on the charm, when it is determining whether it is active AND clustered.
The change hooks into the _determine_os_workload_status() directly in
charmhelpers to ensure that status_set() is only called once when
assess_status() is called.
Change-Id: Idfd93126c3edb41f83897c82ee7f20fe5f366559
Related-Bug:#1588462
--
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to cinder in Juju Charms Collection.
Matching subscriptions: charm-bugs
https://bugs.launchpad.net/bugs/1588462
Title:
Status set multiple times in OpenStack charms with optional relations
Status in ceph-radosgw package in Juju Charms Collection:
Fix Committed
Status in cinder package in Juju Charms Collection:
Fix Committed
Status in glance package in Juju Charms Collection:
Fix Committed
Status in keystone package in Juju Charms Collection:
Fix Committed
Status in neutron-api package in Juju Charms Collection:
Fix Committed
Status in neutron-gateway package in Juju Charms Collection:
Fix Committed
Status in nova-cloud-controller package in Juju Charms Collection:
Fix Committed
Status in rabbitmq-server package in Juju Charms Collection:
In Progress
Bug description:
In charms that call assess_status() on every hook execution and that have
optional relations there are two places where status_set() is called in
set_os_workload_status() and make_assess_status_func()'s _assess_status_func()
leading to a race condition in which a status may be overwritten.
For charms like nova-cloud-controller where strangely we call
set_os_workload_status() on each hook execution instead of assess_status() we
only see this during pause and resume actions which do call assess_status().
Regardless of __if__ you hit the race condition you can see the problem simply
using print statements and an update-status hook run:
'STATUS SET IN set_os_workload_status', 'active', 'Unit is ready'
'STATUS SET IN _assess_status_func()', 'active', 'Unit is ready'
If the first happened to be different the second would clobber it.
In the set_os_workload_status() stack a comparison is made against the current
status before setting status. The assess_status() stack needs to do the same
possibly by calling set_os_workload_status() itself.
The goal should be to have a single canonical source for status_set.
This will affect all OpenStack charms that have optional relations.
To manage notifications about this bug go to:
https://bugs.launchpad.net/charms/+source/ceph-radosgw/+bug/1588462/+subscriptions
More information about the Ubuntu-openstack-bugs
mailing list