RFR: 8308995: Update Network IO JFR events to be static mirror events [v3]
    Tim Prinzing 
    tprinzing at openjdk.org
       
    Thu Sep  7 21:57:40 UTC 2023
    
    
  
On Tue, 22 Aug 2023 07:18:21 GMT, Alan Bateman <alanb at openjdk.org> wrote:
>> src/java.base/share/classes/java/net/Socket.java line 1133:
>> 
>>> 1131:                 return parent.getSoTimeout();
>>> 1132:             } catch (Throwable t) {
>>> 1133:                 // ignored - avoiding exceptions in jfr event data gathering
>> 
>> This should be SocketException, not Throwable. That said, I think it would be useful to know why the SocketReadEvent includes the timeout. Is this used to see If read durations are close to the timeout? I assume once this code is fixed to deal with the exceptional case that the need to include the timeout for the success case will mostly go away.
>
> Were you able to find out what the timeout is used for?
No.  I think it's a relic from the distant past though.  I think the timeout field should be removed.  It's not used on SocketChannel at all, and it doesn't seem useful on Socket.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14342#discussion_r1319152153
    
    
More information about the security-dev
mailing list