Skip to content

dir-sim: a group's secondary proxies claim in the provisioning plane - #1480

Merged
AdaWorldAPI merged 1 commit into
mainfrom
ccr-0455e606-wmtsor
Oct 11, 2026
Merged

AdaWorldAPI merged 1 commit into
mainfrom
ccr-0455e606-wmtsor

Conversation

@AdaWorldAPI

@AdaWorldAPI AdaWorldAPI commented Oct 11, 2026 •

Copy link
Copy Markdown
Owner

Follow-up to #1477, which merged before its review fix was pushed. This is that fix (Codex P1 on #1477).

A mail-enabled group's secondary smtp: proxy was invisible to provisioning_conflicts, because the snapshot kept proxy rows for users only and the plane read a group's primary SMTP alone.

  • Snapshot keeps the groups' proxyAddresses as their own relation (group_proxies, owner = group ordinal).
  • provisioning_conflicts adds each live group's secondary SMTP rows to the claim plane.
  • Delivery is unchanged: address_owner still reads a group by its primary address only. That a group's secondary address delivers nowhere today is a separate, open delivery gap; it will be its own red/green change.

Tests

a_groups_secondary_proxy_claims_its_address: a group's smtp: proxy colliding with a user's primary is reported, and the user still owns the address for delivery. Red with the relation present but unread, green after; the disable run (loop skipped) is red. Full cargo test -p lance-graph-dir-sim --all-features green; clippy clean.

🤖 Generated with Claude Code

https://claude.ai/code/session_01G22yT6htkcdyXsihxxXdrg


Generated by Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Group secondary SMTP addresses are now included in provisioning conflict checks, so address collisions with other objects are reported accurately.
    • Conflicts identify each object’s claim while preserving the existing Exchange address owner.

Review (Codex P1): a mail-enabled group's secondary smtp: proxy was
invisible to provisioning_conflicts, because the snapshot kept proxy
rows for users only and the plane read a group's primary SMTP alone.
The snapshot now keeps the groups' proxyAddresses as their own relation
(group_proxies, owner = group ordinal), and the provisioning plane adds
each live group's secondary SMTP rows. Delivery is unchanged: it still
reads a group by its primary address only.

Test a_groups_secondary_proxy_claims_its_address: red with the relation
present but unread, green after; address_owner still answers the user.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01G22yT6htkcdyXsihxxXdrg
@AdaWorldAPI
AdaWorldAPI marked this pull request as ready for review October 11, 2026 09:35
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-11T09:37:21.088973Z d1e9665 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 4eaaa747-4deb-4a17-9149-8e54ad6a9dcd


📥 Commits

Reviewing files that changed from the base of the PR and between f5ba476 and d1e9665.



📒 Files selected for processing (3)
  • crates/lance-graph-dir-sim/src/snapshot.rs
  • crates/lance-graph-dir-sim/src/validate.rs
  • crates/lance-graph-dir-sim/tests/provisioning.rs


Included review availability: This review used your included allowance. 0 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 1 review per hour.




📝 Walkthrough
📝 Walkthrough

Walkthrough

The snapshot now stores group proxy addresses for provisioning. Provisioning conflict detection includes secondary SMTP claims from live groups and reports conflicts with other objects' claims.

Changes

Group proxy claims

Layer / File(s) Summary
Build and store group proxy relation
crates/lance-graph-dir-sim/src/snapshot.rs
Snapshot::build creates and stores a proxy relation for groups. It returns TooManyProxies when the relation has at least u32::MAX rows.
Include group proxies in conflict detection
crates/lance-graph-dir-sim/src/validate.rs, crates/lance-graph-dir-sim/tests/provisioning.rs
provisioning_conflicts adds live groups' secondary SMTP claims and sorts and deduplicates the combined claims. A test checks a conflict between a group's secondary proxy and a user's primary SMTP claim.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Suggested reviewers: claude



Merge Risk: ⚪ Minimal · up to d1e96

Group secondary SMTP claims appear correctly represented in provisioning conflict detection. No issue identified here prevents merging.

Pre-merge checks | Passed 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 3 files.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly identifies the main change: adding group secondary proxy claims to the provisioning plane.

✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR



  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit checks the address list,
A group proxy joins the claims.
The user keeps the primary spot,
Both roles appear when keys collide.
The snapshot holds the paths in place,
Then hops away through fields of lace.

Comment @coderabbitai help to get the list of available commands.

@AdaWorldAPI
AdaWorldAPI merged commit d025754 into main Oct 11, 2026
10 checks passed
AdaWorldAPI pushed a commit that referenced this pull request Oct 11, 2026
Exchange delivers mail sent to any of a distribution group's SMTP
proxies, but the address space read a group by its primary address only:
mail to a group's secondary proxy resolved to no one. rows_over now adds
each live, observed group's secondary SMTP proxies, so address_owner and
address_recipient answer the group, and validate's address rules see the
same rows (Exchange refuses an address another object holds).

provisioning_conflicts read the group proxies in a loop of its own; that
loop is now part of rows_over, so the two planes keep one definition of a
group's claims. The provisioning plane is otherwise unchanged.

Behaviour change, pinned both ways: mail_to_a_groups_secondary_proxy_
reaches_the_group (red before: Ok(None)); a_groups_secondary_proxy_
claims_its_address now expects an AddressConflict where it pinned the
user as owner, since the user and the group share the key.

Board: D-DSV-1 shipped (#1477, #1480); D-DSV-2 added.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01G22yT6htkcdyXsihxxXdrg
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.

2 participants