I would suggest converting your RDDs to Dataframes (or SchemaRDDs depending on
your version) and performing a native join.
mn
> On Aug 25, 2015, at 9:22 AM, Priya Ch wrote:
>
> Hi All,
>
> I have the following scenario:
>
> There exists a booking table in cassandra, which holds the fields like,
> bookingid, passengeName, contact etc etc.
>
> Now in my spark streaming application, there is one class Booking which acts
> as a container and holds all the field details -
>
> class Booking
> {
>val bookingid =...
>val passengerName = ...
>val contact = ...
>.
>.
>.
>.
> }
>
> when a new booking message comes in I populate the fields in the class which
> create rdds of type RDD[Booking]. Now I have this rdd to cassandra table
> Booking as rdd.saveToCassandra.
>
> Lets say if I query on booking table I would get cassandraRDD[CassandraRow]
> If I want to join RDD[Booking] with this cassandraRDD...how is it
> possible...as these are of two different rdds ?
>
> converting CassandraRDD to RDD[CassandraRow] would make things work ?
>
> Thanks,
> Padma Ch
-
To unsubscribe, e-mail: user-unsubscr...@spark.apache.org
For additional commands, e-mail: user-h...@spark.apache.org