w3c-social / Social-APIs-Brainstorming

7 stars 2 forks source link

subscriptions: fully functioning via Pull, and Push just an additional optimization #7

Open elf-pavlik opened 9 years ago

elf-pavlik commented 9 years ago

I would like to propose that all explicit subscriptions need to work with Pull and Push only acts as optimization. This way subscribing party can always get updates without need to implement notification endpoint, for public content subscribing party can also choose to stay anonymous and not announce subscribing to the party acting as publisher.

This would also allow @tantek and @evanp to test basic interoperability as soon as they both can publish compatible feeds/streams and subscribe to each other via pull, as I suggested in https://github.com/w3c-social/social-web/issues/1

This doesn't include mentions like interaction, since mentioned party doesn't need to stay subscribed to all the parties acting as publisher of content which includes mentions.

aaronpk commented 9 years ago

I agree with this, since this is how we've grown organically with the indieweb development. It's only been recently that we've seen a bunch of people start to publish and consume PubSubHubbub to make everything more realtime. This also provides a natural progression so that the spec isn't as overwhelming to implement. You can start by publishing data, and separately, enable push for realtime delivery.

akuckartz commented 9 years ago

:+1:

I like the incremental approach. And the Push aspect seems to be significally more difficult to specify.

elf-pavlik commented 9 years ago

@aaronpk I just took a look at IRC log which you publish

I find in it's rels: pingback and webmention but no hub or something like Updates-Via (proposed in SoLiD). The last I suggested to implement with link relation instead of HTTP header https://github.com/linkeddata/SoLiD/issues/10 & https://github.com/linkeddata/SoLiD/issues/11 @melvincarvalho

In your IRC log I already find live updates subscription

// Streaming logs
  var pushstream = new PushStream({
    host: window.location.hostname,
    port: 443,
    useSSL: true,
    modes: "eventsource",
    urlPrefixEventsource: "/irc-streaming/sub",
    channelsByArgument: true,
    channelsArgument: "id"
  });

Maybe we could have single link relation for updates used to point to multiple endpoint: SSE (direct read-only), WebSockets (direct read-write), PubSubHubBub (indirect read-only) etc.

seeAlso: Social WG ACTION-60: Draw Follow vs. Subscribe with account having multiple feeds allowing subscription independently