Class ActorHttpAbstract

A base actor for listening to HTTP events.

Actor types:

  • Input: IActionHttp: The HTTP request.
  • Test: IActorHttpTest: An estimate for the response time.
  • Output: IActorHttpOutput: The HTTP response.

See

  • IActionHttp
  • IActorHttpTest
  • IActorHttpOutput

Hierarchy (view full)

Constructors

Properties

Actor that must be registered in the bus before this actor.

The bus this actor subscribes to.

name: string

The name for this actor.

Default

{<rdf:subject>}

Methods

  • Deinitialize this actor. This should be used for cleaning up things when the application is shut down, such as closing files and removing temporary files.

    Returns Promise<any>

    A promise that resolves when the actor has been deinitialized.

  • Initialize this actor. This should be used for doing things that take a while, such as opening files.

    Returns Promise<any>

    A promise that resolves when the actor has been initialized.

  • Convert the given headers object into a raw hash.

    Parameters

    • headers: Headers

      A headers object.

    Returns Record<string, string>

  • Converts WhatWG streams to Node streams if required. Returns the input in case the stream already is a Node stream.

    Parameters

    • body: null | ReadableStream<any>

    Returns ReadableStream

    A node stream.

  • Converts Node streams to WhatWG streams.

    Parameters

    • body: null | ReadableStream

    Returns ReadableStream<any>

    A web stream.

Generated using TypeDoc