SOLVE

Tech Tip: NetMaster ReportCenter Java Task NMJAVA is failing with error "Illegal daylight saving value: 0"

  • 1.  Tech Tip: NetMaster ReportCenter Java Task NMJAVA is failing with error "Illegal daylight saving value: 0"

    Broadcom Employee
    Posted 12-08-2016 09:10 PM
     

    Issue:

    The NetMaster ReportCenter Java Task NMJAVA has started failing with the following message: 

    java version "1.6.0" 
    Java(TM) SE Runtime Environment (build pmz3160_26sr8fp30-20160720_01(SR8fp30)) 
    IBM J9 VM (build 2.6, JRE 1.6.0 z/OS s390-31 20160630_309946 (JIT enabled, AOT enabled) 
    J9VM - R26_Java626_SR8_20160630_1807_B309946 
    JIT - tr.r11_20160630_120374 
    GC - R26_Java626_SR8_20160630_1807_B309946 
    J9CL - 20160630_309946) 
    JCL - 20160719_01 
    Exception in thread "main" java.lang.IllegalArgumentException: Illegal daylight saving value: 0 
    .at java.util.SimpleTimeZone.setDSTSavings(SimpleTimeZone.java:803) 
    .at com.ca.syd.utils.adaptor.LocalTimeZone.buildTimeZone(LocalTimeZone.java:148) 
    .at com.ca.syd.utils.adaptor.LocalTimeZone.<init>(LocalTimeZone.java:94) 
    .at com.ca.syd.utils.adaptor.Adaptor.<init>(Adaptor.java:338) 
    .at com.ca.syd.utils.adaptor.Adaptor.main(Adaptor.java:241) 

     

    Our default system Time Zone has the following setting in the /etc/profile file:

    TZ=WST-8WDT-8,M10.1.0,M4.1.0 

     

    Resolution:

    The problem is occurring because the Time Zone setting has an offset value that is not needed.

    The input is broken down as following for the TZ=WST-8WDT-8,M10.1.0,M4.1.0 : 

     

    WST-8 sets Standard Time 
    WDT-8 indicates that there is a Daylight Savings Time being used and gives the offset value 
    M10.1.0 is the start date for the Daylight Savings Time to take effect 
    M4.1.0 is the end date for the Daylight Savings Time 

     

    If you do not wish to specify daylight savings time, the correct setting should just be TZ =WST-8 without any daylight savings offset (WDT). The error occurs when the offset value passed into the setDSTSavings (a native Java function) is “0” and that function only handles positive numbers.