class InMemoryRawStorage extends RawStorage
Provides a RawStorage
implementation that stores all state in memory.
The primary use-case is to allow the use of Storage in tests.
Note: This class is duplicated and should be changed in both places:
streambed-core/src/test/scala/com/cisco/streambed/storage/InMemoryRawStorage.scala streambed-testkit/src/main/scala/com/cisco/streambed/testkit/storage/InMemoryRawStorage.scala
- Alphabetic
- By Inheritance
- InMemoryRawStorage
- RawStorage
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new InMemoryRawStorage()(implicit system: ActorSystem)
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 clean(key: String, id: UUID): Future[Done]
Removes any data for the given key and id.
Removes any data for the given key and id.
This operation must eventually succeed or fail.
- Attributes
- protected
- Definition Classes
- InMemoryRawStorage → RawStorage
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def load[A](stateCodec: StateCodec[A], namespace: String, id: UUID): Future[Option[A]]
Load a stored object of a specified type given its id.
Load a stored object of a specified type given its id.
- Definition Classes
- RawStorage
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def remove[A](stateCodec: StateCodec[A], namespace: String, id: UUID): Future[Done]
Remove a stored object of a specified type given its id.
Remove a stored object of a specified type given its id. This simply defers to the defined clean method.
- Definition Classes
- RawStorage
- def save[A](stateCodec: StateCodec[A], namespace: String, id: UUID, instance: A): Future[Done]
Save a stored object of a specified type given its id and value.
Save a stored object of a specified type given its id and value.
- Definition Classes
- RawStorage
- def sink(key: String, id: UUID): Sink[ByteString, Future[Done]]
Provides a sink that
ByteString
instances can be sent to.Provides a sink that
ByteString
instances can be sent to. This stored data should be retrievable usingsource
with the same key and id.Implementations do not need to be concerned about concurrency.
This operation must eventually succeed or fail.
- Attributes
- protected
- Definition Classes
- InMemoryRawStorage → RawStorage
- def source(key: String, id: UUID): Future[Option[Source[ByteString, NotUsed]]]
Provides a
Source
ofByteString
for the given key and id, or None if the given key/id hasn't been stored before.Provides a
Source
ofByteString
for the given key and id, or None if the given key/id hasn't been stored before.Implementations do not need to be concerned about concurrency.
This operation must eventually succeed or fail.
- Attributes
- protected
- Definition Classes
- InMemoryRawStorage → RawStorage
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- 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()