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 http

    High level Akka http utilities e.g.

    High level Akka http utilities e.g. making it easier to bind and handle an HTTP port with a TLS certificate as per com.cisco.streambed.http.HttpServerConfig.

    Definition Classes
    streambed
  • package identity

    Utilities to integrate streambed identity with Akka HTTP identity such that we can support authentication and authorization via OAuth tokens.

    Utilities to integrate streambed identity with Akka HTTP identity such that we can support authentication and authorization via OAuth tokens. A Java example of an Akka HTTP route that verifies a token, and returning the corresponding com.cisco.streambed.identity.Principal given a valid one.

    pathPrefix("api", () ->
            authenticateOAuth2Async("secured api", identityService::verifier, principal -> route(...
    Definition Classes
    http
  • ActorPrincipalProxy
  • UserIdentityService

package identity

Utilities to integrate streambed identity with Akka HTTP identity such that we can support authentication and authorization via OAuth tokens. A Java example of an Akka HTTP route that verifies a token, and returning the corresponding com.cisco.streambed.identity.Principal given a valid one.

pathPrefix("api", () ->
        authenticateOAuth2Async("secured api", identityService::verifier, principal -> route(...
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. identity
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. class ActorPrincipalProxy extends Actor with Stash with Timers

    Manages short-lived ActorPrincipal instances, acting as a proxy between call site and the actual principal.

    Manages short-lived ActorPrincipal instances, acting as a proxy between call site and the actual principal. When an ActorPrincipal has shutdown due to its TTL elapsing, the proxy can still reply to any requests with a Principal.Unauthenticated.

  2. final class UserIdentityService extends AnyRef

    Provides HTTP services concerning user principal identity

Value Members

  1. object ActorPrincipalProxy
  2. object UserIdentityService

Inherited from AnyRef

Inherited from Any

Ungrouped