-
Notifications
You must be signed in to change notification settings - Fork 46
[DX-955] Add use-case based SDK references across Pub/Sub pages #3340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
ccd2749
d69806d
7968194
e680f21
28eec20
531980e
7ea1666
1a27dd4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -933,7 +933,7 @@ You should be aware of the following limitations: | |
|
|
||
| ## Mapping of message reactions to annotations <a id="mapping-annotations"/> | ||
|
|
||
| Chat message reactions are powered by the PubSub annotations feature. Chat uses the `reaction:` prefix for annotation types. Here is the mapping from message reaction types to annotation types: | ||
| Chat message reactions are powered by the [Pub/Sub annotations](/docs/messages/annotations) feature. Chat uses the `reaction:` prefix for annotation types. Here is the mapping from message reaction types to annotation types: | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think this is necessary - someone wouldn't need to read the Pub/Sub docs to understand annotations for Chat. |
||
|
|
||
| | Reaction type | Annotation type | | ||
| | ------------- | --------------- | | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -7,6 +7,12 @@ meta_description: "Annotate messages on a channel with additional metadata." | |||||
| Message annotations are currently in Public Preview. That means that we are committed to supporting it and expect the API to be stable unless we discover a significant issue, but it may not yet be implemented in all of our SDKs, and there may be other minor shortcomings. | ||||||
| </Aside> | ||||||
|
|
||||||
| <Aside data-type='note'> | ||||||
| For chat applications, the [Chat SDK](/docs/chat) provides dedicated APIs for [message reactions](/docs/chat/rooms/message-reactions), [read receipts](/docs/chat/rooms/read-receipts), and [moderation](/docs/chat/moderation). Message annotations are intended for adding metadata to Pub/Sub messages outside of chat contexts. See [product guidance](/docs/platform/products) for a full comparison. | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Trim "intended for adding metadata to Pub/Sub messages outside of chat contexts" —
Suggested change
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Keeping the original wording. "Message annotations are intended for adding metadata to Pub/Sub messages outside of chat contexts" frames the use case more explicitly than the imperative "Use message annotations to attach metadata...". The descriptive form makes it clearer to readers comparing options when annotations are the right tool.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not in favor using
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As above: I don't think we should be trying to 'sell' Chat on this page. If you're looking at Chat docs then you have an annotations section there. |
||||||
| </Aside> | ||||||
|
|
||||||
| <a id="interactions"/> | ||||||
|
|
||||||
| Message annotations enable clients to append information to existing messages on a channel. You can use annotations to implement features like: | ||||||
|
|
||||||
| * **Message reactions** - add emoji reactions (👍, ❤️, 😂) to messages | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -7,6 +7,10 @@ meta_description: "Update and delete messages published to a channel, and retrie | |||||
| Message updates and deletes are currently in Public Preview. That means that we are committed to supporting it and expect the API to be stable unless we discover a significant issue, but it may not yet be implemented in all of our SDKs, and there may be other minor shortcomings. | ||||||
| </Aside> | ||||||
|
|
||||||
| <Aside data-type='note'> | ||||||
| For chat applications, the [Chat SDK](/docs/chat) provides purpose-built APIs for [message editing](/docs/chat/rooms/messages#update) and [moderation](/docs/chat/moderation). Message updates and deletes are intended for Pub/Sub messages outside of chat contexts. | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same
Suggested change
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Keeping the original wording for the same reason as the equivalent comment on
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here. |
||||||
| </Aside> | ||||||
|
|
||||||
| You can update and delete messages that have been published to a channel, for use cases such as: | ||||||
|
|
||||||
| * **Message editing** - allow users to edit their messages in chat-like applications | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,4 +13,8 @@ Presence is a feature that tracks the membership of a presence set for a channel | |
|
|
||
| Occupancy provides metrics for a channel. It is a feature that counts how many of a thing are attached to a channel, such as the number of connections. It does not provide any information that can identify individual connections or clients attached to the channel. | ||
|
|
||
| Take a chat application containing multiple chat rooms as an example. Occupancy would be a more lightweight method for displaying the popularity of rooms, by displaying the number of connections to each channel. Presence could be utilized in each channel to indicate which users are online, and to notify other members when someone leaves the room. | ||
| Take a [chat application](/docs/chat) containing multiple chat rooms as an example. Occupancy would be a more lightweight method for displaying the popularity of rooms, by displaying the number of connections to each channel. Presence could be used in each channel to indicate which users are online, and to notify other members when someone leaves the room. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this should probably use a different example use case for presence rather than linking out to Chat. |
||
|
|
||
| <Aside data-type='note'> | ||
| For chat applications, the [Chat SDK](/docs/chat) provides built-in [presence](/docs/chat/rooms/presence) and [occupancy](/docs/chat/rooms/occupancy) features. The example below illustrates how these primitives work at the Pub/Sub level. See [product guidance](/docs/platform/products) for a full comparison. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here. |
||
| </Aside> | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure about this one.