refactor(frontier): remove org_id from group RPC requests#490
Conversation
|
The latest Buf updates on your PR. Results from workflow Validate / validate (pull_request).
|
📝 WalkthroughWalkthroughThis change modifies Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
raystack/frontier/v1beta1/frontier.proto (1)
2112-2117: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winReserve the field name in addition to the number.
You reserve the freed field number but not the name. Reserving the name (
reserved "org_id";) prevents accidental reuse oforg_idin a way that breaks JSON/text-format compatibility. This applies consistently to all eight messages in this change (GetGroupRequest,UpdateGroupRequest,ListGroupUsersRequest,EnableGroupRequest,DisableGroupRequest,DeleteGroupRequest,RemoveGroupUserRequest,SetGroupMemberRoleRequest).♻️ Example for GetGroupRequest
message GetGroupRequest { - reserved 2; + reserved 2; + reserved "org_id"; string id = 1; bool with_members = 3; }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@raystack/frontier/v1beta1/frontier.proto` around lines 2112 - 2117, The protobuf messages in this change reserve the old field number but not the removed field name, so update each affected request type to reserve the original name as well as the number. In the relevant message definitions for GetGroupRequest, UpdateGroupRequest, ListGroupUsersRequest, EnableGroupRequest, DisableGroupRequest, DeleteGroupRequest, RemoveGroupUserRequest, and SetGroupMemberRoleRequest, add the reserved field name alongside the existing reserved tag to prevent reuse of org_id and preserve JSON/text-format compatibility.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@raystack/frontier/v1beta1/frontier.proto`:
- Around line 2112-2117: The protobuf messages in this change reserve the old
field number but not the removed field name, so update each affected request
type to reserve the original name as well as the number. In the relevant message
definitions for GetGroupRequest, UpdateGroupRequest, ListGroupUsersRequest,
EnableGroupRequest, DisableGroupRequest, DeleteGroupRequest,
RemoveGroupUserRequest, and SetGroupMemberRoleRequest, add the reserved field
name alongside the existing reserved tag to prevent reuse of org_id and preserve
JSON/text-format compatibility.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 5d4df7ae-d1d1-4534-b3ac-bc1dd004b27c
📒 Files selected for processing (1)
raystack/frontier/v1beta1/frontier.proto
No description provided.