RFR: 8351443: Improve robustness of StringBuilder [v5]

Roger Riggs rriggs at openjdk.org
Tue May 6 15:23:39 UTC 2025


On Tue, 6 May 2025 13:59:40 GMT, Jaikiran Pai <jpai at openjdk.org> wrote:

>> Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Refactor to consistently use `isLatin1(coder)` within AbstractStringBuilder.
>
> test/jdk/java/lang/StringBuilder/StressSBTest.java line 72:
> 
>> 70:     /**
>> 71:      * Stress test using a number of platform threads for a duration.
>> 72:      * Success is marked by a lack of exceptions.
> 
> If I'm reading the test correctly, then the exceptions that happen in the launched thread are merely logged and thus the test will never throw any exceptions and will never fail?

Yes, the logging is there to help assess how often racy use results in unpredictable (exception) behavior.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/24967#discussion_r2075705736


More information about the core-libs-dev mailing list