gearpump-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vincent Wang <fvunic...@gmail.com>
Subject Re: [jira] [Commented] (GEARPUMP-300) java.io.NotSerializableException official DSL version for Wordcount in java
Date Fri, 28 Apr 2017 08:04:23 GMT
Hi Yanghua, can you describe a little about how to reproduce this exception?

yanghua (JIRA) <jira@apache.org>于2017年4月28日周五 上午8:45写道:

>
>     [
> https://issues.apache.org/jira/browse/GEARPUMP-300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15987957#comment-15987957
> ]
>
> yanghua commented on GEARPUMP-300:
> ----------------------------------
>
> I try to find the problem, in source code :
> https://github.com/apache/incubator-gearpump/blob/master/streaming/src/main/scala/org/apache/gearpump/streaming/dsl/scalaapi/StreamApp.scala#L94
>  here need a Iterator and will be serialized.
> And in JavaStreamApp it seams if pass a ArrayList‘s instance it will use
> ArrayList's inner Itr(Iterator's implementation),
>
> https://github.com/apache/incubator-gearpump/blob/master/streaming/src/main/scala/org/apache/gearpump/streaming/dsl/javaapi/JavaStreamApp.scala#L36
>  but Itr is not serializable.
>
> > java.io.NotSerializableException official DSL version for Wordcount in
> java
> >
> ---------------------------------------------------------------------------
> >
> >                 Key: GEARPUMP-300
> >                 URL: https://issues.apache.org/jira/browse/GEARPUMP-300
> >             Project: Apache Gearpump
> >          Issue Type: Bug
> >            Reporter: yanghua
> >
> > java.io.NotSerializableException: java.util.ArrayList$Itr
> >       at
> java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1184)
> >       at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1548)
> >       at
> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1509)
> >       at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1432)
> >       at
> java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1178)
> >       at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1548)
> >       at
> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1509)
> >       at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1432)
> >       at
> java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1178)
> >       at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1548)
> >       at
> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1509)
> >       at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1432)
> >       at
> java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1178)
> >       at
> java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1548)
> >       at
> java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1509)
> >       at
> java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1432)
> >       at
> java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1178)
> >       at
> java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:348)
> >       at
> akka.serialization.JavaSerializer$$anonfun$toBinary$1.apply$mcV$sp(Serializer.scala:235)
> >       at
> akka.serialization.JavaSerializer$$anonfun$toBinary$1.apply(Serializer.scala:235)
> >       at
> akka.serialization.JavaSerializer$$anonfun$toBinary$1.apply(Serializer.scala:235)
> >       at scala.util.DynamicVariable.withValue(DynamicVariable.scala:58)
> >       at akka.serialization.JavaSerializer.toBinary(Serializer.scala:235)
> >       at
> org.apache.gearpump.cluster.UserConfig.withValue(UserConfig.scala:139)
> >       at
> org.apache.gearpump.streaming.dsl.plan.DataSourceOp.getProcessor(OP.scala:98)
> >       at
> org.apache.gearpump.streaming.dsl.plan.Planner$$anonfun$plan$2.apply(Planner.scala:50)
> >       at
> org.apache.gearpump.streaming.dsl.plan.Planner$$anonfun$plan$2.apply(Planner.scala:50)
> >       at org.apache.gearpump.util.Graph$$anonfun$1.apply(Graph.scala:143)
> >       at org.apache.gearpump.util.Graph$$anonfun$1.apply(Graph.scala:143)
> >       at scala.collection.immutable.List.map(List.scala:277)
> >       at org.apache.gearpump.util.Graph.mapVertex(Graph.scala:143)
> >       at
> org.apache.gearpump.streaming.dsl.plan.Planner.plan(Planner.scala:50)
> >       at
> org.apache.gearpump.streaming.dsl.StreamApp.plan(StreamApp.scala:62)
> >       at
> org.apache.gearpump.streaming.dsl.StreamApp$.streamAppToApplication(StreamApp.scala:74)
> >       at
> org.apache.gearpump.streaming.dsl.javaapi.JavaStreamApp.run(JavaStreamApp.scala:45)
> >       at com.github.gearpump.demo.WordCount.main(WordCount.java:119)
> >       at com.github.gearpump.demo.WordCount.main(WordCount.java:25)
> >       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> >       at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> >       at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> >       at java.lang.reflect.Method.invoke(Method.java:498)
> >       at
> org.apache.gearpump.cluster.main.AppSubmitter$.main(AppSubmitter.scala:87)
> >       at
> org.apache.gearpump.util.AkkaApp$$anonfun$main$1.apply(AkkaApp.scala:42)
> >       at
> org.apache.gearpump.util.AkkaApp$$anonfun$main$1.apply(AkkaApp.scala:42)
> >       at scala.util.Try$.apply(Try.scala:192)
> >       at org.apache.gearpump.util.AkkaApp$class.main(AkkaApp.scala:41)
> >       at
> org.apache.gearpump.cluster.main.AppSubmitter$.main(AppSubmitter.scala:28)
> >       at
> org.apache.gearpump.cluster.main.Gear$.executeCommand(Gear.scala:40)
> >       at org.apache.gearpump.cluster.main.Gear$.main(Gear.scala:59)
> >       at org.apache.gearpump.cluster.main.Gear.main(Gear.scala)
>
>
>
> --
> This message was sent by Atlassian JIRA
> (v6.3.15#6346)
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message