JDK-8185719 : [testlibrary] rmi TestSocketFactory does not flush
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.rmi
  • Affected Version: 9
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2017-08-02
  • Updated: 2018-03-21
  • Resolved: 2017-08-02
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 10 JDK 8 Other
10 b18Fixed 8u161Fixed openjdk7uFixed
Description
The test/java/rmi/testlibrary/TestSocketFactory MatchReplaceOutputStream does not support flush.

In the case where a partial match is being recognized, those bytes have not been sent to the output stream or log.  If the writer calls flush, the partial match is not flushed.  It may cause a client reading the stream to hang waiting for the missing bytes.

MatchReplaceOutputStream should support flush by writing the partial match and reset the match to start again.

Match/replace across a flush is not needed and not supported.