From 57e3e52191464f6b8f8ec53a6452dcf86d4704a6 Mon Sep 17 00:00:00 2001 From: Ken Takagiwa Date: Wed, 16 Jul 2014 11:24:08 -0700 Subject: [PATCH] remove not implemented DStream functions in python --- python/pyspark/streaming/dstream.py | 102 ---------------------------- 1 file changed, 102 deletions(-) diff --git a/python/pyspark/streaming/dstream.py b/python/pyspark/streaming/dstream.py index a512517f6e437..6ab9c500450aa 100644 --- a/python/pyspark/streaming/dstream.py +++ b/python/pyspark/streaming/dstream.py @@ -54,50 +54,6 @@ def pyprint(self): """ self._jdstream.pyprint() - def cache(self): - """ - """ - raise NotImplementedError - - def checkpoint(self): - """ - """ - raise NotImplementedError - - def compute(self, time): - """ - """ - raise NotImplementedError - - def context(self): - """ - """ - raise NotImplementedError - - def count(self): - """ - """ - raise NotImplementedError - - def countByValue(self, numPartitions=None): - """ - """ - raise NotImplementedError - - def countByValueAndWindow(self, duration, slideDuration=None): - """ - """ - raise NotImplementedError - - def countByWindow(self, duration, slideDuration=None): - """ - """ - raise NotImplementedError - - def dstream(self): - """ - """ - raise NotImplementedError def filter(self, f): """ @@ -111,16 +67,6 @@ def flatMap(self, f, preservesPartitioning=False): def func(s, iterator): return chain.from_iterable(imap(f, iterator)) return self.mapPartitionsWithIndex(func, preservesPartitioning) - def foreachRDD(self, f, time): - """ - """ - raise NotImplementedError - - def glom(self): - """ - """ - raise NotImplementedError - def map(self, f, preservesPartitioning=False): """ """ @@ -133,11 +79,6 @@ def mapPartitions(self, f): def func(s, iterator): return f(iterator) return self.mapPartitionsWithIndex(func) - def perist(self, storageLevel): - """ - """ - raise NotImplementedError - def reduce(self, func, numPartitions=None): """ @@ -210,49 +151,6 @@ def add_shuffle_key(split, iterator): dstream._partitionFunc = partitionFunc return dstream - - - def reduceByWindow(self, reduceFunc, windowDuration, slideDuration, inReduceTunc): - """ - """ - - raise NotImplementedError - - def repartition(self, numPartitions): - """ - """ - raise NotImplementedError - - def slice(self, fromTime, toTime): - """ - """ - raise NotImplementedError - - def transform(self, transformFunc): - """ - """ - raise NotImplementedError - - def transformWith(self, other, transformFunc): - """ - """ - raise NotImplementedError - - def union(self, that): - """ - """ - raise NotImplementedError - - def window(self, windowDuration, slideDuration=None): - """ - """ - raise NotImplementedError - - def wrapRDD(self, rdd): - """ - """ - raise NotImplementedError - def mapPartitionsWithIndex(self, f, preservesPartitioning=False): return PipelinedDStream(self, f, preservesPartitioning)