问题
We're building an application in which user can upload lists of pages, can leave notes on those pages, and people can discuss these notes. A user may choose to get notified for all replies on all notes on a page, which could all be separate activity streams. Or for all discussions on all pages in a list of pages (which can be many.)
Would it be possible to let a list follow all its pages, and a page all its notes, so that a user can follow a page or a list and receive all the relevant updates?
回答1:
That's possible.
However, follow relationship gets activities from direct connections. For hierarchy, to
targeting should be used.
When an activity is added to a note, it will be captured by the page since page follows it and if project follows pages, it won't get the activity but while adding an activity to a note you can add project as notified too.
Change is minimal, add to
key to activity payload with feeds you want to copy it:
{
verb: 'comment',
...
to: ['project:mine']
}
来源:https://stackoverflow.com/questions/64496847/are-stream-hierarchies-possible-in-getstreams-io