Possible bug in jdk.naming.dns. I need guidance on how get someone smarter to look at it.

Daniel Fuchs daniel.fuchs at oracle.com
Wed Sep 4 13:24:49 UTC 2024


Hi Marko,

This is not the proper list for this kind of question:
I'm moving the discussion to core-libs-dev at openjdk.org.

There's definitely a bug here: that code should use
System.nanoTime() and not System.currentTimeMillis()
since the latter is not guaranteed to be monotonic.

It may not explain the issue you are observing, but
again, it may cause the timeout to punctually increase.

I have logged
https://bugs.openjdk.org/browse/JDK-8339538

I wonder if that has an impact on what you are observing.

best regards,

-- daniel

On 04/09/2024 13:50, Marko Bakšić wrote:
> Hey there!
> 
> Sorry for coming here with a technical question, but I would appreciate 
> if you could point me in the right direction.
> 
> We experienced a bug in production a few times already and through 
> profiling we suspect it is an infinite loop here:
> https://github.com/openjdk/jdk/blob/master/src/jdk.naming.dns/share/classes/com/sun/jndi/dns/DnsClient.java#L475 <https://github.com/openjdk/jdk/blob/master/src/jdk.naming.dns/share/classes/com/sun/jndi/dns/DnsClient.java#L475>
> 
> I came here before opening a bug report, because I'm not sure I am 
> right. We haven't been able to reproduce the bug in a dev environment.
> Before spending much more time trying to reproduce this, I was hoping 
> someone smarter could give me a hint if this is even the right direction.
> 
> If no one here can help, I'd appreciate if you could point me in a 
> direction of somewhere where I could have a casual discussion about 
> this, or get some more eyes on this.
> 
> Thank you very much.
> 
> -- ​Marko
> 
> 
> 	
> 
> *Marko Bakšić*
> 
> Software Engineer
> 
> 	
> 
> *E *Marko.Baksic at infobip.com
> 
> *M*
> 
> 	
> 
> *A *Utinjska 29A, 10000 Zagreb, Croatia
> 
> www.infobip.com<http://www.infobip.com>
> 
> <https://www.infobip.com/news/infobip-named-to-fast-companys-annual-list-of-the-worlds-most-innovative-companies-of-2024>
> 
> <https://www.facebook.com/infobip> 
> <https://www.linkedin.com/company/infobip> 
> <https://twitter.com/Infobip> 	<https://www.instagram.com/infobip/> 
> <https://www.youtube.com/channel/UCUPSTy53VecI5GIir3J3ZbQ>
> 
> *GSMA Associate Member*
> This email message and any attachments are intended solely for the use 
> of the addressee. If you are not the intended recipient, you are 
> prohibited from reading, disclosing, reproducing, distributing, 
> disseminating or otherwise using this transmission. If you have received 
> this message in error, please promptly notify the sender by reply email 
> and immediately delete this message from your system. This message and 
> any attachments may contain information that is confidential, privileged 
> or exempt from disclosure. Delivery of this message to any person other 
> than the intended recipient is not intended to waive any right or privilege.
> 



More information about the discuss mailing list