Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TimeZone issue on Activity Page #350

Closed
gitblit opened this issue Aug 12, 2015 · 6 comments
Closed

TimeZone issue on Activity Page #350

gitblit opened this issue Aug 12, 2015 · 6 comments

Comments

@gitblit
Copy link
Collaborator

gitblit commented Aug 12, 2015

Originally reported on Google Code with ID 54

What steps will reproduce the problem?
1. I'm running GitBlit on a server with UTC time zone

2. I'm launching GitBlit using tomcat and setting Java's time zone to using -Duser.timezone=Americas/Los_Angeles

3. I modified web.xml and appended "z" to all the time/date formats to see the time
zones

4. The dates on the commit log are correct and are shown as PST, but the date/times
on the main "Activity" tab are all in GMT. 

What is the expected output? What do you see instead?
The dates on the activity tab should be PST

What version of the product are you using? On what operating system?
0.8.2 WAR on Tomcat 6.0.

Please provide any additional information below.
I think the best would be to have a setting in GitBlit to set the time zone. This way,
I can set the JVM time zone to UTC too so my logs would be in UTC. In addition, since
the actual git blob files are being created using the UTC times this makes things simpler.

Reported by Drew.Kutcharian on 2012-02-03 02:10:15

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

Not that it matters but I'm running 0.8.2 WAR on Tomcat 7.0.25 on Ubuntu 10.4 64-bit.

Reported by Drew.Kutcharian on 2012-02-03 02:14:11

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

Gitblit uses the server's timezone unless you are allowing browser timezone identification
web.useClientTimezone.  I'm not sure why the activity page would be different since
it should be using the same date formatting as everything else.  I'll consider adding
a Gitblit timezone setting, but since it can be overridden with a -D parameter it seems
unnecessary.

Reported by James.Moger on 2012-02-03 12:56:36

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

I configured my timestamps as you did and then used the exact parameter you specified.
My activity dates were in GMT as you indicated they would be... but so were all other
dates.

There is a typo in your parameter: "America/Los_Angeles" is the correct value.  When
I run it using the correct timezone the activity page shows all dates/times as PST
as does the rest of Gitblit.

Reported by James.Moger on 2012-02-03 13:20:10

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

Found the bug and implemented the timezone control setting.

Reported by James.Moger on 2012-02-21 22:33:41

  • Status changed: Queued
  • Labels added: Milestone-0.9.0

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

Fixed in v0.9.1

Reported by James.Moger on 2012-03-28 00:02:10

@gitblit
Copy link
Collaborator Author

gitblit commented Aug 12, 2015

Fixed in v0.9.1. Closing.

Reported by James.Moger on 2012-03-28 00:03:12

  • Status changed: Fixed

@gitblit gitblit closed this as completed Aug 12, 2015
@flaix flaix modified the milestone: 0.9.0 Dec 13, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants