@smartcloud/pubsub-listener

0.0.7 • Public • Published

@smartcloud/pubsub-listener

Pubsub listener Module of SmartCloud Utility Library for Node.js

npm installation

$ npm install --save @smartcloud/pubsub-listener

Initialization

The module has core class named "PubsubListener". To initialize an PubsubListener object, pass the follow parameters.

* trigger - (required) target pubsub name.

* listenerName - (required) listener process name

* targets - (required) listener's targets

* filter - (optional) filters

Sample usage

const SmartCloudPubsubListener = require('@smartcloud/pubsub-listener');

var listener = new SmartCloudPubsubListener.PubsubListener();

Methods

  • getMessage(event) method - Return message details (event id, attributes, and message) based on pubsub event passed.

/@smartcloud/pubsub-listener/

    Package Sidebar

    Install

    npm i @smartcloud/pubsub-listener

    Weekly Downloads

    4

    Version

    0.0.7

    License

    Apache-2.0

    Last publish

    Collaborators

    • spt-arif
    • jacrowland1
    • spt-edison
    • alexkozlov
    • deanscratcherd
    • kin.chan
    • mib1085
    • connorsage