You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@spark.apache.org by Adrian Mocanu <am...@verticalscope.com> on 2014/03/04 19:08:00 UTC

how to add rddID to tuples in DStream

Hi
I've another simple question:
I have a DStream and want to add the ID of each RDD to the tuples contained in that RDD and return a DStream of them.
So far I've figured out how to do this via foreachRDD and return RDDs.
How to create a DStream from these RDDs? Or even better, how to use .map to do this on the dstream like
  mystream.map( tuple => (tuple, getRDDIdSomehow) )

-Adrian