myxce/src/controller
Rongsong Shen 93b8616f11 fix: capture am_i_primary() result once; set ha->role before phase2; cluster_init wrapper cleanup on failure
- myapp.c: capture am_i_primary() into is_primary (avoids redundant
  second probe call); after load_primary_config() succeeds, record
  CTRL_PRIMARY role via atomic_store_explicit so cluster_init_phase2()
  sees the correct role (ha_init() defaults to CTRL_STANDBY)
- myapp.c: add #include "ha.h" for CTRL_PRIMARY, atomic_store_explicit,
  and memory_order_release
- cluster.c: cluster_init() wrapper now calls cluster_fini(c) before
  returning on create_ssl_context failure, hook failure, and
  cluster_init_phase2 failure — prevents SSL ctx and phase1 resource leak
2026-05-13 17:32:32 +00:00
..
include feat: split cluster_init() into phase1/phase2; update myapp_run() for two-phase startup with am_i_primary gating 2026-05-13 17:06:45 +00:00
testsuite feat: implement real am_i_primary() with election probing, ha_is_primary(), ha_check_priority_stepdown() 2026-05-13 16:39:59 +00:00
apiserver.c controller will pass resource <name, value> pair than <idx, value> pair 2026-05-13 07:18:03 +00:00
CLAUDE.md Merge Go frontend (apiserver + xcecli) into meson build 2026-04-14 11:23:18 +08:00
cluster.c fix: capture am_i_primary() result once; set ha->role before phase2; cluster_init wrapper cleanup on failure 2026-05-13 17:32:32 +00:00
config_repl.c feat: split cluster_init() into phase1/phase2; update myapp_run() for two-phase startup with am_i_primary gating 2026-05-13 17:06:45 +00:00
config_repl.h feat: split cluster_init() into phase1/phase2; update myapp_run() for two-phase startup with am_i_primary gating 2026-05-13 17:06:45 +00:00
ctrl_metrics.c feat: P3-7 ctrl_metrics — 7 atomic counters/gauges + descriptor table + persist wiring 2026-05-08 00:04:06 +00:00
dataex.c controller will pass resource <name, value> pair than <idx, value> pair 2026-05-13 07:18:03 +00:00
ha.c fix: capture SSL_get_error once per retry; lock ha->lock in ha_check_priority_stepdown 2026-05-13 16:44:55 +00:00
ha.h fix: resolve probe_ctx_t type tag, add DEFAULT_MAX_WAL_RECORDS macro, fix atomic type consistency, move ha_seed_jitter to ha.c, add API doc comments 2026-05-13 14:27:07 +00:00
job.c feat: implement job state, queue state, and worker recovery in WAL replay 2026-05-08 08:19:20 +00:00
join.c fix: correct controller restart recovery — jobs, workers, and resource ordering 2026-05-09 03:02:39 +00:00
main.c fix: validate --conf-keep-n >= 1 and --conf-stale-timeout >= 0 in argument parsing 2026-05-13 16:00:09 +00:00
meson.build feat: add config_repl Phase 1 — HEAD-file storage, SHA-256, trim, stale check, sanitise_cn 2026-05-13 15:45:28 +00:00
misc.c save works 2026-03-05 16:03:37 +08:00
myapp.c fix: capture am_i_primary() result once; set ha->role before phase2; cluster_init wrapper cleanup on failure 2026-05-13 17:32:32 +00:00
myconf.c feat: split cluster_init() into phase1/phase2; update myapp_run() for two-phase startup with am_i_primary gating 2026-05-13 17:06:45 +00:00
opget.c controller will pass resource <name, value> pair than <idx, value> pair 2026-05-13 07:18:03 +00:00
opupd.c save works 2026-03-03 16:49:26 +08:00
persist.c fix: correct controller restart recovery — jobs, workers, and resource ordering 2026-05-09 03:02:39 +00:00
queue.c feat: implement job state, queue state, and worker recovery in WAL replay 2026-05-08 08:19:20 +00:00
repl.c feat: P2-5 repl_start/complete_catchup, repl_needs_snapshot — standby catch-up state 2026-05-07 18:14:12 +00:00
reply.c controller will pass resource <name, value> pair than <idx, value> pair 2026-05-13 07:18:03 +00:00
resources.c update controller code 2025-11-05 16:58:57 +08:00
sched.c controller will pass resource <name, value> pair than <idx, value> pair 2026-05-13 07:18:03 +00:00
task.c save works 2026-03-04 18:18:53 +08:00
worker.c fix: preserve admin-set host state across worker re-registration in makeWorker_ 2026-05-13 10:38:39 +00:00