Project

General

Profile

Bug #14508

mon: drop useless rank init assignment

Added by huanwen ren about 3 years ago. Updated about 3 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
01/26/2016
Due date:
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:

Description

Monitor::Monitor(CephContext* cct_, string nm, MonitorDBStore *s,
         Messenger *m, MonMap *map) :
  Dispatcher(cct_),
  name(nm),
  rank(-1),        //already defined
  messenger(m),
  con_self(m ? m->get_loopback_connection() : NULL),
  lock("Monitor::lock"),
  timer(cct_, lock),
  has_ever_joined(false),
  logger(NULL), cluster_logger(NULL), cluster_logger_registered(false),
  monmap(map),
  log_client(cct_, messenger, monmap, LogClient::FLAG_MON),
  key_server(cct, &keyring),
  auth_cluster_required(cct,
            cct->_conf->auth_supported.empty() ?
            cct->_conf->auth_cluster_required : cct->_conf->auth_supported),
  auth_service_required(cct,
            cct->_conf->auth_supported.empty() ?
            cct->_conf->auth_service_required : cct->_conf->auth_supported ),
  leader_supported_mon_commands(NULL),
  leader_supported_mon_commands_size(0),
  store(s),

  state(STATE_PROBING),

  elector(this),
  required_features(0),
  leader(0),
  quorum_features(0),
  scrub_version(0),

  // sync state
  sync_provider_count(0),
  sync_cookie(0),
  sync_full(false),
  sync_start_version(0),
  sync_timeout_event(NULL),
  sync_last_committed_floor(0),

  timecheck_round(0),
  timecheck_acks(0),
  timecheck_event(NULL),

  probe_timeout_event(NULL),

  paxos_service(PAXOS_NUM),
  admin_hook(NULL),
  health_tick_event(NULL),
  health_interval_event(NULL),
  routed_request_tid(0)
{
  rank = -1;              //unnecessary
  ......
}

History

#2 Updated by xie xingguo about 3 years ago

  • Status changed from New to Resolved

Also available in: Atom PDF