spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dinesh Vallabhdas <dines...@yahoo.com.INVALID>
Subject A spark newbie question
Date Sun, 04 Jan 2015 16:28:08 GMT
A spark cassandra newbie question. Thanks in advance for the help.I have a cassandra table
with 2 columns message_timestamp(timestamp) and message_type(text). The data is of the form2014-06-25
12:01:39 "START"
2014-06-25 12:02:39 "START"
2014-06-25 12:02:39 "PAUSE"
2014-06-25 14:02:39 "STOP"
2014-06-25 15:02:39 "START"
2014-06-27 12:01:39 "START"
2014-06-27 11:03:39 "STOP"
2014-06-27 12:03:39 "REWIND"
2014-06-27 12:04:39 "RESTART"
2014-06-27 12:05:39 "PAUSE"
2014-06-27 13:03:39 "REWIND"
2014-06-27 14:03:39 "START"
I want to use spark(using java) to calculate counts of a message_type on a per day basis and
store it back in cassandra in a new table with 3 columns (date,message_type,count).The result
table should look like this2014-06-25 START 3
2014-06-25 STOP 1
2014-06-25 PAUSE 1
2014-06-27 START 2
2014-06-27 STOP 1
2014-06-27 PAUSE 1
2014-06-27 REWIND 2
2014-06-27 RESTART 1
I'm not proficient in scala and would like to use java.


Mime
View raw message