On Mon, May 19, 2008 at 7:17 PM, Blaine Cook <[EMAIL PROTECTED]> wrote:
> I'm a big fan of pubsub nodes that
> correspond to functioning URLs, e.g.,

Yes. It is often quite appropriate to provide a simple mapping from URL to
pubsub node. However, it should be recognized that doing so isn't always the
right thing to do. Some edge case examples:

   - Early or fixed binding between a node id and a query URL makes a mess
   if you ever need to change the query. For instance, I might want to expose a
   stream of results on "Britney Spears". Initially, I might create a query
   like "Britney Spears" but later realize that I should have used ["Britney
   Spears" OR "Britney Speers"]... In this case, a "late binding" between
   node-id and query would make life easier for subscribers who may have
   difficulty detecting the change and switching to the new node.
   - Exposing the query might not be the right thing to do. Sometimes, the
   search query itself might represent some "intellectual property" that I'm
   not willing to disclose to the net. You can have the results of my search,
   but I might not want you to see my query...
   - Some queries may very long and thus cumbersome to deal with. This is
   particularly a concern with mobile devices that have limited bandwidth.

i.e. Keep it simple if you can, but don't make it simpler than it is...

bob wyman

On Mon, May 19, 2008 at 7:17 PM, Blaine Cook <[EMAIL PROTECTED]> wrote:

> I'm a big fan of pubsub nodes that correspond to functioning URLs, e.g.,
>
> if your blog has a view:
>
> http://zemarmot.net/jehan/blog/posts?categories=Jabber,Linux;tag=en
>
> that shows only Jabber or Linux posts in English, then the
> corresponding pubsub node would be (wait for it!):
>
> http://zemarmot.net/jehan/blog/posts?categories=Jabber,Linux;tag=en
>
> (i.e., they're the same). I think it's informative that HTTP doesn't
> have a formalized syntax for specifying query parameters beyond the
> URL string (POST bodies are a different matter, but the *vast*
> majority of use is identical to normal query string parameters).
>
> b.
>
> On Mon, May 19, 2008 at 2:35 PM, Bob Wyman <[EMAIL PROTECTED]> wrote:
> > On Mon, May 19, 2008 at 5:25 AM, Jehan wrote:
> >> I was thinking about a real estate website where I
> >> subscribe to receive emails when they got a
> >> garage close to my apartment and under
> >> a given price.
> > If you were using XEP-0060 wouldn't you just do this by adding something
> > like a "query-string" field to the node configuration form? See possible
> > stanza below:
> >
> > <iq type="set" to="xmpp.example.com" id="sub1">
> >   <pubsub xmlns="http://jabber.org/protocol/pubsub";>
> >     <subscribe
> >         node="real-estate"
> >         jid="[EMAIL PROTECTED]">
> >     <options>
> >       <x xmlns="jabber:x:data" type="submit">
> >         <field var="FORM_TYPE" type="hidden">
> >           <value>http://jabber.org/protocol/pubsub#subscribe_options
> </value>
> >         </field>
> >         <field var="title">
> >           <value>Possible Garage</value>
> >         </field>
> >         <field var="query-string">
> >           <value><![CDATA[ (price .lt. $500) & (size .eq.
> large)]></value>
> >         </field>
> >       </x>
> >       </options>
> >     </subscribe>
> >   </pubsub>
> > </iq>
> >
> > bob wyman
> >
> > On Mon, May 19, 2008 at 5:25 AM, JabberForum <
> [EMAIL PROTECTED]>
> > wrote:
> >>
> >> I think this kind of feature has already been discussed mixed with other
> >> topics. But I wanted to discuss it here.
> >>
> >> Currently you can configure your subscription (theoritically in the XEP
> >> at least) very basically. Like "I want to receive the whole items,
> >> nothing, the whole body or only an excerpt, etc.). But if you want to
> >> have advanced configuration, you could "play" with subnodes, but this is
> >> very limited. A tag and category system would be advantageous.
> >>
> >> Let me give the examples I was dealing with when I thought about this
> >> all. First a blog with pubsub as I am writing a Wordpress plugin:
> >> currently my plugin enables only to subscribe to all the posts, or all
> >> the comments, or the comments of a given post (or absolutely everything
> >> of course). For this, I made a global container node (let's call it G).
> >> In this one, I have 2 subnodes:
> >> - a leaf node with all the posts (P);
> >> - a container node for comments (C), with inside leaf nodes for each
> >> posts (P1, P2, etc.).
> >>
> >> So if I want to subscribe to everything, I subscribe to G, G/P for only
> >> posts, G/C for all comments, and for instance G/C/P3 for all comments of
> >> post 3 (these are not really the node names I chose of course).
> >>
> >> Imagine you want to provide a way to subscribe only to some categories.
> >> For instance I like the blog posts of a guy about philosophy, but I
> >> don't care when he speaks about nuclear physics because I don't
> >> understand at all what he writes. Of course you could "emulate"
> >> categories with subnodes once again; but then when a post belongs to
> >> several categories, it will be copied to several nodes (and when
> >> modified, don't forget to sync all "copies"); moreover if you subscribe
> >> to both categories, you will receive the same publication several
> >> times.
> >> So the (or at least one) solution would be that all posts are in the
> >> same nodes, but they can be categorized. So a subscriber subscribes to
> >> the P node, then configure which categories interest him. And then the
> >> "decision" to notify a subscriber will be done at server side. Each time
> >> a new publication is done, the server will send it to any person whose
> >> configuration agrees.
> >>
> >> This can be done with categories, with tags, but also with authors (on
> >> multi-author blogs), etc. In fact the better system would allow
> >> flexibility.
> >>
> >> You will do such configuration through your Jabber client, but also my
> >> blog can generate such link:
> >>
> >> xmpp:
> pubsub.zemarmot.net?action=subscribe;node=home/zemarmot.net/jehan/blog/posts;categories=Jabber,Linux;tag=en
> >>
> >> If I click this link, my Jabber client will propose me to subscribe to
> >> the given node and configure it to receive only posts categorized under
> >> "Jabber" and "Linux", and tagged as "en" (because I would not speak any
> >> other language).
> >>
> >> Another instance: I was thinking about a real estate website where I
> >> subscribe to receive emails when they got a garage close to my
> >> appartment and under a given price. Why couldn't such configuration be
> >> available on a pubsub node which contains items to sell. And you
> >> configure your subscription to be notified only about items which
> >> interest you (under some price for instance, and in some category).
> >>
> >> What do you think of it?
> >>
> >>
> >> --
> >> Jehan
> >> ------------------------------------------------------------------------
> >> Jehan's Profile: http://www.jabberforum.org/member.php?userid=16911
> >> View this thread: http://www.jabberforum.org/showthread.php?t=95
> >>
> >
> >
>

Reply via email to