RFR: 8201778: Speed up test javax/net/ssl/DTLS/PacketLossRetransmission.java

Fernando Guallini fguallini at openjdk.org
Thu Mar 20 12:23:52 UTC 2025


On Mon, 17 Mar 2025 18:19:46 GMT, Matthew Donovan <mdonovan at openjdk.org> wrote:

>> The test  `javax/net/ssl/DTLS/PacketLossRetransmission` takes about ~2  to complete. The reason is that, in multiple scenarios, the server/client socket times out after 10 seconds waiting to receive a DatagramPacket that has been removed (to simulate a packet loss). 
>> After reducing the time out only for such scenarios, the total test execution is completed within ~20 seconds on average. Other scenarios do not throw SocketTimeOut, no need to update.
>
> test/jdk/javax/net/ssl/DTLS/PacketLossRetransmission.java line 36:
> 
>> 34:  *
>> 35:  * @run main/othervm PacketLossRetransmission client 0 hello_request
>> 36:  * @run main/othervm PacketLossRetransmission client 1 client_hello shortTimeOut
> 
> Why are you only using a short time out for some messages?
> 
> (Also a small nit: line 109 has a typo.)

Hi Matthew, only reducing the timeout when needed (most scenarios don't throw a socketTimeOut, only some), I'll add a PR description before removing the draft status. Fixed the typo 👍

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24079#discussion_r1999452425


More information about the security-dev mailing list