[Building Sakai] Default Time Zone

Sam Chow samchow at ln.edu.hk
Mon Jan 11 00:12:33 PST 2010


Thanks for your reply,
i have set the default time zone by adding -Duser.timezone=Asia/Hong_Kong to
JVM

Thanks~



Matthew Jones-8 wrote:
> 
> I believe as Beth is saying, the default TimeZone in Sakai
> BasicTimeService
> is set by TimeZone.getDefault(). Reading google there are issues with
> timezone data in windows so this may report incorrect. I would update to
> the
> latest JVM and see what this returns. There is a program here from sun
> that
> updates the timezone config files.
> 
> http://java.sun.com/javase/timezones/
> 
> The following short program on Windows Server 2008 prints out for me
> correctly.
> timezone is
> sun.util.calendar.ZoneInfo[id="America/New_York",offset=-18000000, . . .
> 
> javac TestTimeZone.java;java TestTimeZone
> 
> TestTimeZone.java
> --------------------------
> import java.util.*;
> public class TestTimeZone {
>   public static void main(String[] args) {
>     System.out.println("timezone is " + TimeZone.getDefault());
> System.out.println("time is " + new Date()); System.out.println("locale
> is"
> + Locale.getDefault());
>   } }
> 
> On Fri, Jan 8, 2010 at 12:02 PM, Beth Kirschner <bkirschn at umich.edu>
> wrote:
> 
>> The displayed timezone comes from the JRE, and I'm guessing it doesn't
>> understand the timezone string you/Windows provided. When I look at
>> the Sakai user preferences, the timezone string for Hong Kong is "Asia/
>> Hong_Kong". So maybe try using that? Unfortunately I'm fairly windows
>> illiterate, so I don't think I can be much help :-(
>>
>> - Beth
>>
>> On Jan 8, 2010, at 11:10 AM, samchow wrote:
>>
>> > Dear Beth,
>> >
>> > Thanks your reply. Our Sakai is running on a window xp server, and i
>> > have
>> > set the timezone of the os is  +8 Bejing, Hong Kong. In Sakai time
>> > zone,
>> > there are a lot of +8 district, how can i tell the sakai the local
>> > time
>> > zone is +8 Hong KOng?
>> >
>> > Man yThanks
>> > Sam
>> >
>> > On Fri, 8 Jan 2010 08:49:03 -0500, Beth Kirschner <bkirschn at umich.edu>
>> > wrote:
>> >> The system default time zone uses the time zone of your server.
>> >> User's
>> >> can set their own default time zone in Preferences (My Workspace ->
>> >> Preferences -> Time Zone).
>> >>
>> >> - Beth
>> >>
>> >> On Jan 8, 2010, at 2:29 AM, Sam Chow wrote:
>> >>
>> >>>
>> >>> Dear all,
>> >>>
>> >>> I wanna ask how to set the default time zone, Thanks!
>> >>>
>> >>> Sam
>> >>> --
>> >>> View this message in context:
>> >>> http://old.nabble.com/Default-Time-Zone-tp27072234p27072234.html
>> >>> Sent from the Sakai - Development mailing list archive at
>> >>> Nabble.com.
>> >>>
>> >>> _______________________________________________
>> >>> sakai-dev mailing list
>> >>> sakai-dev at collab.sakaiproject.org
>> >>> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>> >>>
>> >>> TO UNSUBSCRIBE: send email to
>> >>> sakai-dev-unsubscribe at collab.sakaiproject.org
>> >>> with a subject of "unsubscribe"
>> >>>
>> >>>
>> >
>> >
>>
>> _______________________________________________
>> sakai-dev mailing list
>> sakai-dev at collab.sakaiproject.org
>> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>>
>> TO UNSUBSCRIBE: send email to
>> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
>> "unsubscribe"
>>
> 
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
> 
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
> 

-- 
View this message in context: http://old.nabble.com/Default-Time-Zone-tp27072234p27107003.html
Sent from the Sakai - Development mailing list archive at Nabble.com.



More information about the sakai-dev mailing list