On 1/7/2020 5:31 PM, calder wrote:
On Tue, Jan 7, 2020, 17:17 Jerry Malcolm <techst...@malcolms.com> wrote:

On Tue, 7 Jan 2020, 21:52 , <john.e.gr...@wellsfargo.com.invalid> wrote:
'.  What do I set/change?
Those millisecond values are 6 hours apart, which looks like a timezone
issue.  I happen to be in US Central time, which is 6 hours earlier than
UTC in winter.

You're right that System.currentTimeMillis() itself is independent of
timezone but Date is not.
That all makes sense.  But at the end of the day, what do I do to make
it work right?  I am also in Central time.  My Linux OS is set to
central (at least I tried to set that.  Afterwards my log entries are
correctly logging in central time instead of gmt.  So I assume it's set
right).   What do I need to do in Tomcat to 'fix' it so that sql dates
aren't somehow adjusted?  I simply want a 2019-02-01 in the database to
appear as 2019-02-01 in java.  And the same code must work identically
on both OS's.


Have you checked the DST setting?

I googled around trying to see how to check DST in Amazon Linux. the Date command gave me the correct date and timezone with no DST which is currently correct.  I looked at the /etc/sysconfig/clock file.  It has two lines:

ZONE="CST6ST"
UTC=true

But DST is only one hour change.  An earlier post said that my two different values of times were 6 hours off.  Would DST be the cause of that?



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to