org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.lang.String cannot be cast to org.apache.spark.streaming.receiver.Receiver

Stack Overflow | Sachin | 2 months ago
  1. 0

    Spark Streaming Context and JavaSparkContext for parallel processing

    Stack Overflow | 2 months ago | Sachin
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.lang.String cannot be cast to org.apache.spark.streaming.receiver.Receiver
  2. 0

    Step up a simple pipeline with the following configuration Strem -> Projection -> GroupBy -> JavaScript -> Table. This pipeline works if the engine is mapreduce, doesn't run when the engine is spark. Please see the error below. Attached the pipeline configs for MR and Spark. {code} 2016-03-29 08:59:34,551 - INFO [WorkflowDriver:c.c.c.i.a.r.w.WorkflowDriver@166] - Starting Workflow WorkflowSpecification{className='co.cask.cdap.etl.datapipeline.SmartWorkflow', name='DataPipelineWorkflow', description='Data Pipeline Workflow', properties={pipeline.spec={"stages":[{"name":"Table","plugin":{"type":"batchsink","name":"Table","properties":{"schema":"{\"type\":\"record\",\"name\":\"etlSchemaBody\",\"fields\":[{\"name\":\"key\",\"type\":\"string\"},{\"name\":\"remote_host\",\"type\":\"string\"},{\"name\":\"status\",\"type\":\"int\"},{\"name\":\"count\",\"type\":\"long\"}]}","name":"agg","schema.row.field":"key"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"outputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"inputs":["JavaScript"],"outputs":[]},{"name":"Stream","plugin":{"type":"batchsource","name":"Stream","properties":{"format":"clf","name":"logs","duration":"1d"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":[],"outputs":["Projection"]},{"name":"GroupByAggregate","plugin":{"type":"batchaggregator","name":"GroupByAggregate","properties":{"groupByFields":"remote_host,status","aggregates":"count:Count(remote_host)"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":["Projection"],"outputs":["JavaScript"]},{"name":"Projection","plugin":{"type":"transform","name":"Projection","properties":{"convert":"","drop":"ts,headers","rename":""},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":["Stream"],"outputs":["GroupByAggregate"]},{"name":"JavaScript","plugin":{"type":"transform","name":"JavaScript","properties":{"script":"function transform(input, emitter, context) {\n var output \u003d input;\n output.key \u003d input.remote_host + \u0027:\u0027 + input.status;\n emitter.emit(output);\n}","schema":"{\"type\":\"record\",\"name\":\"etlSchemaBody\",\"fields\":[{\"name\":\"key\",\"type\":\"string\"},{\"name\":\"remote_host\",\"type\":\"string\"},{\"name\":\"status\",\"type\":\"int\"},{\"name\":\"count\",\"type\":\"long\"}]}"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"outputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"inputs":["GroupByAggregate"],"outputs":["Table"]}],"connections":[{"from":"GroupByAggregate","to":"JavaScript"},{"from":"Stream","to":"Projection"},{"from":"JavaScript","to":"Table"},{"from":"Projection","to":"GroupByAggregate"}],"resources":{"virtualCores":1,"memoryMB":512},"stageLoggingEnabled":true}}, nodes=[WorkflowActionNode{nodeId=phase-1, program=ScheduleProgramInfo{programName='phase-1', programType=SPARK}, actionSpecification=null}], localDatasetSpecs={}} 2016-03-29 08:59:34,554 - INFO [NettyHttpService STARTING:c.c.h.NettyHttpService@258] - Starting service on address localhost/127.0.0.1:0... 2016-03-29 08:59:34,557 - INFO [NettyHttpService STARTING:c.c.h.NettyHttpService@263] - Started service on address /127.0.0.1:53268 2016-03-29 08:59:34,680 - INFO [WorkflowDriver:c.c.c.i.a.r.w.WorkflowProgramController@78] - Workflow service workflow.default.PipelineSpark.DataPipelineWorkflow.3afaa533-f5c7-11e5-b854-2e84265fb0e5 announced at /127.0.0.1:53268 2016-03-29 08:59:34,681 - INFO [WorkflowDriver:c.c.c.i.a.r.w.WorkflowDriver@480] - Start workflow execution for WorkflowSpecification{className='co.cask.cdap.etl.datapipeline.SmartWorkflow', name='DataPipelineWorkflow', description='Data Pipeline Workflow', properties={pipeline.spec={"stages":[{"name":"Table","plugin":{"type":"batchsink","name":"Table","properties":{"schema":"{\"type\":\"record\",\"name\":\"etlSchemaBody\",\"fields\":[{\"name\":\"key\",\"type\":\"string\"},{\"name\":\"remote_host\",\"type\":\"string\"},{\"name\":\"status\",\"type\":\"int\"},{\"name\":\"count\",\"type\":\"long\"}]}","name":"agg","schema.row.field":"key"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"outputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"inputs":["JavaScript"],"outputs":[]},{"name":"Stream","plugin":{"type":"batchsource","name":"Stream","properties":{"format":"clf","name":"logs","duration":"1d"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":[],"outputs":["Projection"]},{"name":"GroupByAggregate","plugin":{"type":"batchaggregator","name":"GroupByAggregate","properties":{"groupByFields":"remote_host,status","aggregates":"count:Count(remote_host)"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":["Projection"],"outputs":["JavaScript"]},{"name":"Projection","plugin":{"type":"transform","name":"Projection","properties":{"convert":"","drop":"ts,headers","rename":""},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"inputs":["Stream"],"outputs":["GroupByAggregate"]},{"name":"JavaScript","plugin":{"type":"transform","name":"JavaScript","properties":{"script":"function transform(input, emitter, context) {\n var output \u003d input;\n output.key \u003d input.remote_host + \u0027:\u0027 + input.status;\n emitter.emit(output);\n}","schema":"{\"type\":\"record\",\"name\":\"etlSchemaBody\",\"fields\":[{\"name\":\"key\",\"type\":\"string\"},{\"name\":\"remote_host\",\"type\":\"string\"},{\"name\":\"status\",\"type\":\"int\"},{\"name\":\"count\",\"type\":\"long\"}]}"},"artifact":{"name":"core-plugins","version":{"version":"1.3.0-SNAPSHOT","major":1,"minor":3,"fix":0,"suffix":"SNAPSHOT"},"scope":"SYSTEM"}},"outputSchema":{"type":"record","name":"etlSchemaBody","fields":[{"name":"key","type":"string"},{"name":"remote_host","type":"string"},{"name":"status","type":"int"},{"name":"count","type":"long"}]},"inputs":["GroupByAggregate"],"outputs":["Table"]}],"connections":[{"from":"GroupByAggregate","to":"JavaScript"},{"from":"Stream","to":"Projection"},{"from":"JavaScript","to":"Table"},{"from":"Projection","to":"GroupByAggregate"}],"resources":{"virtualCores":1,"memoryMB":512},"stageLoggingEnabled":true}}, nodes=[WorkflowActionNode{nodeId=phase-1, program=ScheduleProgramInfo{programName='phase-1', programType=SPARK}, actionSpecification=null}], localDatasetSpecs={}} 2016-03-29 08:59:34,683 - INFO [action-phase-1-0:c.c.c.i.w.ProgramWorkflowAction@63] - Starting Program for workflow action: phase-1 2016-03-29 08:59:35,170 - INFO [action-phase-1-0:c.c.c.i.a.r.s.SparkProgramRunner@170] - Starting Spark Job: SparkContext{id=program:default.PipelineSpark.spark.phase-1, runId=3b4c6eb4-f5c7-11e5-a050-2e84265fb0e5} 2016-03-29 08:59:40,081 - INFO [action-phase-1-0:c.c.c.i.w.ProgramWorkflowAction@71] - Failed to execute SPARK Program phase-1 in workflow java.lang.RuntimeException: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.base.Throwables.propagate(Throwables.java:160) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.workflow.AbstractProgramWorkflowRunner$1.run(AbstractProgramWorkflowRunner.java:116) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.workflow.ProgramWorkflowAction.run(ProgramWorkflowAction.java:64) ~[co.cask.cdap.cdap-api-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:293) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:290) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_79] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_79] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_79] at java.lang.Thread.run(Thread.java:745) [na:1.7.0_79] Caused by: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:294) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:281) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService.run(SparkRuntimeService.java:228) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService$2$1.run(SparkRuntimeService.java:294) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] ... 1 common frames omitted org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1204) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1193) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) ~[org.scala-lang.scala-library-2.10.4.jar:na] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.Option.foreach(Option.scala:236) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1393) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1354) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] 2016-03-29 08:59:40,083 - ERROR [WorkflowDriver:c.c.c.i.a.r.w.WorkflowDriver@299] - Error executing the action phase-1 in the Workflow program_run:default.PipelineSpark.workflow.DataPipelineWorkflow.3afaa533-f5c7-11e5-b854-2e84265fb0e5. java.util.concurrent.ExecutionException: java.lang.RuntimeException: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[na:1.7.0_79] at java.util.concurrent.FutureTask.get(FutureTask.java:188) ~[na:1.7.0_79] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAction(WorkflowDriver.java:297) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeNode(WorkflowDriver.java:408) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAll(WorkflowDriver.java:494) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.run(WorkflowDriver.java:482) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) [com.google.guava.guava-13.0.1.jar:na] at java.lang.Thread.run(Thread.java:745) [na:1.7.0_79] Caused by: java.lang.RuntimeException: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.base.Throwables.propagate(Throwables.java:160) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.workflow.AbstractProgramWorkflowRunner$1.run(AbstractProgramWorkflowRunner.java:116) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.workflow.ProgramWorkflowAction.run(ProgramWorkflowAction.java:64) ~[co.cask.cdap.cdap-api-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:293) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:290) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at java.util.concurrent.FutureTask.run(FutureTask.java:262) ~[na:1.7.0_79] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_79] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) ~[na:1.7.0_79] ... 1 common frames omitted Caused by: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:294) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:281) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService.run(SparkRuntimeService.java:228) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) [com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService$2$1.run(SparkRuntimeService.java:294) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] ... 1 common frames omitted org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1204) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1193) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) ~[org.scala-lang.scala-library-2.10.4.jar:na] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.Option.foreach(Option.scala:236) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1393) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1354) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] 2016-03-29 08:59:40,086 - INFO [NettyHttpService STOPPING:c.c.h.NettyHttpService@275] - Stopping service on address /127.0.0.1:53268... 2016-03-29 08:59:40,087 - INFO [NettyHttpService STOPPING:c.c.h.NettyHttpService@289] - Done stopping service on address /127.0.0.1:53268 2016-03-29 08:59:40,088 - INFO [WorkflowDriver:c.c.c.i.a.r.w.WorkflowProgramController@98] - Workflow service failed from RUNNING. Un-registering service workflow.default.PipelineSpark.DataPipelineWorkflow.3afaa533-f5c7-11e5-b854-2e84265fb0e5. java.lang.RuntimeException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.base.Throwables.propagate(Throwables.java:160) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAll(WorkflowDriver.java:501) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.run(WorkflowDriver.java:482) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) ~[com.google.guava.guava-13.0.1.jar:na] at java.lang.Thread.run(Thread.java:745) [na:1.7.0_79] org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1204) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1193) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) ~[org.scala-lang.scala-library-2.10.4.jar:na] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.Option.foreach(Option.scala:236) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1393) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1354) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] 2016-03-29 08:59:40,089 - INFO [WorkflowDriver:c.c.c.i.a.r.w.WorkflowProgramController@100] - Service workflow.default.PipelineSpark.DataPipelineWorkflow.3afaa533-f5c7-11e5-b854-2e84265fb0e5 unregistered. 2016-03-29 08:59:40,090 - INFO [pcontroller-program:default.PipelineSpark.workflow.DataPipelineWorkflow-3afaa533-f5c7-11e5-b854-2e84265fb0e5:c.c.c.i.a.s.ProgramLifecycleService@323] - Program stopped with error program:default.PipelineSpark.workflow.DataPipelineWorkflow, 3afaa533-f5c7-11e5-b854-2e84265fb0e5 java.lang.RuntimeException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.base.Throwables.propagate(Throwables.java:160) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAll(WorkflowDriver.java:501) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.run(WorkflowDriver.java:482) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) ~[com.google.guava.guava-13.0.1.jar:na] at java.lang.Thread.run(Thread.java:745) [na:1.7.0_79] org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.util.collection.ExternalSorter.insertAll(ExternalSorter.scala:210) at org.apache.spark.shuffle.sort.SortShuffleWriter.write(SortShuffleWriter.scala:63) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:68) at org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:41) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1204) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1193) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) ~[org.scala-lang.scala-library-2.10.4.jar:na] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.Option.foreach(Option.scala:236) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1393) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1354) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] 2016-03-29 08:59:40,094 - DEBUG [pcontroller-program:default.PipelineSpark.workflow.DataPipelineWorkflow-3afaa533-f5c7-11e5-b854-2e84265fb0e5:c.c.c.a.r.AbstractProgramRuntimeService@338] - Removing RuntimeInfo: Workflow DataPipelineWorkflow 3afaa533-f5c7-11e5-b854-2e84265fb0e5 2016-03-29 08:59:40,095 - DEBUG [pcontroller-program:default.PipelineSpark.workflow.DataPipelineWorkflow-3afaa533-f5c7-11e5-b854-2e84265fb0e5:c.c.c.a.r.AbstractProgramRuntimeService@341] - RuntimeInfo removed: RuntimeInfo{type=Workflow, appId=PipelineSpark, programId=DataPipelineWorkflow} {code}

    Cask Community Issue Tracker | 8 months ago | Sreevatsan Raman
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord
  3. 0

    The attached pipeline runs clean as MR, but when changed to Spark engine it fails with: 2016-04-13 10:05:55,830 - ERROR [WorkflowDriver:c.c.c.i.a.r.w.WorkflowDriver@304] - Error executing the action phase-1 in the Workflow program_run:Tst.Clinical_spark.workflow.DataPipelineWorkflow.d494c4fa-0180-11e6-bbf2-f07959633aa6. java.util.concurrent.ExecutionException: java.lang.RuntimeException: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:248) at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:172) at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:79) at org.apache.spark.rdd.RDD.iterator(RDD.scala:242) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[na:1.7.0_76] at java.util.concurrent.FutureTask.get(FutureTask.java:188) ~[na:1.7.0_76] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAction(WorkflowDriver.java:302) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeNode(WorkflowDriver.java:424) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.executeAll(WorkflowDriver.java:510) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver.run(WorkflowDriver.java:498) [co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) [com.google.guava.guava-13.0.1.jar:na] at java.lang.Thread.run(Thread.java:745) [na:1.7.0_76] Caused by: java.lang.RuntimeException: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:248) at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:172) at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:79) at org.apache.spark.rdd.RDD.iterator(RDD.scala:242) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.base.Throwables.propagate(Throwables.java:160) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.workflow.AbstractProgramWorkflowRunner$1.run(AbstractProgramWorkflowRunner.java:120) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.workflow.ProgramWorkflowAction.run(ProgramWorkflowAction.java:64) ~[co.cask.cdap.cdap-api-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:298) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at co.cask.cdap.internal.app.runtime.workflow.WorkflowDriver$1.call(WorkflowDriver.java:295) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at java.util.concurrent.FutureTask.run(FutureTask.java:262) ~[na:1.7.0_76] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_76] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) ~[na:1.7.0_76] ... 1 common frames omitted Caused by: java.util.concurrent.ExecutionException: org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:248) at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:172) at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:79) at org.apache.spark.rdd.RDD.iterator(RDD.scala:242) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:294) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:281) ~[com.google.guava.guava-13.0.1.jar:na] at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116) ~[com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService.run(SparkRuntimeService.java:228) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] at com.google.common.util.concurrent.AbstractExecutionThreadService$1$1.run(AbstractExecutionThreadService.java:52) [com.google.guava.guava-13.0.1.jar:na] at co.cask.cdap.internal.app.runtime.spark.SparkRuntimeService$2$1.run(SparkRuntimeService.java:294) ~[co.cask.cdap.cdap-app-fabric-3.4.0-SNAPSHOT.jar:na] ... 1 common frames omitted org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:147) at co.cask.hydrator.plugin.batch.source.StreamBatchSource.transform(StreamBatchSource.java:54) at co.cask.cdap.etl.common.TrackedTransform.transform(TrackedTransform.java:43) at co.cask.cdap.etl.common.TransformExecutor.executeTransformation(TransformExecutor.java:86) at co.cask.cdap.etl.common.TransformExecutor.runOneIteration(TransformExecutor.java:49) at co.cask.cdap.etl.batch.spark.ETLSparkProgram$TransformExecutorFunction.call(ETLSparkProgram.java:242) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at org.apache.spark.api.java.JavaRDDLike$$anonfun$fn$3$1.apply(JavaRDDLike.scala:142) at scala.collection.Iterator$$anon$13.hasNext(Iterator.scala:371) at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:248) at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:172) at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:79) at org.apache.spark.rdd.RDD.iterator(RDD.scala:242) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:35) at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:277) at org.apache.spark.rdd.RDD.iterator(RDD.scala:244) at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61) at org.apache.spark.scheduler.Task.run(Task.scala:64) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:203) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Driver stacktrace: at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1204) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1193) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) ~[org.scala-lang.scala-library-2.10.4.jar:na] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1192) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at scala.Option.foreach(Option.scala:236) ~[org.scala-lang.scala-library-2.10.4.jar:na] at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:693) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1393) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1354) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1] at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48) ~[org.apache.spark.spark-core_2.10-1.3.1.jar:1.3.1]

    Cask Community Issue Tracker | 8 months ago | Dave Finnegan
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.nio.HeapByteBuffer cannot be cast to co.cask.cdap.api.data.format.StructuredRecord
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Working with arraybuffers in Spark UDAF's

    Stack Overflow | 8 months ago | Abhishek Modi
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: scala.collection.mutable.WrappedArray$ofRef cannot be cast to scala.collection.mutable.ArrayBuffer
  6. 0

    From the user list. It looks like data is not implemented correctly in in-memory caching. We should also check the JDBC datasource support for date. {code} Stack trace of an exception being reported since upgrade to 1.3.0: java.lang.ClassCastException: java.sql.Date cannot be cast to java.lang.Integer at scala.runtime.BoxesRunTime.unboxToInt(BoxesRunTime.java:105) ~[scala-library-2.11.6.jar:na] at org.apache.spark.sql.catalyst.expressions.GenericRow.getInt(rows.scala:83) ~[spark-catalyst_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.IntColumnStats.gatherStats(ColumnStats.scala:191) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.NullableColumnBuilder$class.appendFrom(NullableColumnBuilder.scala:56) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.NativeColumnBuilder.org$apache$spark$sql$columnar$compression$CompressibleColumnBuilder$$super$appendFrom(ColumnBuilder.scala:87) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.compression.CompressibleColumnBuilder$class.appendFrom(CompressibleColumnBuilder.scala:78) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.NativeColumnBuilder.appendFrom(ColumnBuilder.scala:87) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at org.apache.spark.sql.columnar.InMemoryRelation$$anonfun$3$$anon$1.next(InMemoryColumnarTableScan.scala:135) ~[spark-sql_2.11-1.3.0.jar:1.3.0] at {code}

    Apache's JIRA Issue Tracker | 2 years ago | Michael Armbrust
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: org.apache.spark.sql.catalyst.expressions.MutableAny cannot be cast to org.apache.spark.sql.catalyst.expressions.MutableInt

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.apache.spark.SparkException

      Job aborted due to stage failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0 (TID 0, localhost): java.lang.ClassCastException: java.lang.String cannot be cast to org.apache.spark.streaming.receiver.Receiver

      at org.apache.spark.streaming.scheduler.ReceiverTracker$ReceiverLauncher$$anonfun$8.apply()
    2. Spark Project Streaming
      ReceiverTracker$ReceiverLauncher$$anonfun$8.apply
      1. org.apache.spark.streaming.scheduler.ReceiverTracker$ReceiverLauncher$$anonfun$8.apply(ReceiverTracker.scala:305)
      2. org.apache.spark.streaming.scheduler.ReceiverTracker$ReceiverLauncher$$anonfun$8.apply(ReceiverTracker.scala:300)
      2 frames
    3. Spark
      Executor$TaskRunner.run
      1. org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1767)
      2. org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1767)
      3. org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:63)
      4. org.apache.spark.scheduler.Task.run(Task.scala:70)
      5. org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:213)
      5 frames
    4. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      3. java.lang.Thread.run(Thread.java:745)
      3 frames