Skip to content

Improve behaviour when TCP_NODELAY is set#1936

Merged
stevenengler merged 1 commit intoshadow:mainfrom
stevenengler:tcp-no-delay
Mar 1, 2022
Merged

Improve behaviour when TCP_NODELAY is set#1936
stevenengler merged 1 commit intoshadow:mainfrom
stevenengler:tcp-no-delay

Conversation

@stevenengler
Copy link
Copy Markdown
Contributor

@stevenengler stevenengler commented Feb 25, 2022

Shadow doesn't support nagle's algorithm, so shadow always behaves as if TCP_NODELAY is enabled. Some programs will fail if setsockopt(fd, SOL_TCP, TCP_NODELAY, &1, sizeof(int)) returns an error, so we treat this as a no-op for compatibility.

Three examples I can think of that fail when they're unable to set TCP_NODELAY are nginx (unless using tcp_nodelay off), python's urllib library, and salticidae-based programs.

@stevenengler stevenengler added the Component: Main Composing the core Shadow executable label Feb 25, 2022
@stevenengler stevenengler self-assigned this Feb 25, 2022
@github-actions github-actions bot added Component: Testing Unit and integration tests and frameworks labels Feb 25, 2022
@stevenengler stevenengler enabled auto-merge March 1, 2022 22:13
@stevenengler stevenengler merged commit 4d53826 into shadow:main Mar 1, 2022
@stevenengler stevenengler deleted the tcp-no-delay branch March 1, 2022 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants