Skip to main content

Versioning

Archenstack versions two independent things, and keeping them separate is the whole point of this document. Section references (§n) point at specification, which is normative.

  • Library versions — each implementation (the Python, Node, Go, and Rust cores, the Java core + Spring starter, the Django adapter, and the TypeScript web library) is a package with its own semver MAJOR.MINOR.PATCH.
  • Wire version — a single integer stamped on every payload (wire_version), governing the serialized format and the resolution semantics.

These move on different clocks. A library can ship many semver releases — bug fixes, new adapters, ergonomic APIs — while the wire version stays at 1, as long as none of them changes how a snapshot resolves.

1. Libraries use semver​

Each package follows ordinary semantic versioning:

  • PATCH — backwards-compatible bug fixes, doc changes, internal refactors.
  • MINOR — backwards-compatible additions to the library's public API.
  • MAJOR — a backwards-incompatible change to the library's API surface (renamed function, removed export, changed signature).

A library MAJOR bump is about that library's API. It is not the same as a wire change and does not by itself imply one — and, conversely, a wire change does not automatically force a library MAJOR (see the matrix below).

2. The wire has an integer wire_version​

Every wire payload carries an integer wire_version (§15). Version 1 is the first published version. There is no minor/patch on the wire — additive, non-semantic changes happen within a wire version; anything else bumps the integer.

An implementation MUST reject a payload whose wire_version it does not support rather than best-effort parse it (§2.3).

3. Resolution semantics are pinned to the wire MAJOR version​

This is the load-bearing rule (§2). Clients resolve snapshots locally — the TypeScript library ships a real resolving engine, not a thin display layer, so it computes effective levels without a server round-trip. That means the resolution semantics are part of the wire contract: if a server and a client disagreed about how a snapshot resolves, they would silently reach different access decisions.

Therefore:

Any change to resolution semantics is BREAKING and MUST bump wire_version. It is never an additive change.

"Resolution semantics" includes, without limitation (§2.2):

  • the role hierarchy / precedence order (super → alias → override → default → fallback, §7);
  • the meaning or precedence of explicit deny, superusers, or aliases;
  • the ScopeExpr grammar, eval_scope edge identities, or the fail-closed rule (§8);
  • whether a scoped read changes a decision (it does not, in v1);
  • the canonical-JSON algorithm (§13), the wire envelope (§15), or the AccessLevel integer mapping (§3).

Because old clients resolve locally, they must be rejected rather than fed a snapshot they would resolve under stale semantics — a new wire major is a hard break, and a migration note goes in changelog.

What MAY change additively within wire_version: 1 (§2.3)​

Changes that cannot alter the decision a v1 resolver reaches for an existing snapshot:

  • adding new roles, features, groups, or overrides to a snapshot;
  • adding new OPTIONAL fields a v1 reader ignores (e.g. the reserved per-cell scope slot §5.4, or UI-hint metadata), provided a v1 reader that ignores them still resolves identically;
  • adding new ErrorCode members used only in error payloads (an unrecognized code is treated as a generic failure).

4. Compatibility matrix​

Wire version ⇄ the library versions that implement it. A library row is compatible with a wire version when it reads/writes that version's payloads and resolves them under that version's semantics.

Wire versionSpec versionLibrary versions
10.6.01.0.x

Every library tracks that one row. The cores — archenstack-rbac (Python), archenstack-rbac-nodejs, archenstack-rbac-go, archenstack-rbac-rust, archenstack-rbac-java — the archenstack-rbac-django adapter and the @archenstack/rbac-web client release in lockstep against the shared conformance corpus, so one library version line covers all of them.

Earlier rows are deliberately absent. The versions published before the suite was renamed have been withdrawn, so nothing resolves them and a compatibility row for them would describe coordinates no registry holds. Each library's own changelog keeps that history under a heading saying so.

Notes:

  • Every library is at 1.0.0 and speaks wire_version: 1.
  • The spec is versioned with semver independently of the libraries and is at 0.6.0. No spec release so far has changed resolution semantics or wire_version (see changelog).
  • The libraries' 1.0.0 is the first release under the Archenstack name. It is library-side breaking and wire-compatible: the active-organization request header is now X-Archenstack-Org, which every client and every adapter has to agree on at once. Resolution semantics, the access-level ordering and the serialized shapes are unchanged, so wire_version stays 1.
  • Go's module path is a standing constraint on any future major bump. Go's semantic import versioning makes a major a module path change: a v2 module must be imported as github.com/archenstack/archenstack-rbac-go/v2, with the monorepo tag archenstack-rbac-go/v2/vX.Y.Z. Bumping Go purely to preserve lockstep would force every consumer to rewrite imports for a library in which nothing broke, so if that ever conflicts, lockstep yields — it is a convention, and the conformance corpus is what actually governs interoperability.
  • Spec 0.2.0 adds multi-org tenancy as an additive-optional change: an OPTIONAL org field on the me / policy / policy-batch envelopes, an additive unknown_org ErrorCode, and per-org uniqueness/anti-lockout — all of which a v1 reader that ignores the new field resolves identically. org is an out-of-band snapshot-selection dimension, never part of the canonical matrix body, so wire_version stays 1 and the entire existing conformance corpus (vectors + wire-golden) is unchanged. This is a spec MINOR bump, not a wire bump (specification §2.3, §Organizations).
  • Spec 0.3.0 adds the control plane (org/app lifecycle, the platform capability above per-org rbac.manage, an app = a registered OIDC client bound to an org, and the member registry as the subject source of truth) as another additive-optional change: two new list-envelope kinds members / apps (mirroring the shipped orgs / assignments collection envelopes) and an OPTIONAL is_platform_admin boolean on the me envelope. None of it touches resolve, Cell, the canonical matrix body, or matrix.schema.json required[], so wire_version stays 1 and the existing conformance corpus is unchanged — a spec MINOR bump, not a wire bump (specification §2.3, §15.3).
  • When a future change bumps the wire to 2, this table gains a 2 row and the libraries that support it; libraries pinned to wire 1 stay in the 1 row and a wire-2 server MUST reject them.

5. Practical guidance​

  • Adding a role/feature/override to your policy? Additive — no wire bump; a library MINOR at most if you also added API for it.
  • Fixing a bug in an adapter or client? Library PATCH; wire unchanged.
  • Changing precedence, scope grammar, canonical JSON, or the level mapping? Wire MAJOR bump, spec MAJOR, migration note, and every client updated in lockstep. This is intentionally the heaviest change you can make.