This is no longer active or running. If you think it's a good idea just email me and I'll run it again, or send you the code, or both.

Observer Web Service

This is a Web programmer service. This is not for end users.

This is documentation for an appoximation of the observer pattern as a Web service. It shows the problem I wanted to solve, the solution, and how you can use it.

Documentation

News

Problem

I was playing around with storing FOAF. An issue I have with existing FOAF front-ends is that you have to ping it when you change your FOAF. The only other solution is for them to poll your FOAF file. It'd be great if, whenever your FOAF changed, anything that depended on it were automaticaly pinged.

Solution

So I cracked open my worn copy of GoF, re-read the details of the observer pattern, and got to work. Here's a run-down of how it works:

  1. The observer Web service polls the subject URL with a HEAD request and stores the subject's last-modified timestamp.
  2. When the last-modified timestamp is changed it sends a ping to all dependant URLs.

As you can see there is still polling. However I'm the only one polling; other services wait patiently for a ping from me telling them of the update.

FOAF Mike Burns <mike@mike-burns.com> <mikeburns@myjabber.net>