Skip to content

Gate diagnostics behind the app master switch and mask trace output - #203

Merged
bedipritpal merged 4 commits into
FiveTechSoft:mainfrom
bedipritpal:stage4/diagnostics-gate-trace-pr
Nov 22, 2026
Merged

bedipritpal merged 4 commits into
FiveTechSoft:mainfrom
bedipritpal:stage4/diagnostics-gate-trace-pr

Conversation

@bedipritpal

Copy link
Copy Markdown
Collaborator

Summary

  • One application-controlled master switch (OAds_SetLogging /
    OAdsSetLogging) now gates all client diagnostics: wire trace, ARC
    trace, create-table/index diagnostics, CDX lock diagnostics,
    error/audit logs and diagnostic stderr. Default OFF; no environment
    variable or INI entry can enable it. Existing env/INI selectors behave
    exactly as before once the application enables the master, and turning
    the master off silences an already-installed wire hook.
  • The standalone server gets its own admin-owned switch: diagnostics=true
    in the server config file, default OFF when absent, never settable from
    the environment. OPDUMP sampling cannot start while the master is off.
  • Trace output masks real table names, paths, filename-derived aliases,
    index expressions, SQL and raw error text; explicitly set aliases stay
    readable.
  • Wire trace adds fixed-width columns, an optional compact frame-only
    mode, a caller column naming the synchronous ACE entry and dispatch
    reason, and application trace markers (OAds_TraceMark, with optional
    instance/thread IDs).
  • No storage, wire-protocol, locking-policy or navigation changes. API
    error returns, operational startup/shutdown messages and recovery
    journals are unchanged.

Test plan

  • New diagnostics_gate_contract: client master matrix (env/INI/both x
    default/off/on/lifecycle/late), masking canaries, compact/full frame
    parity, explicit-false selector handling, plus a separate-process
    standalone-server boundary (default/off/admin-on with live requests;
    env and client-INI enable attempts rejected; admin config honored).
  • New trace_marker_contract; new wire-caller and frame-trace unit cases;
    existing diagnostics-surface unit tests opt into the master and assert
    the masked contract.
  • All 684 public ACE entry points carry caller scopes.
  • Fork review CI on this content: standard CTest selection with soak and
    repository flaky/slow exclusions, plus explicit contract reruns. Green.

Notes

  • Local validation is Linux-only; Windows and macOS coverage is whatever
    this PR's CI provides.
  • Broad runs including the repo's flaky-tagged cases show failures
    (replication DELETE assertions, MT contention, exclusive-held
    OpenIndex) also observed and reproduced on the base commit without
    these changes; the replication cases pass in isolation

…ce markers

Port the application-controlled diagnostics design: OAdsSetLogging master
default OFF with no env/INI enable, env/INI only select channels after the
app opts in; server master from admin-owned config only. Mask table names,
paths, aliases, usernames, SQL and raw error detail in every diagnostic
sink (cli_trace, server wire trace, audit channel, error log, create
diagnostics, startup failures). Add compact/full client wire trace columns,
scoped ACE caller provenance, and local application markers
(OAdsTraceMark/Ex, OAds_TraceMark). Include the gate-contract, marker and
frame-hook tests. Server open-phase timing capture is NOT included.
OPENADS_LOCK_DIAG output now requires the application master and hides
paths and raw error text; the byte-lock timeout print is likewise gated.
Caught by the gate-contract canary matrix.
@bedipritpal
bedipritpal merged commit c649054 into FiveTechSoft:main Nov 22, 2026
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant