Repository navigation
Drop topic wildcards from the Topic helper - #2056
Merged
Merged
Conversation
Remove Topic::any()/all() and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
Remove the any()/all() wildcard builders and the ResolvedTopic type so a topic is only a path of plain id levels. A level containing + or # is now rejected outright rather than steered toward a wildcard builder.
The language programs no longer print the any()/all() cases, so remove the matching lines from the shared topic helper expectations.
🟢 Tier S · Ready to merge
This change removes the
📂 Walkthrough · 6
Reviewed |
abnegate
approved these changes
Oct 15, 2026
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
Removes the wildcard builders from the
Topichelper across every SDK that ships it, so a topic can only be a path of plain id levels — no single-level (+) or multi-level (#) MQTT wildcards.Concretely, per SDK:
any()/all()builders (and theirTopic.any()/Topic.all()entry points).ResolvedTopictype, which existed only as the terminal value returned byall(). It is removed from the helper and from everyPush.subscribesignature /TopicValueconversion that referenced it;subscribenow accepts a string or aTopic(and lists of them)./,+or#, but a+or#level is now simply "not allowed in a topic" instead of being steered toward a wildcard builder.This follows from topics being plain ids: the broker only grants exact topic ids, so the wildcard surface had no server-side meaning.
Scope
Topic helper templates, their unit tests, the
Push.subscribesignatures / docs that referencedResolvedTopic, the SDK re-exports, and the per-language e2e programs plus the sharedTOPIC_HELPER_RESPONSESexpectations.Verification
Regenerated every affected SDK and ran the available formatters/linters/tests locally:
go build/go test(go, cli),cargo fmt+cargo test(rust)dart format(dart), swift-format (swift, apple)npm test(910 tests) passdotnet format(dotnet, unity) was not run locally (no toolchain available); left for CI. Docker e2e is left for CI.Usage (JS)
Build a topic as a path of plain id levels and pass it to
push.subscribe(strings still work too):There is no longer an
any()/all()builder or aResolvedTopictype. A level that contains/,+or#throws —+and#are "not allowed in a topic". To match the old.toString()form,String(topic)or`${topic}`still works.