Repository navigation
PB-15775: Remove design references from proto comments - #464
Merged
Merged
Conversation
The proto is a contract read by every consumer repo and by people who do not have the design document. A comment citing FR-074 or journey E12 gives them nothing to look up. Removes 78 such references from resource-centric comments: 53 FR numbers, 26 journey ids, 4 question numbers and 2 ticket numbers. 67 were a trailing clause and came off cleanly; 11 were mid-sentence and are reworded to say the same thing without the reference. Only comments change. No field, name, number or type is touched, and no legacy field is touched - the two edits outside the resource-centric block are on BackupInfo fields 66 and 68, which this feature added. The reasoning stays in the design document, which is where it belongs.
A reviewer found that MembershipInterval.child_uid makes no sense on a row documented "VMs only" - a VM row holding a list of children is incoherent. Checking it showed the field is not needed on either row. Kubernetes enforces metadata.namespace as immutable on every object update, in ValidateObjectMetaUpdate. So a VM cannot change namespace. Moving one means delete and recreate, which gives a new UID and therefore a new catalog row. The history could only ever hold one interval: joined at creation, left at tombstoning. That is already parent_uid, Metadata.create_time and tombstoned_time. "Which VMs did namespace N hold at time T" is a query over the VM rows on the parent_uid index, and tombstoned rows are kept. Field 14 and the name are reserved. The message is removed. Nothing is built on either.
A review found fields that store what the model already knows. Each one is reserved, with its number and name, so nothing can reuse them. Derivable from a field already on the object: - created_time on the three rule Infos: Metadata.create_time - backup_object_type on BindingRuleInfo and BindingInfo: the resource kind - classification: a baseline lives on the policy, a supplemental on the Binding - backup_schedule_cr_name and schedule_policy_cr_name: both are a digest of schedule_key, which is on the row - BindingInfo.placement_assignment_ref: read it from the catalog row - restorable: true unless failure_reason is set - ExclusionReasonTemplateInfo.code: Metadata.name - AutoRuleExclusionInfo.excluded: the message being present IS the exclusion, and a resource is re-included by clearing it - SharedVolumeInfo.owner_resource_uid: a volume that is not VM-exclusive belongs to the namespace, so the owner is parent_uid Nothing reads it: - captured_rule_definition. refresh_from_rule re-reads the live rule and still_matches_source_rule compares against the live filter - parent_recovery_point_ref. A namespace point and a VM point are separate publication boundaries, so a stored link implies a dependency that must not exist No requirement asks for it: - run_time. The four schedule forms already carry the time - minimum_retention_period. No retention floor is defined anywhere - expires_time and requires_expiry. No expiring exclusion is defined BackupObjectType gains NamespaceExcludingVirtualMachines. The enum had Invalid, All and VirtualMachine, and a namespace must exclude the objects its VMs own, which All does not. exclude_resource_types cannot substitute: it excludes by kind, and this excludes by ownership. Kept against the review's advice: - RecoveryPointInfo.sla_policy_revision_at_capture. Retention is governed by the revision in effect at capture and one timeline spans several revisions, so the Binding's current revision cannot serve it - last_run_time. Materialized so a list view does not read every recovery point, the same reason child_count is kept - BindingInfo.sla_policy_revision. Propagating a policy edit across thousands of Bindings is not one transaction, so this is how a stale Binding is detected graph_owner_index stays until stork can exclude by ownership, which the new enum value is the precondition for.
lalat-das
force-pushed
the
pb-15775-rcb-proto-comments
branch
from
October 27, 2026 08:55
f4a1b40 to
f93849a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The proto is a contract read by every consumer repo and by people who do not have the design document. A comment citing FR-074 or journey E12 gives them nothing to look up.
Removes 78 such references from resource-centric comments: 53 FR numbers, 26 journey ids, 4 question numbers and 2 ticket numbers. 67 were a trailing clause and came off cleanly; 11 were mid-sentence and are reworded to say the same thing without the reference.
Only comments change. No field, name, number or type is touched, and no legacy field is touched - the two edits outside the resource-centric block are on BackupInfo fields 66 and 68, which this feature added.
The reasoning stays in the design document, which is where it belongs.
What this PR does / why we need it:
Which issue(s) this PR fixes (optional)
Closes #
Special notes for your reviewer: