Class/Object

com.twitter.summingbird.scalding.store

VersionedBatchStore

Related Docs: object VersionedBatchStore | package store

Permalink

class VersionedBatchStore[K, V, K2, V2] extends VersionedBatchStoreBase[K, V]

Linear Supertypes
VersionedBatchStoreBase[K, V], BatchedStore[K, V], Store[K, V], Serializable, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. VersionedBatchStore
  2. VersionedBatchStoreBase
  3. BatchedStore
  4. Store
  5. Serializable
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Instance Constructors

  1. new VersionedBatchStore(rootPath: String, versionsToKeep: Int, batcher: Batcher)(pack: (BatchID, (K, V)) ⇒ (K2, V2))(unpack: ((K2, V2)) ⇒ (K, V))(implicit injection: Injection[(K2, V2), (Array[Byte], Array[Byte])], ordering: Ordering[K])

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def batchIDToVersion(b: BatchID): Long

    Permalink

    These functions convert back and forth between a specific BatchID and the earliest time of the BatchID just after it.

    These functions convert back and forth between a specific BatchID and the earliest time of the BatchID just after it.

    The version numbers are the exclusive upper-bound of time covered by this store, while the batchIDs are the inclusive upper bound. Put another way, all events that occured before the version are included in this store.

    Definition Classes
    VersionedBatchStoreBase
  6. val batcher: Batcher

    Permalink

    The batcher for this store

    The batcher for this store

    Definition Classes
    VersionedBatchStoreBatchedStore
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  9. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  12. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  13. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  14. def lastBatch(exclusiveUB: BatchID, mode: Hdfs): Option[(BatchID, FlowProducer[TypedPipe[(K, V)]])]

    Permalink
    Attributes
    protected
    Definition Classes
    VersionedBatchStoreBase
  15. final def merge(delta: PipeFactory[(K, V)], sg: Semigroup[V], commutativity: Commutativity, reducers: Int): PipeFactory[(K, (Option[V], V))]

    Permalink

    instances of this trait MAY NOT change the logic here.

    instances of this trait MAY NOT change the logic here. This always follows the rule that we look for existing data (avoiding reading deltas in that case), then we fall back to the last checkpointed output by calling readLast. In that case, we compute the results by rolling forward

    Definition Classes
    BatchedStoreStore
  16. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  19. implicit val ordering: Ordering[K]

    Permalink
    Definition Classes
    VersionedBatchStoreBatchedStore
  20. def partialMerge[K1](delta: PipeFactory[(K1, V)], sg: Semigroup[V], commutativity: Commutativity): PipeFactory[(K1, V)]

    Permalink

    For each batch, collect up values with the same key on mapside before the keys are expanded.

    For each batch, collect up values with the same key on mapside before the keys are expanded.

    Definition Classes
    BatchedStoreStore
  21. final def planReadLast: PlannerOutput[(BatchID, FlowProducer[TypedPipe[(K, V)]])]

    Permalink

    This is the monadic version of readLast, returns the BatchID actually on disk

    This is the monadic version of readLast, returns the BatchID actually on disk

    Definition Classes
    BatchedStore
  22. def pruning: PrunedSpace[(K, V)]

    Permalink

    Override this to set up store pruning, by default, no (key,value) pairs are pruned.

    Override this to set up store pruning, by default, no (key,value) pairs are pruned. This is a house keeping function to permanently remove entries matching a criteria.

    Definition Classes
    BatchedStore
  23. final def readAfterLastBatch[T](input: PipeFactory[T]): PlannerOutput[(BatchID, FlowProducer[TypedPipe[(K, V)]], FlowToPipe[T])]

    Permalink

    Reads the input data after the last batch written.

    Reads the input data after the last batch written.

    Returns: - the BatchID of the last batch written - the snapshot of the store just before this state - the data from this input covering all the time SINCE the last snapshot

    Definition Classes
    BatchedStore
  24. def readDeltaLog(delta: PipeFactory[(K, V)]): PipeFactory[(K, V)]

    Permalink

    This combines the current inputs along with the last checkpoint on disk to get a log of all deltas with a timestamp This is useful to leftJoin against a store.

    This combines the current inputs along with the last checkpoint on disk to get a log of all deltas with a timestamp This is useful to leftJoin against a store. TODO: This should not limit to batch boundaries, the batch store should handle only writing the data for full batches, but we can materialize more data if it is needed downstream. Note: the returned time interval NOT include the time of the snapshot data point (which is exactly 1 millisecond before the start of the interval).

    Definition Classes
    BatchedStore
  25. def readLast(exclusiveUB: BatchID, mode: Mode): Try[(BatchID, FlowProducer[TypedPipe[(K, V)]])]

    Permalink

    Returns a snapshot of the store's (K, V) pairs aggregated up to (but not including!) the time covered by the supplied batchID.

    Returns a snapshot of the store's (K, V) pairs aggregated up to (but not including!) the time covered by the supplied batchID.

    Aggregating the readLast for a particular batchID with the stream stored for the same batchID will return the aggregate up to (but not including) batchID.next. Streams deal with inclusive upper bound.

    Definition Classes
    VersionedBatchStoreBaseBatchedStore
  26. def readVersion(v: Long): FlowProducer[TypedPipe[(K, V)]]

    Permalink

    Returns a FlowProducer that supplies all data for the given specific version within this store's rootPath.

    Returns a FlowProducer that supplies all data for the given specific version within this store's rootPath.

    Attributes
    protected
    Definition Classes
    VersionedBatchStoreVersionedBatchStoreBase
  27. val rootPath: String

    Permalink
    Definition Classes
    VersionedBatchStoreBase
  28. def select(b: List[BatchID]): List[BatchID]

    Permalink

    Make sure not to keep more than versionsToKeep when we write out.

    Make sure not to keep more than versionsToKeep when we write out. If this is out of sync with VersionedKeyValSource we can have issues

    Definition Classes
    VersionedBatchStoreBatchedStore
  29. def sumByBatches[K1, V](ins: TypedPipe[(Timestamp, (K1, V))], capturedBatcher: Batcher, commutativity: Commutativity)(implicit arg0: Semigroup[V]): TypedPipe[(LTuple2[K1, BatchID], (Timestamp, V))]

    Permalink
    Attributes
    protected
    Definition Classes
    BatchedStore
  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. final def timeSpanToBatches: PlannerOutput[List[BatchID]]

    Permalink

    This gives the batches needed to cover the requested input This will always be non-empty

    This gives the batches needed to cover the requested input This will always be non-empty

    Definition Classes
    BatchedStore
  32. def toString(): String

    Permalink
    Definition Classes
    VersionedBatchStore → AnyRef → Any
  33. def versionToBatchID(ver: Long): BatchID

    Permalink
    Definition Classes
    VersionedBatchStoreBase
  34. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  35. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  36. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  37. def withInitialBatch(firstNonZero: BatchID): BatchedStore[K, V]

    Permalink

    For (firstNonZero - 1) we read empty.

    For (firstNonZero - 1) we read empty. For all before we error on read. For all later, we proxy On write, we throw if batchID is less than firstNonZero

    Definition Classes
    BatchedStore
  38. def writeLast(batchID: BatchID, lastVals: TypedPipe[(K, V)])(implicit flowDef: FlowDef, mode: Mode): Unit

    Permalink

    writeLast receives an INCLUSIVE upper bound on batchID and a pipe of all key-value pairs aggregated up to (and including) that batchID.

    writeLast receives an INCLUSIVE upper bound on batchID and a pipe of all key-value pairs aggregated up to (and including) that batchID. (Yes, this is confusing, since a number of other methods talk about the EXCLUSIVE upper bound.)

    This implementation of writeLast sinks all key-value pairs out into a VersionedStore directory whose tagged version is the EXCLUSIVE upper bound on batchID, or "batchID.next".

    Definition Classes
    VersionedBatchStoreBatchedStore

Inherited from VersionedBatchStoreBase[K, V]

Inherited from BatchedStore[K, V]

Inherited from Store[K, V]

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped