Uh oh!
There was an error while loading. Please reload this page.
[SPARK-19050][SS][Tests]Fix EventTimeWatermarkSuite 'delay in months and years handled correctly' - #16449
[SPARK-19050][SS][Tests]Fix EventTimeWatermarkSuite 'delay in months and years handled correctly'#16449zsxwing wants to merge 1 commit into
Conversation
zsxwing
commented
Jan 1, 2017
zsxwing
commented
Jan 1, 2017
I will merge this PR once this test passes since the master is broken now. |
zsxwing
commented
Jan 1, 2017
Merging to master and 2.1 |
… and years handled correctly' ## What changes were proposed in this pull request? `monthsSinceEpoch` in this test is like `math.floor(num)`, so `monthDiff` has two possible values. ## How was this patch tested? Jenkins. Author: Shixiong Zhu <shixiong@databricks.com> Closes#16449 from zsxwing/watermark-test-hotfix. (cherry picked from commit 2394047) Signed-off-by: Shixiong Zhu <shixiong@databricks.com>
SparkQA
commented
Jan 1, 2017
Test build #70777 has finished for PR 16449 at commit
|
gatorsmile
commented
Jan 2, 2017
It sounds like our watermarkTime delay calculation causes this issue. Below are two typical cases: Case 1: when setting the watermark delay to 1 month interval: .withWatermark("eventTime", "1 months")the Case 2: when setting the watermark delay to 1 month interval: .withWatermark("eventTime", "29 months")the It sounds like it is caused by our intentional over-estimation (that is, by using 31 days per month)? |
zsxwing
commented
Jan 2, 2017
@gatorsmile this is an expected behavior. It's intentional and it's correct as per the comment in
If the user wants to filter data accurately, they need to use That's why I changed the test rather than the watermark calculation. |
gatorsmile
commented
Jan 2, 2017
Yeah, agree. This is a bug in the test cases. Thanks! |
… and years handled correctly' ## What changes were proposed in this pull request? `monthsSinceEpoch` in this test is like `math.floor(num)`, so `monthDiff` has two possible values. ## How was this patch tested? Jenkins. Author: Shixiong Zhu <shixiong@databricks.com> Closesapache#16449 from zsxwing/watermark-test-hotfix.
… and years handled correctly' ## What changes were proposed in this pull request? `monthsSinceEpoch` in this test is like `math.floor(num)`, so `monthDiff` has two possible values. ## How was this patch tested? Jenkins. Author: Shixiong Zhu <shixiong@databricks.com> Closesapache#16449 from zsxwing/watermark-test-hotfix.
… and years handled correctly' ## What changes were proposed in this pull request? `monthsSinceEpoch` in this test is like `math.floor(num)`, so `monthDiff` has two possible values. ## How was this patch tested? Jenkins. Author: Shixiong Zhu <shixiong@databricks.com> Closesapache#16449 from zsxwing/watermark-test-hotfix. (cherry picked from commit 2394047) Signed-off-by: Shixiong Zhu <shixiong@databricks.com>
… and years handled correctly' ## What changes were proposed in this pull request? `monthsSinceEpoch` in this test is like `math.floor(num)`, so `monthDiff` has two possible values. ## How was this patch tested? Jenkins. Author: Shixiong Zhu <shixiong@databricks.com> Closesapache#16449 from zsxwing/watermark-test-hotfix. (cherry picked from commit 2394047) Signed-off-by: Shixiong Zhu <shixiong@databricks.com>
What changes were proposed in this pull request?
monthsSinceEpochin this test is likemath.floor(num), somonthDiffhas two possible values.How was this patch tested?
Jenkins.