Home > AS/400 Tips > WebSphere Strategies for iSeries professionals > It's about time
iSeries 400 Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

WEBSPHERE STRATEGIES FOR ISERIES PROFESSIONALS

It's about time


Bob Cancilla
04.18.2002
Rating: --- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


I recently ran into a situation that should be documented in a README FIRST file in WebSphere and installation of the basic Java Virtual Machine (JVM ? 5769JV1 for V4R5 or 5722JV1 for V5R1).

My machine is in Los Angeles and was set to Pacific Standard Time (PST). At 4:30pm we were running servlets that used methods from the Java DATE and CALENDAR classes to create documents, e-mail and update our database with the date and time that an event occurred. Our developers found that the date was displaying the next day for the date and 00:30 as the time.

Further investigation revealed that if we simply used the basic Date() method, the date and time would display in UTC (Universal Coordinated Time). We used our Support Line contract and opened a problem report. We were told to create a file named

SystemDefault.properties

This file can control global Java behavior for the system when it is placed in the following directory:

/QIBM/UserData/Java400/

It can affect a specific user's Java settings when placed in the user's root directory:

/home/userid/

Create SystemDefault.properties (case-sensitive) containing the following two lines:

java.version=1.3
timezone=PST

PST is the Java acronym for your time zone. It also accepts and supports the Java 1.3 method of defining time zones such as America/Los_Angeles. (See http://www.ignite400.org/html/wastimezones.htm for a list of time zones.)

This parameter assumes you have set the QTIME system value to your local time and provided an offset in the QUTCOFSET system value to adjust back to UTC. In Los Angeles, Pacfic Standard Time has an offset of -8 hours (-08:00). Once the time zone entry in SystemDefault.properties is established, Java will now adjust the methods on the Date and Calendar Classes to local time.

When daylight savings time (Summertime in the UK) arrives, you need to change the QTIME system value and QUTCOFSET from -08:00 (for Pacific time) to -9:00 to reflect the new offset. You do not need to change the timezone= parameter in SystemDefault.properites.

I've searched the IBM InfoCenter using its search engine and also searched it with Google. I found a few hits on the SystemDefault.properties file, but none on the time zone parameter.

Here are couple of other parameters you may be interested in finding more information about:

file.encoding=ISO8859_1 -- This affects code page equivalency within Java.
java.compiler=jitc -- This apparently enables the Just In Time compiler.
java.version=1.3 -- Supposedly Java 1.4 is on the horizon. This sets the default JVM to use.

I'm going to do more research on the SystemDefault.properties file and will share my findings in a future tip.

-------------------------
About the author: Bob Cancilla is managing director of IGNITe/400, an electronic iSeries 400 Internet users group. He is also author of the book Getting Down to e-business with AS/400.

=======================
MORE INFORMATION
=======================


Rate this Tip
To rate tips, you must be a member of Search400.com.
Register now to start rating these tips. Log in if you are already a member.




Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED CONTENT
Web Development
Implementing a browser interface in COBOL: Creating your graphic Web page
Implementing a browser interface in COBOL: Getting started
IBM i shop boosts online sales with RPG-based Web platform
Migrating from RPG to EGL on IBM i
Groovy programming on IBM i
Running PHP open source applications: NOBODY needs authority
Zend Web software teams up with IBM System i
The best technologies and tools for System i programmers in 2009
Seven IBM i project lessons learned in 2008
AS/400 lessons from the past, present, and future: A holiday tale

Web Servers
System i no longer the stepchild of IBM's world
Connecting WebSphere to AS/400 for image retrieval
Weaving in WebSphere
SOA enhancements drive IBM WebSphere feature packs
SOA means money for IT workers
Enable J2EE app on WAS to access DB2
Securing Apache: Keeping patches current
IBM runs USOpen.org on Power boxes
MoMA's IT makeover a mix of old and new
How does RPG talk to a browser?

Web
Leverage IBM's Enterprise Identity Mapping (EIM)
Build Web apps using free utility -- WOW!
Q&A: Pluta touts benefits of RPG over Java
Make your database easy to read
Take their money and run: Processing Internet credit card payments with Java, WebSphere
Three tips for using WebFacing
WebFacing v5.1.2 may save a lot of money
Get the lowdown on Eclipse and WebSphere, including pros and cons
Optimizing Tomcat for Web applications
Insourcing beyond outsourcing

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
WebSphere Development Studio Client (WDSC)  (Search400.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary

DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



iSeries Security - Security Tools, Physical Security and System Security
HomeNewsTopicsITKnowledge ExchangeTipsBlogsAsk the ExpertsMultimediaWhite PapersProducts
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 1999 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts