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

ejb32/lite/timer/schedule/expression/annotated/Client.java#dayOfMonthAndDayOfWeek failed when running the day before daylight time switch #134

Open
chengfang opened this issue Nov 3, 2019 · 0 comments
Labels
bug Something isn't working

Comments

@chengfang
Copy link
Contributor

The following 4 tests failed when running the day before daylight time switch (e.g., 2019-11-02):

com/sun/ts/tests/ejb32/lite/timer/schedule/expression/annotated/Client.java\#dayOfMonthAndDayOfWeek_from_ejblitejsf
com/sun/ts/tests/ejb32/lite/timer/schedule/expression/annotated/Client.java\#dayOfMonthAndDayOfWeek_from_ejblitejsp 
com/sun/ts/tests/ejb32/lite/timer/schedule/expression/annotated/Client.java\#dayOfMonthAndDayOfWeek_from_ejbliteservlet 
com/sun/ts/tests/ejb32/lite/timer/schedule/expression/annotated/Client.java\#dayOfMonthAndDayOfWeek_from_ejbliteservlet2 

The test creates a timer that expires this DAY_OF_WEEK and next DAY_OF_MONTH. When running this test the day before daylight time switch, the next day of month is +/- 1 hour, instead of the exact 24 hours. The test manually computes an expected remaining time as long expectedNext = 24 * 60 * 60 * 1000;, which is off by 1 hour when running on the day before daylight time switch.

See test class com.sun.ts.tests.ejb32.lite.timer.schedule.expression.annotated.ScheduleBean

The error messages:

Nov 03, 2019 12:01:26 AM com.sun.ts.tests.common.vehicle.ejbliteshare.EJBLiteWebVehicleRunner run
INFO: Connecting http://localhost:8080/ejb32_lite_timer_schedule_expression_annotated_ejblitejsf_vehicle_web/faces/ejblitejsf_vehicle.jsp?testName=dayOfMonthAndDayOfWeek
<html>
    <head><title>dayOfMonthAndDayOfWeek_from_ejblitejsf</title></head>
    <body>
        [TEST FAILED] testName=dayOfMonthAndDayOfWeek Created timer: TimerInfo testName=dayOfMonthAndDayOfWeek testNumber=0 status=false doubleVar=0.0 longVar=0 charVar=  booleanVar=false intVar=0	schedule:ScheduleExpression [second=27;minute=1;hour=0;dayOfMonth=4;month=*;dayOfWeek=7;year=*;timezoneID=null;start=null;end=null]	nextTimeout:Sun Nov 03 00:01:27 EDT 2019	timeRemaining:551	isPersistent:false
[Invoking Timeout method for timer with schedule: year=* month=* dayOfMonth=4 dayOfWeek=7 hour=0 minute=1 second=27 start=null end=null timezone=null, info: TimerInfo testName=dayOfMonthAndDayOfWeek testNumber=0 status=false doubleVar=0.0 longVar=0 charVar=  booleanVar=false intVar=0, and isPersistent: false, Expecting approximate timeRemaining 86400000, actual timeRemaining 89999998]


Check timeout status Expecting true, but actual falseFailed with exception 
java.lang.RuntimeException: Created timer: TimerInfo testName=dayOfMonthAndDayOfWeek testNumber=0 status=false doubleVar=0.0 longVar=0 charVar=  booleanVar=false intVar=0	schedule:ScheduleExpression [second=27;minute=1;hour=0;dayOfMonth=4;month=*;dayOfWeek=7;year=*;timezoneID=null;start=null;end=null]	nextTimeout:Sun Nov 03 00:01:27 EDT 2019	timeRemaining:551	isPersistent:false
[Invoking Timeout method for timer with schedule: year=* month=* dayOfMonth=4 dayOfWeek=7 hour=0 minute=1 second=27 start=null end=null timezone=null, info: TimerInfo testName=dayOfMonthAndDayOfWeek testNumber=0 status=false doubleVar=0.0 longVar=0 charVar=  booleanVar=false intVar=0, and isPersistent: false, Expecting approximate timeRemaining 86400000, actual timeRemaining 89999998]
@gurunrao gurunrao added the bug Something isn't working label Feb 21, 2020
@RohitKumarJain RohitKumarJain self-assigned this May 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants