client: config: expose try_from_* methods#457
Draft
kp-antonio-yang wants to merge 12 commits into
Draft
Conversation
eb37bbe to
85c745e
Compare
In order to ease integration from downstream, `Config` and `ConnectionConfig ` of client are exposed as substrate.
Define a validation method of the client configuration.
85c745e to
9faed56
Compare
|
Code coverage summary for b34decd: ✅ Region coverage 68% passes |
8d437ba to
e6cd3be
Compare
try_from_* methods
Ensure sndbuf is valid and raise an error based on the target if this isn't allowed to set using TCP.
e6cd3be to
f9e84b7
Compare
Ensure rcvbuf is valid and raise an error based on the target if this isn't allowed to set using TCP.
Ensure device guild is valid.
Ensure pmtud only enabled with udp mode
Ensure wintun_ring_capacity setting is a power of two between 128KiB and 64MiB
Downstream implementing can easier to resue method of ClientConfig.
…nectionConfig Downstream implementing can easier to resue method of ClientConnectionConfig.
Use String type for server_dn, and emtpy string for none setting
pmtud is not supported with tcp, remove `--enable-pmtud` to avoid error.
f9e84b7 to
c08444b
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.
Description
try_from_reload_sig_and_configofClientConfigtry_from_event_handler_and_connection_configof ClientConnectionConfigMotivation and Context
Provide reusable methods, including validations and casting for
ConfigandConnectionConfig, such that these method can easier to reused by any downstream projects.How Has This Been Tested?
Types of changes
Checklist:
main