code wiki / _hdl_build / nx_hr_migrate.nx
nx_hr_migrate.nx
buildroot/runtime/_hdl_build/nx_hr_migrate.nx
about
nx_hr_migrate.nx -- the LOSSLESS migrator the torrent/HR teams need for THEIR base-nx_hr cutover (operator: "if they
dont have the capabilities work with them to build them from the hardware rung up"). Reads an existing nx_hr TAB-log
(cred_id<TAB>handle<TAB>level<TAB>family<TAB>status<TAB>ts<TAB>actor, append-only) and replays EVERY line through
hrs_migrate into a sovereign nx_seg_store -- so ALL versions (history) survive and latest-wins is preserved. Pure
library (no main -> no duplicate-symbol when a gate/tool imports it). IDEMPOTENT (hrs_migrate auto-segids by content,
re-running a record is a no-op). This is the de-risking tool: prove it lossless (nx_hr_migrate_gate), hand it to the
team, they flip base nx_hr -> seg_store + run this on their live roles store at cutover. [[feedback-no-3rd-party-tsv-sovereign-store]]
dependencies 3 imports · 1 importers
imports: nx_hr.nxnx_hr_sov.nxnx_syscalls.nx
imported by: nx_hr_migrate_gate.nx
structs
| none |
consts
| 12 | const HRM_BUF: i64 = 1048576 |
functions
| 14 | func hrm_dup(buf: *u8, start: i64, len: i64, out: *u8) -> i64 { var i: i64=0; while i<len { out[i]=buf[start+i]; i=i+1 } out[len]=0 as u8; return len } called by 1: hrm_migrate |
| 17 | func hrm_migrate(logpath: *u8, prefix: *u8) -> i64 |