add cli message-properties and $SYS control flags - #122
Merged
Conversation
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.
Adds the three CLI options requested in #115.
mqttv5 sub --show-properties(-s)Prints the MQTT v5 properties of each received message alongside its payload. When set, the subscriber renders the delivered QoS, the retain flag, and every present property (payload format indicator, message expiry interval, content type, response topic, correlation data as hex, subscription identifiers, and user properties), one per line, followed by the payload. Without the flag the output is unchanged (payload only, or
topic: payloadunder--verbose).mqttv5 broker --no-sys-topicsand--sys-interval <DUR>Expose the broker's
$SYSstatistics publishing on the command line.--no-sys-topicsdisables$SYSpublishing (enabled by default);--sys-intervalsets the publish interval and accepts a bare number of seconds or a duration such as10sor1m(default10). Both map to the existingBrokerConfigfields, so an interval of zero while$SYSis enabled is still rejected at config validation.Notes
mqttv5-clibumped 0.28.4 -> 0.28.5 (additive), CHANGELOG updatedREADME.md,CLI_USAGE.md); also removed a stalesub -t a -t b"multiple topics" example that the command rejectscli_functionality.rs:test_cli_sub_show_properties(real pub -> sub asserting rendered properties) andtest_cli_broker_sys_flags(help exposes the flags)Closes #115