Skip to content

Test gap: no multi-node IT covers group / API-token seeding of a newly-added peer #7524

Closed

Description

@robfrank

Raised by the claude-review on PR #7513 (issue #7373).

Two multi-node tests exercise PostAddPeerHandler today, and both assert only the users half:

  • ha-raft/src/test/java/com/arcadedb/server/ha/raft/RaftUserSeedOnPeerAdd3NodesIT.java
  • e2e-ha/src/test/java/com/arcadedb/containers/ha/UserSeedOnPeerAddScenarioIT.java

#7373 made addPeer seed the group document and the API-token document as well, and #7513 then moved all three
reads under the ServerSecurity monitor (a seed that read the document before a revocation and submitted it
after would have restored the revoked token on every node). Both changes are covered at unit level - against a
fake HAServerPlugin in Issue7373ClusterWideGroupsAndTokensTest - but nothing drives the real handler through
a real cluster.

What is not covered

  1. A peer added to a live cluster answers a group-gated request with the cluster's permissions rather than
    whatever its own server-groups.json holds.
  2. The same for an API token: a token minted on the leader before the join authenticates against the new peer.
  3. The revocation direction, which is the one that matters: a token revoked before the join must NOT
    authenticate against the new peer.
  4. The "warning" field fix(#7373): replicate groups and API tokens across the cluster like users #7513 added to the addPeer response when a seed fails.

Why it was not added there

These are BaseGraphServerTest-derived (ports from 2480) or container-based, and the change that needs them is
in the seeding path, not in the transport. Writing an IT that the author cannot execute is worse than filing
this: it would land unverified and green only because nobody ran it.

Item 3 is the one worth writing first - it is the security direction, and it is the failure #7521 describes from
the other side.

Refs #7373, #7513

Activity

  1. added
    server
    ha
    e2e
    on Sep 12, 2026
  2. added a commit that references this issue on Sep 12, 2026
  3. added this to the 26.10.1 milestone on Sep 12, 2026
  4. added
    in progress
    on Sep 17, 2026
  5. self-assigned this
    on Sep 17, 2026
  6. added 2 commits that reference this issue on Sep 17, 2026
  7. removed
    in progress
    on Sep 17, 2026
  8. lvca commented on Sep 17, 2026

    @lvca
    Member

    Fixed in PR #7764 (merged).

    Added a real 3-node test that adds a peer to a live cluster and checks it correctly picks up the current permission groups and API tokens - including that a token revoked before the peer joined stays revoked, which is the direction that matters for security. No change in behavior, just test coverage that was missing.

    ❤️ Thanks for helping make ArcadeDB better! ArcadeDB is free and open source, sustained by its community. If it's useful to you or your company, please consider becoming a sponsor to keep development going.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

e2ehasecurityserver

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions