commit | 891c2687abdb9f276f4198ff1c92a577a1880088 | [log] [tgz] |
---|---|---|
author | Idan Amit <ia096e@intl.att.com> | Wed Sep 12 11:35:12 2018 +0300 |
committer | Idan Amit <ia096e@intl.att.com> | Wed Sep 12 11:35:12 2018 +0300 |
tree | 7e86db3f703c79a42a6f0943b012575846387b9c | |
parent | dc5da2d5d61bd20051ee8b5bffa23773ee7d44f3 [diff] |
update group id in pom.xml Updated the group id in the pom.xml from openecomp to onap Change-Id: Ia0b181d38c14a4ab59cefa9c83a55171ccb56613 Issue-ID: SDC-1753 Signed-off-by: Idan Amit <ia096e@intl.att.com>
sdc-pubsub npm package.
Installing using npm:
npm install sdc-pubsub
import {PluginPubSub} from 'sdc-pubsub'
<!-- index.html --> <script src="./node_Modules/sdc-pubsub/dist/sdc-pubsub.js"></script>
// script.js var pubsub = window.sdcPubSub.PluginPubSub;
// eventsClientId = client id to be used by the event bus, received from query params // parentUrl = event bus location url for communication, received from query params // eventsToWaitFor = list of events names that the event hub should wait for their completion. // the client should send an "ACTION_COMPLETED" event to the hub in order to notify the event hub to continue with the flow. // For example: [ “CHECK_IN” ] var client = new PluginPubSub('eventsClientId, parentUrl, eventsToWaitFor')
client.notify(“READY”)
// When lisetning to event we have to specify the specific event we want to act once it being received. // eventData.type will hold the event name that was notified by someone else client.on((eventData,event) => { if(eventData.type == ”WINDOW_OUT”) { //do logic } } )
None.
None.
Copyright 2018 AT&T, Inc.
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0