@@ -19,42 +19,28 @@ package org.apache.spark.streaming.api.python
19
19
20
20
import java .util .{List => JList , ArrayList => JArrayList , Map => JMap , Collections }
21
21
22
- import org . apache . spark . api . java .{ JavaSparkContext , JavaPairRDD , JavaRDD }
23
- import org . apache . spark . broadcast . Broadcast
22
+ import scala . reflect . ClassTag
23
+
24
24
import org .apache .spark ._
25
- import org .apache .spark .util .Utils
26
- import java .io ._
27
- import scala .Some
28
- import org .apache .spark .streaming .Duration
29
- import scala .util .control .Breaks ._
30
- import org .apache .spark .broadcast .Broadcast
31
- import scala .Some
32
- import org .apache .spark .streaming .Duration
33
25
import org .apache .spark .rdd .RDD
34
- import org .apache .spark .api .python .PythonRDD
35
-
36
-
26
+ import org .apache .spark .api .python ._
27
+ import org .apache .spark .broadcast .Broadcast
37
28
import org .apache .spark .streaming .{Duration , Time }
38
29
import org .apache .spark .streaming .dstream ._
39
30
import org .apache .spark .streaming .api .java ._
40
- import org .apache .spark .rdd .RDD
41
- import org .apache .spark .api .python ._
42
- import org .apache .spark .api .python .PairwiseRDD
43
-
44
31
45
- import scala .reflect .ClassTag
46
32
47
33
48
34
class PythonDStream [T : ClassTag ](
49
- parent : DStream [T ],
50
- command : Array [Byte ],
51
- envVars : JMap [String , String ],
52
- pythonIncludes : JList [String ],
53
- preservePartitoning : Boolean ,
54
- pythonExec : String ,
55
- broadcastVars : JList [Broadcast [Array [Byte ]]],
56
- accumulator : Accumulator [JList [Array [Byte ]]]
57
- ) extends DStream [Array [Byte ]](parent.ssc) {
35
+ parent : DStream [T ],
36
+ command : Array [Byte ],
37
+ envVars : JMap [String , String ],
38
+ pythonIncludes : JList [String ],
39
+ preservePartitoning : Boolean ,
40
+ pythonExec : String ,
41
+ broadcastVars : JList [Broadcast [Array [Byte ]]],
42
+ accumulator : Accumulator [JList [Array [Byte ]]])
43
+ extends DStream [Array [Byte ]](parent.ssc) {
58
44
59
45
override def dependencies = List (parent)
60
46
@@ -146,8 +132,3 @@ DStream[(Long, Array[Byte])](prev.ssc){
146
132
}
147
133
val asJavaPairDStream : JavaPairDStream [Long , Array [Byte ]] = JavaPairDStream .fromJavaDStream(this )
148
134
}
149
-
150
-
151
-
152
-
153
-
0 commit comments