Found while reviewing the Edge Cookie provider work in
PR #1043. The
settings predate that pull request and are present on main.
The problem
[ec] cluster_trust_threshold and [ec] cluster_recheck_secs are accepted in
the operator configuration, given defaults, and described in the operator guide
as controlling identity decisions. No code reads either value. An operator can
set both, see the application start cleanly, and get no behavior change at all.
What was checked and found
Read on main at commit d516a9e94 and again on the
PR #1043 branch. Both
trees carry the same settings, defaults and documentation. The line numbers
below are from the branch tree, so they sit roughly 30 lines below the matching
lines on main.
crates/trusted-server-core/src/settings.rs:525-537 declares both fields with
serde defaults, and :560-570 supplies the default values, being 10 and
3600.
- A workspace search for
cluster_trust_threshold and cluster_recheck_secs
finds matches only in settings.rs, in docs/, and in
trusted-server.example.toml. There is no read anywhere in crates/.
- The doc comment on
cluster_trust_threshold says entries at or below the
value "are treated as individual users for identity resolution" and tells B2B
publishers to raise it to 50 or more. Nothing compares any value against it.
docs/guide/configuration.md:510 repeats that claim to operators.
trusted-server.example.toml:93-94 repeats it again in a commented example.
cluster_size itself is real. It is computed in
crates/trusted-server-core/src/ec/kv.rs:683-771, stored on the identity
graph entry, and reported in the identify response
(crates/trusted-server-core/src/ec/identify.rs:87-155). It gates nothing.
cluster_recheck_secs is the milder of the two, because its own doc comment
in settings.rs:531-535 already admits the value is not used. The operator
guide entry still lists it as a setting.
Why it matters
An operator reading the guide believes there is a knob that decides whether a
shared network address is treated as one user. There is no such knob. The
unimplemented claim is also what would lead a reader to believe cluster_size
is a control rather than a signal reported in a diagnostic response, which is
the misreading that made the cluster count look load bearing during the
PR #1043 review.
What would resolve it
Pick one of two directions and carry it through in one change.
- Delete both fields, their defaults, their operator guide rows, and their
example configuration lines. The repository rule is that when a mechanism
goes, its parameters and documentation go in the same commit, because
documentation that outlives its mechanism reads as a working feature to the
next person.
- Implement the threshold, meaning make identity resolution actually compare
the stored cluster_size against cluster_trust_threshold, and add a test
that fails if the comparison disappears.
Direction 1 is the smaller change and matches what the code does today. Either
way, remove cluster_recheck_secs, because its own doc comment says nothing
uses it.
This issue does not depend on any pull request in the current stack and can be
picked up independently.
Note on authorship
This issue was drafted with AI assistance. Every file and line reference above
was read at the commits named. A human should review it before acting on it.
Found while reviewing the Edge Cookie provider work in
PR #1043. The
settings predate that pull request and are present on
main.The problem
[ec] cluster_trust_thresholdand[ec] cluster_recheck_secsare accepted inthe operator configuration, given defaults, and described in the operator guide
as controlling identity decisions. No code reads either value. An operator can
set both, see the application start cleanly, and get no behavior change at all.
What was checked and found
Read on
mainat commitd516a9e94and again on thePR #1043 branch. Both
trees carry the same settings, defaults and documentation. The line numbers
below are from the branch tree, so they sit roughly 30 lines below the matching
lines on
main.crates/trusted-server-core/src/settings.rs:525-537declares both fields withserdedefaults, and:560-570supplies the default values, being10and3600.cluster_trust_thresholdandcluster_recheck_secsfinds matches only in
settings.rs, indocs/, and intrusted-server.example.toml. There is no read anywhere incrates/.cluster_trust_thresholdsays entries at or below thevalue "are treated as individual users for identity resolution" and tells B2B
publishers to raise it to 50 or more. Nothing compares any value against it.
docs/guide/configuration.md:510repeats that claim to operators.trusted-server.example.toml:93-94repeats it again in a commented example.cluster_sizeitself is real. It is computed incrates/trusted-server-core/src/ec/kv.rs:683-771, stored on the identitygraph entry, and reported in the identify response
(
crates/trusted-server-core/src/ec/identify.rs:87-155). It gates nothing.cluster_recheck_secsis the milder of the two, because its own doc commentin
settings.rs:531-535already admits the value is not used. The operatorguide entry still lists it as a setting.
Why it matters
An operator reading the guide believes there is a knob that decides whether a
shared network address is treated as one user. There is no such knob. The
unimplemented claim is also what would lead a reader to believe
cluster_sizeis a control rather than a signal reported in a diagnostic response, which is
the misreading that made the cluster count look load bearing during the
PR #1043 review.
What would resolve it
Pick one of two directions and carry it through in one change.
example configuration lines. The repository rule is that when a mechanism
goes, its parameters and documentation go in the same commit, because
documentation that outlives its mechanism reads as a working feature to the
next person.
the stored
cluster_sizeagainstcluster_trust_threshold, and add a testthat fails if the comparison disappears.
Direction 1 is the smaller change and matches what the code does today. Either
way, remove
cluster_recheck_secs, because its own doc comment says nothinguses it.
This issue does not depend on any pull request in the current stack and can be
picked up independently.
Note on authorship
This issue was drafted with AI assistance. Every file and line reference above
was read at the commits named. A human should review it before acting on it.