keymetrics / pm2-io-js-api

PM2.io API Client for Javascript
http://docs.api.cloud.pm2.io/index.html
Apache License 2.0
28 stars 13 forks source link

issue: cannot subscribe in realtime to multiple bucket? #38

Closed Unitech closed 6 years ago

Unitech commented 6 years ago

The only way currently is to instantiate multiple kmjs core?

Currently I cannot do that:

const bucket_id_1 = '543970ae931fb40357ed3a5e'
const bucket_id_2 = '58c536dd35034ec15f8fe923'

var rt1 = km.realtime.subscribe(bucket_id_1).catch(console.error)
var rt1 = km.realtime.subscribe(bucket_id_2).catch(console.error)       
vmarchaud commented 6 years ago

See example : https://github.com/keymetrics/kmjs-core/blob/master/examples/standalone_get_user.js#L21