Spark Streaming

2014-07-17 Thread Guangle Fan
Hi, All When I run spark streaming, in one of the flatMap stage, I want to access database. Code looks like : stream.flatMap( new FlatMapFunction { call () { //access database cluster } } ) Since I don't want to create database connection every time call() was called, where is

Re: Spark Streaming

2014-07-18 Thread Guangle Fan
JVM. > > TD > > > On Thu, Jul 17, 2014 at 4:41 PM, Guangle Fan wrote: > >> Hi, All >> >> When I run spark streaming, in one of the flatMap stage, I want to access >> database. >> >> Code looks like : >> >> stream.