-
Notifications
You must be signed in to change notification settings - Fork 77
feat(ws): add Config
#533
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(ws): add Config
#533
Conversation
03cde16 to
d81ae45
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a unified Config struct for compio-ws that consolidates WebSocket configuration, buffer sizing, and Nagle's algorithm settings. The changes aim to provide a more flexible and ergonomic API through the builder pattern and trait implementations.
- Introduces a new
Configstruct with builder methods to replace disparate parameters - Updates all
_with_configfunctions to acceptimpl Into<Config>for ergonomic usage - Standardizes unit notation from "KB" to "KiB" across documentation
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| compio-ws/src/lib.rs | Adds Config struct with builder pattern and trait implementations; updates function signatures to use Config; makes client_async_with_config private |
| compio-ws/src/tls.rs | Updates imports and function signatures to use new Config type; extracts Nagle setting from config |
| compio-io/src/write/buf.rs | Corrects documentation from "KB" to "KiB" |
| compio-io/src/util/mod.rs | Corrects documentation from "KB" to "KiB" |
| compio-io/src/read/buf.rs | Corrects documentation from "KB" to "KiB" |
| compio-io/src/compat/sync_stream.rs | Corrects documentation from "KB"/"MB" to "KiB"/"MiB" |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
75f7bb3 to
0221d92
Compare
Berrysoft
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
No description provided.