Make standalone_nexus_operation capability optional for field presence#831
Closed
stephanos wants to merge 1 commit into
Closed
Make standalone_nexus_operation capability optional for field presence#831stephanos wants to merge 1 commit into
stephanos wants to merge 1 commit into
Conversation
Change NamespaceInfo.Capabilities.standalone_nexus_operation from an implicit-presence bool to `optional bool` so clients can distinguish "server does not know this capability" (field absent) from "server supports it but it is disabled" (field present, false). Wire-compatible; regenerated Go bindings change the field to *bool. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Change
NamespaceInfo.Capabilities.standalone_nexus_operationfrom an implicit-presencebooltooptional bool.Why
With a plain proto3
bool, afalsevalue is indistinguishable from an unset field on the wire (both are omitted). This means aDescribeNamespaceclient cannot tell apart:false— server supports it, but the dynamic config is disabledtrue— supported and enabledCases 1 and 2 currently collapse into "field omitted". Marking the field
optionaladds explicit field presence, so a server that knows the capability always emits it (trueorfalse), and only an older server omits it — giving the UI a reliable three-state signal.Compatibility
optional boolencodes identically toboolon the same field number.*bool(with aHas...()accessor). Downstream (temporal server)Capabilities{...}literal must wrap the value inproto.Bool(...); getter reads are unaffected.Draft pending discussion on whether to apply the same treatment to the other capability bools.