]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
common/pick_addresses: behave even after internal_safe_to_start_threads
authorSage Weil <sage@inktank.com>
Mon, 24 Jun 2013 19:52:44 +0000 (12:52 -0700)
committerSage Weil <sage@inktank.com>
Mon, 24 Jun 2013 23:16:42 +0000 (16:16 -0700)
commit4d57c12faceb7f591f10776c6850d98da55c667b
tree9a17822481c52571783eb0c28266249691f4b87f
parente1ac7c6c3ca673d08710829aa5a3c03735710486
common/pick_addresses: behave even after internal_safe_to_start_threads

ceph-mon recently started using Preforker to working around forking issues.
As a result, internal_safe_to_start_threads got set sooner and calls to
pick_addresses() which try to set string config values now fail because
there are no config observers for them.

Work around this by observing the change while we adjust the value.  We
assume pick_addresses() callers are smart enough to realize that their
result will be reflected by cct->_conf and not magically handled elsewhere.

Fixes: #5195, #5205
Backport: cuttlefish
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
(cherry picked from commit eb86eebe1ba42f04b46f7c3e3419b83eb6fe7f9a)
src/common/pick_address.cc