-
Notifications
You must be signed in to change notification settings - Fork 20
Add granular tcp configuration through TcpConfig struct #65
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
Conversation
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 granular TCP configuration through a new TcpConfig struct, replacing the single tcp_timeout field in IpStackConfig with configurable timeout values for different TCP states and operations. This change provides more fine-grained control over TCP behavior without breaking the existing API significantly.
- Replaces single
tcp_timeoutfield with comprehensiveTcpConfigstruct containing multiple timeout parameters - Updates all TCP timeout-related code to use configurable values instead of hardcoded constants
- Modifies the example to demonstrate the new configuration approach
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/stream/tcp.rs | Introduces TcpConfig struct and updates TCP stream implementation to use configurable timeouts |
| src/stream/mod.rs | Exports the new TcpConfig struct |
| src/lib.rs | Updates IpStackConfig to use TcpConfig and replaces tcp_timeout method with with_tcp_config |
| examples/tun.rs | Updates example to use the new TCP configuration API |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
Good work. |
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
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
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
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
No description provided.