Skip to content

Commit 184f9bb

Browse files
JanPretzelstephenplusplus
authored andcommitted
docs: messages published as JSON (#2212)
1 parent cd41c31 commit 184f9bb

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

packages/pubsub/src/topic.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,9 @@ Topic.prototype.getSubscriptionsStream = function(options) {
369369
* box your message in to an object with a `data` and `attributes` property.
370370
* `data` will be the raw message value you want to publish, and
371371
* `attributes` is a key/value pair of attributes to apply to the message.
372+
* All messages not provided as `Buffer` will be published in JSON format.
373+
* If your receiving end uses another library, make sure it parses the
374+
* message properly.
372375
* @param {object=} options - Configuration object.
373376
* @param {boolean} options.raw - Enable if you require setting attributes on
374377
* your messages.

0 commit comments

Comments
 (0)