Re: Thread-safety of a SparkListener

2016-04-01 Thread Marcelo Vanzin
On Fri, Apr 1, 2016 at 9:23 AM, Truong Duc Kien wrote: > I need to gather some metrics using a SparkListener. Does the callback > methods need to thread-safe or they are always call from the same thread ? The callbacks are all fired on the same thread. Just be careful

Re: Thread-safety of a SparkListener

2016-04-01 Thread Truong Duc Kien
I need to process the events related to Task, Stage and Executor. Regards, Kien Truong On Fri, Apr 1, 2016 at 5:34 PM, Ted Yu wrote: > In general, you should implement thread-safety in your code. > > Which set of events are you interested in ? > > Cheers > > On Fri, Apr 1,

Re: Thread-safety of a SparkListener

2016-04-01 Thread Ted Yu
In general, you should implement thread-safety in your code. Which set of events are you interested in ? Cheers On Fri, Apr 1, 2016 at 9:23 AM, Truong Duc Kien wrote: > Hi, > > I need to gather some metrics using a SparkListener. Does the callback > methods need to

Thread-safety of a SparkListener

2016-04-01 Thread Truong Duc Kien
Hi, I need to gather some metrics using a SparkListener. Does the callback methods need to thread-safe or they are always call from the same thread ? Thanks, Kien Truong