-
CREW, Caboto and RDF-Based Annotations
Posted on June 26th, 2008 No commentsI’ve been busy for the last few weeks preparing the CREW web application for the project’s support of 3rd ESRC Research Methods Festival in Oxford. A version of the CREW application is available to view that includes some data for the Oxford event.
A lot of the work involved preparing the 0.1 release of the annotations engine, Caboto. Why call it Caboto? In the Web Futures office at ILRT we can see Cabot’s Tower which is situated at the top of Brandon Hill, Bristol. John Cabot’s Italian name is Giovanni Caboto. Simple, eh?
Caboto is basically an RDF-based web annotations system designed to meet the uses cases of a number of project that members of the Web Futures team are working on. It will allow users of systems to annotate things such as events, papers, photos, people etc. The annotations might be comments and criticisms about a presentation, linking to a relevant paper or resource such as a photo or ranking an event out of 10 (or some other arbitrary number). The 0.1 release just supports simple comments but this will be extended in the next release.
Caboto has the concept of public and private annotations - a public annotation is available for all to see while private annotations are restricted to the author. The 0.1 release only supports public annotations. The annotations themselves are stored as RDF in a relational database.
Caboto uses a number of technologies:-
- The Jena Semantic Web Framework is used to handle the RDF querying and storage.
- Jersey, the JSR 311 reference implementation, is used to provide a RESTful interface for the annotations so they can be added, retrieved and deleted with POST, GET and DELETE HTTP methods.
- The Spring Application Framework is used to glue things together.
By using Jersey it is easy to make the URI of an annotaion a URL to access the RDF. For example, we could access the same data as RDF/XML, RDF/N3 or JSON:
curl -i -X GET -H accept:application/rdf+xml http://localhost:9090/caboto-web/person/user1/public/bcd6dbe7-fbd4-44a9-816e-57697720f2b9curl -i -X GET -H accept:text/rdf+n3 http://localhost:9090/caboto-web/person/user1/public/bcd6dbe7-fbd4-44a9-816e-57697720f2b9curl -i -X GET -H accept:application/json http://localhost:9090/caboto-web/person/user1/public/bcd6dbe7-fbd4-44a9-816e-57697720f2b9The Caboto site has instructions on downloading and running a sample version of Caboto, with examples on adding, querying and deleting annotations via the REST interface. Its still in the early stages so is a bit limited and subject to change in further releases.
Within CREW we have used it to allow people to make simple comments about the event.

The functionality in CREW will expand with developments in Caboto.
-
The case of the borked header field
Posted on March 7th, 2008 No commentsI’m currently looking at RESTful web services using Jersey. When testing a simple application with curl everything worked fine. However, when I tried a request in Firefox on my Mac Intel I received the following error message:
The HTTP header field "Accept" with value "HTTP Accept=text/xml,application/xml,application/xhtml+xml,text/html; q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5" could not be parsed."The header should be …
"text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5"… and not …
"HTTP Accept=text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5"This is the request captured with tcpdump:
........GET /JerseyTest/people/ HTTP/1.1 Host: localhost:9090 User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.12) Gecko/20080201 Firefox/2.0.0.12 Accept: HTTP Accept=text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5 Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip,deflate Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Keep-Alive: 300 Connection: keep-aliveA vanilla install of Firefox sends the correct header so either I have been fiddling with the configuration (I haven’t), or one of the plugins or extensions that I have installed is the culprit. If not, it must be gremlins. Fixed now, but for some reason went for a clean install of Firefox rather than editing the preferences in about:config
-
HelloWorld! - JSR-311, Jersey, Maven2 and the Jetty Plugin
Posted on March 6th, 2008 8 commentsI thought I’d record my notes on creating a trivial HelloWorld RESTful service using Jersey. I used an entry in Sud’s Blog as a starting point but hit some issues and deviated slightly, so I thought I’d note what I did here.
The impression that I got with my initial foray into Jersey is that life is a little bit easier if you use Netbeans and Glassfish. The code base I am developing for the CREW project uses Maven for the build and the Jetty plugin for deploying and testing the web application, so I’d like to stick with that setup. In addition, I’m currently an IntelliJ IDEA user and not ready for a switch to a new IDE.
-
Developing portlets with Spring
Posted on March 3rd, 2008 No commentsLast Thursday I attended the Portal Developers Workshop at the University of Reading. I gave a talk on developing Portlets with Spring.
A Flash version of the presentation is here:
-
Flex Presentation
Posted on December 13th, 2007 2 commentsI’ve just given a presentation on “Developing Rich Internet Applications with Flex 2″ as part of the ILRT staff development week. A Flash version if the presentation is here:


