Queries with streaming sources must be executed with writeStream.start();;

2018-03-27 Thread Junfeng Chen
I am reading some data from kafka, and willing to save them to parquet on hdfs with structured streaming. The data from kafka is in JSON format. I try to convert them to DataSet with spark.read.json(). However, I get the exception: > > Queries with streaming sources must be execute

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-12 Thread kant kodali
start(); >>>>> query.awaitTermination(); >>>>> >>>>> >>>>> On Sat, Sep 9, 2017 at 4:20 PM, Felix Cheung < >>>>> felixcheun...@hotmail.com> wrote: >>>>> >>>>>> What is newDS? >>>>

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-12 Thread kant kodali
string}); >>>> StreamingQuery query = ds.writeStream().start(); >>>> query.awaitTermination(); >>>> >>>> >>>> On Sat, Sep 9, 2017 at 4:20 PM, Felix Cheung >>> > wrote: >>>> >>>>> What is newDS? >&

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-11 Thread Michael Armbrust
gt;>>> If it is a Streaming Dataset/DataFrame (since you have writeStream >>>> there) then there seems to be an issue preventing toJSON to work. >>>> >>>> -- >>>> *From:* kant kodali >>>> *Sent:* Sa

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-09 Thread kant kodali
Streaming Dataset/DataFrame (since you have writeStream >>> there) then there seems to be an issue preventing toJSON to work. >>> >>> ---------- >>> *From:* kant kodali >>> *Sent:* Saturday, September 9, 2017 4:04:33 PM >>> *To:* user @spark >&

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-09 Thread Shixiong(Ryan) Zhu
is newDS? >> If it is a Streaming Dataset/DataFrame (since you have writeStream there) >> then there seems to be an issue preventing toJSON to work. >> >> -- >> *From:* kant kodali >> *Sent:* Saturday, September 9, 2017

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-09 Thread kant kodali
k > *Subject:* Queries with streaming sources must be executed with > writeStream.start() > > Hi All, > > I have the following code and I am not sure what's wrong with it? I > cannot call dataset.toJSON() (which returns a DataSet) ? I am using spark > 2.2.0 so I a

Re: Queries with streaming sources must be executed with writeStream.start()

2017-09-09 Thread Felix Cheung
sources must be executed with writeStream.start() Hi All, I have the following code and I am not sure what's wrong with it? I cannot call dataset.toJSON() (which returns a DataSet) ? I am using spark 2.2.0 so I am wondering if there is any work around? Dataset ds = newDS.toJSON().map(()-&

Queries with streaming sources must be executed with writeStream.start()

2017-09-09 Thread kant kodali
Hi All, I have the following code and I am not sure what's wrong with it? I cannot call dataset.toJSON() (which returns a DataSet) ? I am using spark 2.2.0 so I am wondering if there is any work around? Dataset ds = newDS.toJSON().map(()->{some function that returns a string}); StreamingQuery