com.here.platform.data.processing.driver.impl.state
StateSerializer
Companion object StateSerializer
class StateSerializer[K, V] extends AnyRef
Serializes the compiler state represented as RDD[K, V] to/from an RDD[K, Payload]. The compiler-specific serializer for a single spark partition needs to be defined when instantiating class. This class saves tha state in a deterministic way by:
- partitioning by key - sorting by key inside the partitions
- K
the type of the state key, to write the state in a stable way this type must have an ordering
- V
the type of the state values
- Alphabetic
- By Inheritance
- StateSerializer
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new StateSerializer(statePartitionSerializer: StatePartitionSerializer[K, V], partitions: Int)(implicit arg0: Ordering[K], arg1: ClassTag[K], arg2: ClassTag[V])
- statePartitionSerializer
the partition.StatePartitionSerializer to serialize state information
- partitions
the maximum number of partitions in which to group the state entries
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- def deserializeRDD(prefixKey: Key, rdd: RDD[(Key, Payload)]): RDD[(K, V)]
Deserializes an RDD of prefix keys and com.here.platform.data.processing.blobstore.Payload.
Deserializes an RDD of prefix keys and com.here.platform.data.processing.blobstore.Payload. Each Payload consisting of a scala.List of items of type (K,V) serialized using a given object serializer.
- prefixKey
the prefix key to select the partitions
- rdd
the RDD to be deserialized
- returns
the deserialized RDD
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- val partitioner: Partitioner[Key]
- def serializeRDD(prefixKey: Key, rdd: RDD[(K, V)]): RDD[(Key, Payload)]
Serializes an RDD of (K,V) in another RDD of com.here.platform.data.processing.blobstore.Payload consisting of a Iterable[(K, V)] serialized using specific serializer.
Serializes an RDD of (K,V) in another RDD of com.here.platform.data.processing.blobstore.Payload consisting of a Iterable[(K, V)] serialized using specific serializer. The RDD is serialized by partitions. Each RDD partition is encoded into a single com.here.platform.data.processing.blobstore.Payload and a catalog partition key is generated out of a template key, so that the result set of payloads can be committed to a catalog.
- prefixKey
the catalog template key where the serialized RDD is going to be published
- rdd
the RDD to be serialized
- returns
the serialized RDD ready to be uploaded
- Note
an hash based repartitioning happens in this function
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)