spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ahmed El-Gamal <ahmed.elga...@badrit.com>
Subject Sorting a DStream and taking topN
Date Sun, 07 Aug 2016 14:43:56 GMT
I have some DStream in Spark Scala and I want to sort it then take the top
N. The problem is that whenever I try to run it I get
NotSerializableException and the exception message says:

This is because the DStream object is being referred to from within the
closure.

The problem is that I don't know how to solve it.

My try is attached with the e-mail.

I don't mind any other ways to sort a DStream and get its top N rather than
my way.

Mime
View raw message