Add opt-in managed GUID alarm-ack path #160
Reference in New Issue
Block a user
Delete Branch "feat/managed-guid-alarm-ack"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Adds a managed acknowledge path over AVEVA's modern alarm client so GUID acks carry full operator identity (domain + full name) and work on builds where the wnwrap COM
AlarmAckByGUIDisE_NOTIMPL.Default off — opt in with
MXGATEWAY_USE_MANAGED_ALARM_ACK=1; wnwrap behavior is unchanged otherwise.Changes
AaManagedAlarmAckConsumer— reflection wrapper overaaAlarmManagedClient.AlarmClient(InitializeConsumer/RegisterConsumer/Subscribe/AlarmAckByGUID).EnvGatedFactorydegrades to the wnwrap path if the DLL can't load, so alarm reads never break.IManagedAlarmAckClientseam.AlarmDispatchertakes an optional client and routes GUID acks to it (subscribing + disposing it alongside the reader).AlarmCommandHandlergains an optionalmanagedAckFactory;WorkerPipeSessionwiresAaManagedAlarmAckConsumer.EnvGatedFactoryat the production sites.WnalNativeAckConsumer— confirmed nativealarmlst.dllWNAL submit layer (WNALalarmReqSetText/WNALUserRequest/WNALUserRequestEx+lpAlmAcklayout). List acquisition is intentionally not hand-rolled: the alarm-record layout and selection semantics are provider-defined and not recoverable fromalarmlst.dll, so inferring them would risk acking the wrong alarm.AlarmManagedGuidAckLiveSmokeTests— skip-gated live smoke that pulls a real (non-degraded) alarm GUID and asserts the ack applies (Acknowledge transition / acked snapshot), not merelyrc=0.By-name acks stay on wnwrap (
AlarmClienthas noAlarmAckByName).Validation
TreatWarningsAsErrors).Notes / runtime confirmation still needed
RegisterConsumer's trailingboolis passedfalse(meaning unconfirmed).Subscribeis strictly required beforeAlarmAckByGUID.MxSecurityOperate) alarm the ack must run under an authenticated operator;rc=0means accepted, not applied. The new smoke test is the harness for this.Grounded in static RE of
alarmlst.dll,aaAlarmManagedClient.dll, andalarmmgr.exe.🤖 Generated with Claude Code
Merged into main as
6c82de55c6(with review fix commit6f4c7c3: subtag-mode acks stay on the subtag consumer, managed lifecycle failure falls back to wnwrap, stale crefs removed, tests + docs). x86 Worker.Tests on windev: 533 passed, 0 failed.Pull request closed