Hey Daniel,
You have some good points. I also think moving slowly and not forcing
standards is a good idea *but* I think it is important to get groups
of people rallying behind different sets of standards. Some of us
working towards a REST standard and perhaps others towards an envelope
standard etc. There are a lot of developers out there that don't want
to re-invent the wheel, they have enough on their plates without
having to create a custom WebHooks implementation. They would rather
see some guideliness and then say "well, that doesn't quite work so
I'll tweak this or that." I think in the end we get more adoption and
better insight because the "best practices" are out in the open for
people to see, criticize and rework. If we have this "open"
hodgepodge, there will be 20 organizations making all the same
mistakes instead of learning from each other and advancing.
Regarding your envelope comments, I think a universal enveloped
payload is still unnecessary even in your example. The reality is that
if I am going to send a text message, IM, etc. I have to change
networks/protocols anyway, I must have some sort of "adapter" to send
a message from HTTP to SMS. Furthermore, if I send my message in a
envelope the target network either has to understand my native
envelope or transform it at which point the envelope is moot. I would
rather see a REST approach where we have adapters that convert a
RESTful HTTP message to an envelope'less SMS message at the same time
moving it onto the target network. Why wrap stuff up in envelopes? Are
there a bunch of different envelopes for SMS (I hope not otherwise
that hurts my point)? If there are not several SMS envelopes then why
wrap-up HTTP in envelopes? To give you an example I am currently
prepping for a project that requires adapters to Quickbooks and other
supply chain tools. I plan to expose RESTful (true REST not REST-RPC
hybrid) services and WebHooks from the core web app. I then plan to
write the adapters as RESTful+WebHooked services. When a sales order
is added to my system the web based Quickbooks adapter is notified
through its WebHooks subscription. This notification gets added to a
queue of notifications that Quickbooks (a desktop adapter) will poll
for updates. Any time Quickbooks changes, the notification will be
posted to my Quickbooks adapter which will publish a WebHooks event
that my core system has subscribed to (this has an added benefit in
that I could allow others to subscribe directly to my web based QB
adapter thereby expanding my sales universe). I can envision the rest
of the web working in this way. I publish a WebHooks event that an SMS
adapter has subscribed to, it sends the text message using native
protocols (no envelopes); my target texts me back, the SMS adapter
publishes a WebHooks message that I subscribe to. Lets be honest about
what our protocol is/supports and use adapters to move those messages
to other protocols instead of creating yet another xml envelope
standard.
My ten cents and then some :)
Nathan
On Oct 4, 8:58 pm, Daniel Parker <
dcpar...@gmail.com> wrote:
> First of all, I guess I'm glad of the interest. I mean, if several of you
> are interested in talking about standardizing *something*, then that's
> great. We do have to be focused on what that very specific *something* is,
> and make sure that the specific focus is communicated loud and clear.
> I've conceded to Jeff's advice in the past to move slowly in the area of
> standards, giving things time to sort-of grow on their own, time to be tried
> and tested, new people to find and comment on things as they grow, etc.
>
> In any case, here are my replies to a couple things that were brought up
> here:
>
> HTTP Headers vs. "light envelope" model.
> I personally like HTTP Headers better --- for HTTP. When I wrote up that
> spec (it was a while ago) I had settled on the light envelope model. I won't
> claim that my conclusions are the "right" way, but ... if I remember
> correctly, this was my thought process: The standard I was working on
> writing was actually all about the big idea of push subscription as a whole,
> and that encompasses several different medium: HTTP, XMPP, SMTP, SMS and
> more. This in itself necessitates that if a single spec can span the various
> mediums, the payload itself must contain the meta-data related to the
> *subscription
> content delivered*, while the regular medium-specific meta-data should only
> carry data regarding the *transmission* of that content. This also makes it
> easy and simple to relay subscription content from one medium to another
> without the need to understand and translate headers or other meta-data.
>
> Illustration: Using HTTP Headers in this case might be like putting the
> newspaper's date on the bag it came in instead of on the actual paper. This
> makes sense for most types of delivery, but not for newspapers. The content
> makes the difference.
>
> The same reasons hold for base64-encoding it. Encoding it may easily look
> silly and extraneous even to me, but it solves the problem of XMPP clients
> that could be confused by badly-formed XML that *could* be in the payload
> > > >> Jeff Lindsayhttp://webhooks.org--Makethe web more programmablehttp://
> >
shdh.org