CONFIDENTIAL & RESTRICTED Does the system time (OS) change in a similar way? Is it always the change of instead using CDT the timestamps switch to UTC? Do the times at least match to some degree? I mean is it just the wrong timezone (and same hour of the day), or is it the same instant in time just represented from a different timezone (02:06 CDT -> 09:06 CEST)?
If the system time remains stable, it is related to the JVM. Also the fact that a restart fixes the problem is an indication the system time is correct. Remains the fact that the time is lost after decreasing intervals. So there might be the question if the application can configure timezone/system time and to find out whether it does it. If you find out which java methods need to be called for this to change then you could check the source code for such calls, or at least set breakpoints to be informed immediately when such a line of code is reached. Hiran -----Original Message----- From: David <rax1...@gmail.com> Sent: Thursday, October 27, 2022 17:31 To: Tomcat Users List <users@tomcat.apache.org> Subject: Tomcat/Java app timezone radomly changes during operation. CAUTION: External mail. Be careful with links and attachments. Hi all, I've experienced an issue since the morning of the 21st that I'm hoping to get some direction on for where to look. An app uses the date/time to set a timeout for a password reset. This had been working fine for years and suddenly it failed. A restart of tomcat allowed it to work for a day, then 12 hours, then 5 hours, then 1 hr and now is averaging a 10 minute or so working duration between tomcat restarts. Changing the logging in the app showed that the issue is due to it sending UTC to the DB while it is broken. Restarting Tomcat results in CDT being sent for a while until randomly it switches again. RHEL 7.9, jvm 1.8.0_231-b11, Tomcat 9.0.29 ntp is on, chrony is syncing, Java states correct time when queried however unsure if it's JDK or JRE when targeted. OS time is good. When I redeploy the app, log timestamps for the app are in UTC as well until restarting tomcat. During the issue the log timestamp remains in CDT as expected, even though values passed are UTC. I have explicitly defined the timezone in setenv.sh with no change in behavior. Any thoughts as what to investigate are greatly appreciated. Thanks, David IMPORTANT - CONFIDENTIALITY NOTICE - This e-mail is intended only for the use of the individual or entity shown above as addressees . It may contain information which is privileged, confidential or otherwise protected from disclosure under applicable laws . If the reader of this transmission is not the intended recipient, you are hereby notified that any dissemination, printing, distribution, copying, disclosure or the taking of any action in reliance on the contents of this information is strictly prohibited. If you have received this transmission in error, please immediately notify us by reply e-mail or using the address below and delete the message and any attachments from your system. Amadeus Data Processing GmbH Geschaftsfuhrer: Sven Fuhrmeister Sitz der Gesellschaft: Erding HR Munchen 212770 Berghamer Strasse 6 85435 Erding Germany. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org