]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
common/config: change type of osd_mon_ack_timeout from int to double 10526/head
authorxie xingguo <xie.xingguo@zte.com.cn>
Mon, 1 Aug 2016 08:51:38 +0000 (16:51 +0800)
committerxie xingguo <xie.xingguo@zte.com.cn>
Mon, 1 Aug 2016 22:54:57 +0000 (06:54 +0800)
commit966c7c2bc43a79ba8fc6d246164f751444d11adc
treebfdcbc9962659afbc58393e14cee5b9694596a2a
parent4ff6c8190f7de9320d148963521bc14320788135
common/config: change type of osd_mon_ack_timeout from int to double

We may use osd_mon_ack_timeout the following way:
  double backoff = stats_ack_timeout / g_conf->osd_mon_ack_timeout;
which is at risk of precision lost.

Example:

main()
{
  double r = 5 / 30;
  cout << "r = " << r << std::endl;
}

Output:
  r = 0

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
src/common/config_opts.h