Uh oh!
There was an error while loading. Please reload this page.
[SPARK-18671][SS][TEST] Added tests to ensure stability of that all Structured Streaming log formats - #16128
[SPARK-18671][SS][TEST] Added tests to ensure stability of that all Structured Streaming log formats#16128tdas wants to merge 9 commits into
Conversation
SparkQA
commented
Dec 3, 2016
Test build #69605 has finished for PR 16128 at commit
|
| OffsetSeq( | ||
| offsets = Seq(Some(SerializedOffset( | ||
| """ | ||
| |{"kafka-topic":{"23":0,"8":1,"17":1,"11":1,"20":0,"2":6,"5":2,"14":0,"4":4,"13":1, |
There was a problem hiding this comment.
We should add a test for Kafka source to check if we can convert json to KafkaSourceOffset. This doesn't check that.
SparkQA
commented
Dec 3, 2016
Test build #69609 has finished for PR 16128 at commit
|
| } | ||
| } | ||
| val partitions = partitionOffsets.keySet.toSeq.sorted // sort for more determinism | ||
| partitions.foreach { tp => |
There was a problem hiding this comment.
nit: You can use partitionOffsets.toSeq.sortBy(_._1).foreach { case (tp, off) => to simplify the codes.
There was a problem hiding this comment.
I want to sort by topic and partitions together. so that partitions are ordered when json is generated (currently is not) and hard to read.
| } | ||
| test("read Spark 2.1.0 log format") { | ||
| val offset = readFromResource("kafka-source-offset-version-2.1.0.txt") |
There was a problem hiding this comment.
nit: maybe not need to read json from a file since we never write them into a single file.
There was a problem hiding this comment.
yeah. but its good to have it in a separate file in the same place as other formats. will be easier to track all the things that need compatibility guarantees.
| } | ||
| test("FileStreamSource offset - read Spark 2.1.0 log format") { | ||
| val offset = readOffsetFromResource("file-source-offset-version-2.1.0.txt") |
There was a problem hiding this comment.
nit: maybe not need to read json from a file since we never write them into a single file.
SparkQA
commented
Dec 6, 2016
Test build #69705 has finished for PR 16128 at commit
|
zsxwing
commented
Dec 6, 2016
LGTM pending tests. |
SparkQA
commented
Dec 6, 2016
Test build #3468 has finished for PR 16128 at commit
|
SparkQA
commented
Dec 6, 2016
Test build #69714 has started for PR 16128 at commit |
zsxwing
commented
Dec 6, 2016
retest this please |
SparkQA
commented
Dec 6, 2016
Test build #69740 has finished for PR 16128 at commit
|
zsxwing
commented
Dec 6, 2016
LGTM. Thanks. Merging to master and 2.1. |
…tructured Streaming log formats ## What changes were proposed in this pull request? To be able to restart StreamingQueries across Spark version, we have already made the logs (offset log, file source log, file sink log) use json. We should added tests with actual json files in the Spark such that any incompatible changes in reading the logs is immediately caught. This PR add tests for FileStreamSourceLog, FileStreamSinkLog, and OffsetSeqLog. ## How was this patch tested? new unit tests Author: Tathagata Das <tathagata.das1565@gmail.com> Closes#16128 from tdas/SPARK-18671. (cherry picked from commit 1ef6b29) Signed-off-by: Shixiong Zhu <shixiong@databricks.com>
…tructured Streaming log formats ## What changes were proposed in this pull request? To be able to restart StreamingQueries across Spark version, we have already made the logs (offset log, file source log, file sink log) use json. We should added tests with actual json files in the Spark such that any incompatible changes in reading the logs is immediately caught. This PR add tests for FileStreamSourceLog, FileStreamSinkLog, and OffsetSeqLog. ## How was this patch tested? new unit tests Author: Tathagata Das <tathagata.das1565@gmail.com> Closesapache#16128 from tdas/SPARK-18671.
…tructured Streaming log formats ## What changes were proposed in this pull request? To be able to restart StreamingQueries across Spark version, we have already made the logs (offset log, file source log, file sink log) use json. We should added tests with actual json files in the Spark such that any incompatible changes in reading the logs is immediately caught. This PR add tests for FileStreamSourceLog, FileStreamSinkLog, and OffsetSeqLog. ## How was this patch tested? new unit tests Author: Tathagata Das <tathagata.das1565@gmail.com> Closesapache#16128 from tdas/SPARK-18671.
What changes were proposed in this pull request?
To be able to restart StreamingQueries across Spark version, we have already made the logs (offset log, file source log, file sink log) use json. We should added tests with actual json files in the Spark such that any incompatible changes in reading the logs is immediately caught. This PR add tests for FileStreamSourceLog, FileStreamSinkLog, and OffsetSeqLog.
How was this patch tested?
new unit tests