Bug #41406
opencommon: SafeTimer reinit doesn't fix up "stopping" bool, used in MonClient bootstrap
0%
Description
1, New a object of SafeTimer().
2, call init.
3, call add_event_after.
4, call shutdown.
5, call init again.
6, call add_event_after again.
The event can't be added. Because the stopping is True.
I think it should set stopping to false in init function.
Files
Updated by Patrick Donnelly over 4 years ago
- Subject changed from [common-SafeTimer]It shoule reinit stopping to false in init function. to common: reinit stopping to false in init function.
- Status changed from New to Need More Info
- Target version set to v15.0.0
- Start date deleted (
08/23/2019)
Does any code actually do that sequence of events. I would think a SafeTimer should not be re-inited after shutdown.
Updated by haitao chen over 4 years ago
Patrick Donnelly wrote:
Does any code actually do that sequence of events. I would think a SafeTimer should not be re-inited after shutdown.
In monclient.c::get_monmap_and_config()
It will call safetimer.shutdown in monclient::shutdown() and it will call safetimer.init in monclient::init() again.
Updated by Greg Farnum over 4 years ago
- Project changed from Ceph to RADOS
- Category deleted (
common) - Status changed from Need More Info to 12
- Component(RADOS) MonClient added
That's a weird one; perhaps the MonClient should behave differently instead.
(Note that this is a problem only on initial startup; we don't call that function in ongoing usage.)
Updated by Greg Farnum over 4 years ago
- Subject changed from common: reinit stopping to false in init function. to common: SafeTimer reinit doesn't fix up "stopping" bool, used in MonClient bootstrap