Friday, August 27, 2004

More on queues versus resources

Mark Baker writes:

    Whenever I want to do the queue thing, I use two resources; the
    "business resource", and "the inbound message queue for that business
    resource" (though of course, as a separate resource, it need not be
    used only for the business resource). I then subscribe the business
    resource to the queue, such that messages POSTed to the queue also are
    forwarded to the business resource. FWIW, I've been using mod_pubsub
    recently to manage the queue resource (as a topic maintained by its
    router) in some work I'm doing on the side.

But doesn't this create tight temporal coupling between the POSTs and the business resource?

It strikes me that this scheme essentially achieves a "Got your message, I'm dealing with it right now. Please stay here in reception until I get your answer for you."?

I really value temporal decoupling. No implied correspondence between asking to modify a business resource and the business resource itself. What I'm after is:

"Got your message. Thanks. I can assure you that it will be taken care of by the Business Resource in due course. You can safely go about your business now, here is a tracking URI. If you need to know what the state of things are, just call GET."

No comments: