Closed juanrh closed 8 years ago
Consider using the following code to stop the streaming context in DStreamProp.forall
when a counterexample is found
Try {
ssc.stop(stopSparkContext = false, stopGracefully = true)
} recover {
case _ => ssc.stop(stopSparkContext=false, stopGracefully=false)
}
fixed in 0.2.1-SNAPSHOT
when using the trait DStreamTLProperty
and calling `forAllDStream
That should include, at least:
DStreamProp.forall
. CurrentlycurrFormulaLock
is defined asnew Serializable{}
instead ofnew Object
to avoid a serialization exception during checkpointing. Should use the techniques in http://erikerlandson.github.io/blog/2015/03/31/hygienic-closures-for-scala-function-serialization/ to replace that hack, note we also hygienized closures in https://github.com/juanrh/sscheck/blob/91ff63d5c0dd0007939dd588fb8c49d852f1d097/src/main/scala/es/ucm/fdi/sscheck/matcher/specs2/package.scala, used in https://github.com/juanrh/sscheck/blob/b18347613487a2e3b2479e2ad011ae8f88725838/src/test/scala/es/ucm/fdi/sscheck/spark/streaming/SharedStreamingContextBeforeAfterEachTest.scalathis doesn't break the tests but it is not nice. We could try first stopping gracefully and only then stopping directly, and also try our luck in the spark mailing list