cc.spray

can

package can

Visibility
  1. Public
  2. All

Type Members

  1. class BufferingRequestStreamActor extends Actor

    An actor that buffers the content of incoming MessageChunk messages as well as a final ChunkedRequestEnd to construct a full HttpResponse instance and dispatch it to a given service actor.

  2. case class ChunkExtension (name: String, value: String) extends Product with Serializable

  3. case class ChunkedRequestContext (request: HttpRequest, remoteAddress: InetAddress) extends Product with Serializable

    An instance of this class serves as argument to the streamActorCreator function of the ServerConfig.

  4. case class ChunkedRequestEnd (extensions: List[ChunkExtension], trailer: List[HttpHeader], responder: RequestResponder) extends Product with Serializable

    Stream actors (see the streamActorCreator member of the ServerConfig) need to be able to handle ChunkedRequestEnd messages, which represent the end of an incoming chunked (streaming) request.

  5. trait ChunkedRequester extends AnyRef

    An instance of this trait is returned by the startChunkedRequest method of an HttpConnection instance.

  6. trait ChunkedResponder extends AnyRef

    A ChunkedResponder is returned by the startChunkedResponse method of a RequestResponder (the responder member of a RequestContext).

  7. case class ChunkedResponseEnd (extensions: List[ChunkExtension], trailer: List[HttpHeader]) extends Product with Serializable

    Receiver actors (see the sendAndReceive method of the HttpConnection) need to be able to handle ChunkedResponseEnd messages, which represent the end of an incoming chunked (streaming) response.

  8. case class ChunkedResponseStart (status: Int, headers: List[HttpHeader]) extends Product with Serializable

    Receiver actors (see the sendAndReceive method of the HttpConnection) need to be able to handle ChunkedResponseStart messages, which signal the arrival of a chunked (streaming) response.

  9. case class ClientConfig (clientActorId: String, userAgentHeader: String, readBufferSize: Int, idleTimeout: Long, reapingCycle: Long, requestTimeout: Long, timeoutCycle: Long, parserConfig: MessageParserConfig) extends PeerConfig with Product with Serializable

    The ClientConfig configures an instance of the HttpClient actor.

  10. case class Connect (host: String, port: Int) extends Product with Serializable

    Message to be send to an HttpClient actor to initiate a new connection to the given host and port.

  11. trait DateTime extends Ordered[DateTime]

    Immutable, fast and efficient Date + Time implementation without any dependencies.

  12. class DefaultReceiverActor extends Actor

    A new instance of the DefaultReceiverActor is used as the receiver actor for send calls on an HttpConnection, that return a Future[HttpResponse].

  13. trait HighLevelHttpClient extends AnyRef

  14. class HttpClient extends HttpPeer

    The actor implementing the spray-can HTTP client functionality.

  15. class HttpClientException extends RuntimeException

    Special exception used for transporting error occuring during HttpClient operations.

  16. trait HttpConnection extends AnyRef

    An instance of this trait represents an HTTP connection to a specific host and port.

  17. case class HttpHeader (name: String, value: String) extends Product2[String, String] with Product with Serializable

    The spray-can model of an HTTP header.

  18. trait HttpMethod extends AnyRef

    Sealed trait modelling an HTTP method.

  19. trait HttpProtocol extends AnyRef

    Sealed trait modelling an HTTP protocol version.

  20. case class HttpRequest (method: HttpMethod, uri: String, headers: List[HttpHeader], body: Array[Byte], protocol: HttpProtocol) extends Product with Serializable

    The spray-can model of an HTTP request.

  21. case class HttpResponse (status: Int, headers: List[HttpHeader], body: Array[Byte], protocol: HttpProtocol) extends Product with Serializable

    The spray-can model of an HTTP response.

  22. class HttpServer extends HttpPeer with ResponsePreparer

    The actor implementing the spray-can HTTP server functionality.

  23. case class MessageChunk (extensions: List[ChunkExtension], body: Array[Byte]) extends Product with Serializable

    Instance of this class represent the individual chunks of a chunked HTTP message (request or response).

  24. case class MessageParserConfig (maxUriLength: Int, maxResponseReasonLength: Int, maxHeaderNameLength: Int, maxHeaderValueLength: Int, maxHeaderCount: Int, maxContentLength: Int, maxChunkExtNameLength: Int, maxChunkExtValueLength: Int, maxChunkExtCount: Int, maxChunkSize: Int) extends Product with Serializable

    The configuration of the HTTP message parser.

  25. trait PeerConfig extends AnyRef

    The common configuration elements of a ServerConfig and a ClientConfig.

  26. class PimpedByteArray extends AnyRef

  27. class PimpedLinearSeq [+A] extends AnyRef

  28. case class RequestContext (request: HttpRequest, remoteAddress: InetAddress, responder: RequestResponder) extends Product with Serializable

    The HttpServer dispatches a RequestContext instance to the service actor (as configured in the ServerConfig of the HttpServer) upon successful reception of an HTTP request.

  29. trait RequestResponder extends AnyRef

    An instance of this trait is used by the application to complete incoming requests.

  30. case class ServerConfig (host: String, port: Int, serverActorId: String, serviceActorId: String, timeoutActorId: String, timeoutTimeout: Long, serverHeader: String, streamActorCreator: Option[(ChunkedRequestContext) ⇒ Actor], readBufferSize: Int, idleTimeout: Long, reapingCycle: Long, requestTimeout: Long, timeoutCycle: Long, parserConfig: MessageParserConfig) extends PeerConfig with Product with Serializable

    The ServerConfig configures an instance of the HttpServer actor.

  31. case class Stats (uptime: Long, requestsDispatched: Long, requestsTimedOut: Long, requestsOpen: Int, connectionsOpen: Int) extends Product with Serializable

    Both, the HttpServer as well as the HttpClient respond to GetStats messages by replying with an instance of Stats.

  32. case class Timeout (method: HttpMethod, uri: String, protocol: HttpProtocol, headers: List[HttpHeader], remoteAddress: InetAddress, complete: (HttpResponse) ⇒ Unit) extends Product with Serializable

    When the service actor does not reply to a dispatched RequestContext within the time period configured as requestTimeout in the ServerConfig the HttpServer dispatches a Timeout instance to the timeout actor (as configured in the ServerConfig).

Value Members

  1. object BufferingRequestStreamActor extends AnyRef

  2. object ClientConfig extends Serializable

  3. object DateTime extends AnyRef

  4. val EmptyByteArray : Array[Byte]

    Definition Classes
    package
  5. object GetStats extends Product with Serializable

    Both, the HttpServer as well as the HttpClient respond to GetStats messages by replying with an instance of Stats.

  6. object HttpClient extends HighLevelHttpClient

  7. object HttpMethods extends AnyRef

    Module containing all defined HttpMethod instances.

  8. object HttpProtocols extends AnyRef

    Module containing all defined HttpProtocol instances.

  9. object HttpRequest extends Serializable

  10. object HttpResponse extends Serializable

  11. object HttpServer extends AnyRef

  12. object MessageChunk extends Serializable

  13. object MessageParserConfig extends Serializable

  14. object ServerConfig extends Serializable

  15. lazy val SprayCanVersion : String

    Definition Classes
    package
  16. object Trailer extends AnyRef

  17. def isTokenChar (c: Char): Boolean

    Definition Classes
    package
  18. def make [A, U] (a: A)(f: (A) ⇒ U): A

    Definition Classes
    package
  19. implicit def pimpByteArray (array: Array[Byte]): PimpedByteArray

    Attributes
    implicit
    Definition Classes
    package
  20. implicit def pimpLinearSeq [A] (seq: LinearSeq[A]): PimpedLinearSeq[A]

    Attributes
    implicit
    Definition Classes
    package