I have been POC adding a rest service in a Spark Streaming job. Say I create a stateful DStream X by using updateStateByKey, and each time there is a HTTP request, I want to apply some transformations/actions on the latest RDD of X and collect the results immediately but not scheduled by streaming batch interval.
* Is that even possible? * The reason I think of this is because user can get a list of RDDs by DStream.window.slice but I cannot find a way to get the most recent RDD in the DSteam. -- Chen Song