Skip to content
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

handling partial/interrupted I/O #69

Merged
merged 3 commits into from
Nov 30, 2016

Conversation

atumanov
Copy link
Contributor

@atumanov atumanov commented Nov 29, 2016

Updated read_bytes and write_bytes to handle EINTR and changed the flow a bit.

EINTR is induced when a process is interrupted by a signal while doing I/O. It is not uncommon in asynchronous, event-driven code with callbacks. Different *Nix systems may handle EINTR differently, some automatically restart the syscall, some don't. It is best to handle it in all cases and manually restart the syscall, while accounting for the partial read/write.

Plasma send/receive were updated to support partial fd reads/writes, in lieu of treating them as failed I/O.

@robertnishihara robertnishihara merged commit 1499834 into ray-project:master Nov 30, 2016
@atumanov atumanov self-assigned this Nov 30, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants