Packages

  • package root
    Definition Classes
    root
  • package com
    Definition Classes
    root
  • package cisco
    Definition Classes
    com
  • package streambed

    The base package of the Streambed library.

    The base package of the Streambed library. Of note is the com.cisco.streambed.Application suite of types. These types conveniently establish a streambed environment for an application.

    Sample usage from Java:

    /**
     * Bootstraps our application and handles signals
     */
    public class MyServerEntryPoints {
        private static ApplicationProcess applicationProcess = null;
    
        public static void main(String[] args) {
            applicationProcess = new ApplicationProcess(new MyServer());
            applicationProcess.main(args);
        }
    
        public static void trap(int signal) {
          if (applicationProcess != null) {
                applicationProcess.trap(signal);
            }
        }
    }

    ...with MyServer being declared as:

    public class MyServer extends Application {
        @Override
        public void main(String[] args, ApplicationContext context) {
          ..
        }
    }

    The equivalent in Scala:

    object MyServerEntryPoints {
      private lazy val applicationProcess = ApplicationProcess(MyServer)
    
      def main(args: Array[String]): Unit =
        applicationProcess.main(args)
    
      def trap(signal: Int): Unit =
        applicationProcess.trap(signal)
    }

    ...with MyServer being declared as:

    object MyServer extends Application {
      override def main(args: Array[String], applicationContext: ApplicationContext): Unit = {
        ..
      }
    }

    The essential idea is that a regular JVM entry point (MyServerEntryPoints), establishes a com.cisco.streambed.ApplicationProcess of a class named MyServer. The trap method is used by Landlord for whenever an operating systemm signal is sent to the process. My extending com.cisco.streambed.Application, a com.cisco.streambed.ApplicationContext is provided by Streambed, containing almost all of what an application will require in order to startup (an actor system, metrics, logging...). The resources provided within the context are also automatically released on exit.

    Definition Classes
    cisco
  • package testkit

    Various utilities to support streambed based tests

    Various utilities to support streambed based tests

    Definition Classes
    streambed
  • package durablequeue

    An in-memory durable queue to facilitate tests.

    An in-memory durable queue to facilitate tests.

    Sample usage within a Java test:

    DurableQueue durableQueue = InMemoryQueue$.MODULE$.queue(mat, system);

    Sample usage within a Scala test:

    val durableQueue = InMemoryQueue.queue()
    Definition Classes
    testkit
  • package identity
    Definition Classes
    testkit
  • package ioxssslite

    Provides types for testing against the IOx Secret Storage Service.

    Provides types for testing against the IOx Secret Storage Service.

    Sample usage from within a Scala based test (utest):

    'ping - {
      IOxSSSServer.withTestServer { binding =>
        request(binding, HttpMethods.GET, "/ping")
          .map {
            assertMatch(_) {
              case (200, "pong!") =>
            }
          }
      }
    }
    Definition Classes
    testkit
  • package ioxsssliteserver

    Provides an application that runs com.cisco.streambed.testkit.ioxssslite so that developers are able to test without needing to deploy on IOx.

    Provides an application that runs com.cisco.streambed.testkit.ioxssslite so that developers are able to test without needing to deploy on IOx.

    Definition Classes
    testkit
  • package storage
    Definition Classes
    testkit
  • InMemoryRawStorage
  • NumberTestState
  • RawStorageTestSuite
  • StorageOps
  • StringTestState

package storage

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. Protected

Type Members

  1. class InMemoryRawStorage extends RawStorage

    Provides a RawStorage implementation that stores all state in memory.

    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

  2. case class NumberTestState(number: Int) extends Product with Serializable
  3. abstract class RawStorageTestSuite extends TestSuite with TestKitBase
    Annotations
    @SuppressWarnings()
  4. case class StringTestState(message: String) extends Product with Serializable

Value Members

  1. object InMemoryRawStorage
  2. object NumberTestState extends StateCodec[NumberTestState] with Serializable
  3. object StorageOps

    Contains methods to work with the storage mechanism in tests.

  4. object StringTestState extends StateCodec[StringTestState] with Serializable

Ungrouped