Options
All
  • Public
  • Public/Protected
  • All
Menu

  subscribe now with sterfive to access the online-user manual

a Publish Engine for a given session

Hierarchy

  • EventEmitter
    • ServerSidePublishEngine

Implements

  • IServerSidePublishEngine

Index

Constructors

constructor

Properties

isSessionClosed

isSessionClosed: boolean

maxPublishRequestInQueue

maxPublishRequestInQueue: number

Readonly Static captureRejectionSymbol

captureRejectionSymbol: typeof captureRejectionSymbol

Static captureRejections

captureRejections: boolean

Sets or gets the default captureRejection value for all emitters.

Static defaultMaxListeners

defaultMaxListeners: number

Readonly Static errorMonitor

errorMonitor: typeof errorMonitor

This symbol shall be used to install a listener for only monitoring 'error' events. Listeners installed using this symbol are called before the regular 'error' listeners are called.

Installing a listener using this symbol does not change the behavior once an 'error' event is emitted, therefore the process will still crash if no regular 'error' listener is installed.

Static registry

registry: ObjectRegistry

Accessors

currentMonitoredItemCount

  • get currentMonitoredItemCount(): number
  • Returns number

hasLateSubscriptions

  • get hasLateSubscriptions(): boolean
  • Returns boolean

pendingClosedSubscriptionCount

  • get pendingClosedSubscriptionCount(): number
  • Returns number

pendingPublishRequestCount

  • get pendingPublishRequestCount(): number
  • number of pending PublishRequest available in queue

    Returns number

subscriptionCount

  • get subscriptionCount(): number
  • number of subscriptions

    Returns number

subscriptions

  • get a array of subscription handled by the publish engine.

    Returns Subscription[]

Methods

_on_tick

  • _on_tick(): void
  • Returns void

_purge_dangling_subscription

  • _purge_dangling_subscription(subscriptionId: number): void
  • Parameters

    • subscriptionId: number

    Returns void

_send_response

  • Parameters

    Returns void

_send_response_for_request

  • _send_response_for_request(publishData: PublishData, response: PublishResponse): void
  • Parameters

    Returns void

addListener

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

add_subscription

  • Parameters

    Returns Subscription

cancelPendingPublishRequestBeforeChannelChange

  • cancelPendingPublishRequestBeforeChannelChange(): void
  • Returns void

detach_subscription

  • Parameters

    Returns Subscription

dispose

  • dispose(): void
  • Returns void

emit

  • emit(event: string | symbol, ...args: any[]): boolean
  • Parameters

    • event: string | symbol
    • Rest ...args: any[]

    Returns boolean

eventNames

  • eventNames(): (string | symbol)[]
  • Returns (string | symbol)[]

findLateSubscriptions

  • Returns Subscription[]

findLateSubscriptionsSortedByAge

  • Returns Subscription[]

getMaxListeners

  • getMaxListeners(): number
  • Returns number

getSubscriptionById

  • getSubscriptionById(subscriptionId: string | number): Subscription
  • retrieve a subscription by id.

    Parameters

    • subscriptionId: string | number

    Returns Subscription

    Subscription

listenerCount

  • listenerCount(event: string | symbol): number
  • Parameters

    • event: string | symbol

    Returns number

listeners

  • listeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

off

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

on

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

onSessionClose

  • onSessionClose(): void
  • Returns void

on_close_subscription

  • on_close_subscription(subscription: IClosedOrTransferredSubscription): void
  • Parameters

    • subscription: IClosedOrTransferredSubscription

    Returns void

once

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

prependListener

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

prependOnceListener

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

process_subscriptionAcknowledgements

rawListeners

  • rawListeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

removeAllListeners

  • Parameters

    • Optional event: string | symbol

    Returns ServerSidePublishEngine

removeListener

  • Parameters

    • event: string | symbol
    • listener: (...args: any[]) => void
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns ServerSidePublishEngine

send_keep_alive_response

  • send_keep_alive_response(subscriptionId: number, future_sequence_number: number): boolean
  • call by a subscription when no notification message is available after the keep alive delay has expired.

    method

    send_keep_alive_response

    Parameters

    • subscriptionId: number
    • future_sequence_number: number

    Returns boolean

    true if a publish response has been sent

setMaxListeners

shutdown

  • shutdown(): void
  • Returns void

Static listenerCount

  • listenerCount(emitter: EventEmitter, event: string | symbol): number
  • deprecated

    since v4.0.0

    Parameters

    • emitter: EventEmitter
    • event: string | symbol

    Returns number

Static on

  • on(emitter: EventEmitter, event: string): AsyncIterableIterator<any>
  • Parameters

    • emitter: EventEmitter
    • event: string

    Returns AsyncIterableIterator<any>

Static once

  • once(emitter: NodeEventTarget, event: string | symbol): Promise<any[]>
  • once(emitter: DOMEventTarget, event: string): Promise<any[]>
  • Parameters

    • emitter: NodeEventTarget
    • event: string | symbol

    Returns Promise<any[]>

  • Parameters

    • emitter: DOMEventTarget
    • event: string

    Returns Promise<any[]>

Generated using TypeDoc