Options
All
  • Public
  • Public/Protected
  • All
Menu

AmqpBroker implements MessageBroker using the RabbitMQ message broker. Messages are, by default, durable, and will survive a broker restart.

Hierarchy

  • AmqpBroker

Implements

Index

Constructors

Methods

Constructors

constructor

  • Constructs an AmqpBroker with the given options.

    Parameters

    • Optional options: AmqpOptions

      The configuration of the connection to make. If undefined, will connect to RabbitMQ at localhost:6379.

    Returns AmqpBroker

    An AmqpBroker connected using the specified configuration.

Methods

disconnect

  • disconnect(): Promise<void>
  • Disconnects from the RabbitMQ node. Only call once. Alias for #end().

    see

    #end

    Returns Promise<void>

    A Promise that resolves once the connection is closed.

end

  • end(): Promise<void>
  • Disconnects from the RabbitMQ node. Only call once.

    Returns Promise<void>

    A Promise that resolves once the connection is closed.

publish

  • Queues a message onto the requested exchange.

    Parameters

    • message: TaskMessage

      The message to be published. Used to determine the publishing options.

    Returns Promise<string>

    A Promise that resolves to "flushed to write buffer".

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc