Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 550834

Summary: Race condition in InputStreamMonitor can delay or block user input to RuntimeProcess
Product: [Eclipse Project] Platform Reporter: Paul Pazderski <paul-eclipse>
Component: DebugAssignee: Paul Pazderski <paul-eclipse>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: sarika.sinha
Version: 4.12   
Target Milestone: 4.14 M1   
Hardware: All   
OS: All   
See Also: https://git.eclipse.org/r/149019
https://git.eclipse.org/c/platform/eclipse.platform.debug.git/commit/?id=10afa0452509c63806769551cbdf1767d91dea8e
Whiteboard:
Bug Depends on:    
Bug Blocks: 550345, 552030    

Description Paul Pazderski CLA 2019-09-06 05:21:12 EDT
InputStreamMonitor is responsible to transfer user input in Eclipse console to the attached RuntimeProcess. There is a race condition where the thread is blocked and waiting for new input while there is still input in its queue to transfer.

This is usually not problematic because the pending input is transferred when user adds more input and like many race conditions it is hard to trigger this problem in first place. (one condition is to input more than 1024 characters at once)

This is also the reason for the unstable jdt.debug tests testBug545769_UTF8InEven and testBug545769_UTF8InOdd.
Comment 2 Sarika Sinha CLA 2019-10-09 02:38:52 EDT
Marking it verified as the tests have not failed after the release of this change.