forked from lei.chen/myxce
chore: checkpoint all prior work for clean state
Captures all uncommitted work from ha-config-bootstrap, ha-heartbeat-liveness, and associated spec/tooling updates: - src: ha.c, ha.h, cluster.c, config_repl.c, myapp.c, raft.c — heartbeat liveness, RDHUP integration, committing phase fixes - tests: test_ha_role.c, test_config_repl.c, test_ha_rdhup_integration.c, test_p1_integration.c, test_p3_hardening.c, scheduler test - specs: election-iomgr-refactor, ha-heartbeat-liveness, ha-peer-connection-reuse, raft-library (new); ha-config-bootstrap and election-iomgr-refactor task/research updates - tooling: .wolf/ state, ha/data cluster fixtures, raft/raft.tla, src/build symlink, xce-build skill update
This commit is contained in:
parent
15bd291bdd
commit
e31673dd88
66 changed files with 122422 additions and 860 deletions
|
|
@ -845,7 +845,7 @@ int cluster_init_phase1(cluster_t* c)
|
|||
}
|
||||
}
|
||||
|
||||
ha_install_sigusr1(&c->ha);
|
||||
/* ha_install_sigusr1() removed — failover_requested replaced by ha_arm_heartbeat_timeout_vtask */
|
||||
|
||||
/* Initialize standby endpoint tracking */
|
||||
c->ha.standby_endpoints = (zarray_t *)calloc(1, sizeof(zarray_t));
|
||||
|
|
@ -1012,7 +1012,7 @@ int cluster_init_phase2(cluster_t* c)
|
|||
}
|
||||
}
|
||||
|
||||
/* Determine initial role based on am_i_primary() result set by myapp_run */
|
||||
/* Role set by ha_elect_evaluate_and_signal() inside cluster_run() */
|
||||
if (ha_is_primary(&c->ha))
|
||||
ha_promote_to_primary(c);
|
||||
else
|
||||
|
|
@ -1257,12 +1257,8 @@ int cluster_start(cluster_t* c)
|
|||
return rc;
|
||||
}
|
||||
|
||||
/* Start HA heartbeat watchdog thread — P1-5 */
|
||||
rc = ha_start_watchdog(&c->ha);
|
||||
if (rc != 0) {
|
||||
ERROR("ha_start_watchdog failed: %d", rc);
|
||||
return rc;
|
||||
}
|
||||
/* ha_start_watchdog() removed — watchdog pthread replaced by
|
||||
* ha_arm_heartbeat_timeout_vtask (delaymgr) */
|
||||
|
||||
delay_task(&(c->delaymgr), c->myconf->cluster_config->heartbeat_interval,
|
||||
-1, (delay_task_entry_fn_t)check_workers_timeout, (void*)c);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue