Skip to content

Retry the Windows local pipe server connection once on EPIPE - #694

Merged
clintoncwolfe merged 1 commit into
masterfrom
cw/retry-win-pipe
Jun 22, 2021
Merged

clintoncwolfe merged 1 commit into
masterfrom
cw/retry-win-pipe

Conversation

@clintoncwolfe

Copy link
Copy Markdown
Contributor

A customer has reported that on Windows Server 2012, certain InSpec operations are failing with Errno::EPIPE. Because of the way that the Windows local pipe-based connection works, once the pipe has been dropped, all further commands executed in the session will fail.

This change catches EPIPE, closes and restarts the pipe server, and writes to a new pipe. It only tries this onoce per failure; if two failures occur in a row, the failure will be passed up.

Description

Related Issue

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New content (non-breaking change)
  • Breaking change (a content change which would break existing functionality or processes)

Checklist:

  • I have read the CONTRIBUTING document.

Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant