[ https://issues.apache.org/jira/browse/FLINK-5006?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15654613#comment-15654613 ]
ASF GitHub Bot commented on FLINK-5006: --------------------------------------- GitHub user BorisOsipov opened a pull request: https://github.com/apache/flink/pull/2785 [FLINK-5006] SystemProcessingTimeServiceTest.testTimerSorting fails Hello! I'v reproduced this issue on my environment several times. I found that the test uses ScheduledThreadPoolExecutor as threadFactory (actually [SystemProcessingTimeService](https://github.com/apache/flink/blob/master/flink-streaming-java/src/main/java/org/apache/flink/streaming/runtime/tasks/SystemProcessingTimeService.java) uses). ScheduledThreadPoolExecutor does not guarantee that tasks will be executed immediately after delay: > Delayed tasks execute no sooner than they are enabled, but without any real-time guarantees about when, after they are enabled, they will commence. See Oracle [docs ](http://bit.ly/2fobpXv) Thus, order of executions and adding timestamps to ArrayBlockingQueue isn't defined. So it looks like the test is not correct. In changes I increased intervals between tasks, it helps to avoid falling. If I am correct, maybe it makes sense to get rid of this test? You can merge this pull request into a Git repository by running: $ git pull https://github.com/BorisOsipov/flink FLINK-5006 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/flink/pull/2785.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #2785 ---- commit d53100c8361551a5eac29b6955ecb0fa93769a53 Author: Boris Osipov <boris_osi...@epam.com> Date: 2016-11-10T15:52:56Z [FLINK-5006] SystemProcessingTimeServiceTest.testTimerSorting fails Increases test stability ---- > SystemProcessingTimeServiceTest.testTimerSorting fails > ------------------------------------------------------ > > Key: FLINK-5006 > URL: https://issues.apache.org/jira/browse/FLINK-5006 > Project: Flink > Issue Type: Improvement > Components: Streaming > Reporter: Ufuk Celebi > Labels: test-stability > > {code} > testTimerSorting(org.apache.flink.streaming.runtime.tasks.SystemProcessingTimeServiceTest) > Time elapsed: 0.023 sec <<< FAILURE! > java.lang.AssertionError: expected:<1478173518115> but was:<1478173518122> > at org.junit.Assert.fail(Assert.java:88) > at org.junit.Assert.failNotEquals(Assert.java:834) > at org.junit.Assert.assertEquals(Assert.java:645) > at org.junit.Assert.assertEquals(Assert.java:631) > at > org.apache.flink.streaming.runtime.tasks.SystemProcessingTimeServiceTest.testTimerSorting(SystemProcessingTimeServiceTest.java:298) > {code} > Failed in a private branch with unrelated changes (the test is very much self > contained). > https://s3.amazonaws.com/archive.travis-ci.org/jobs/172910645/log.txt -- This message was sent by Atlassian JIRA (v6.3.4#6332)