Monday 23 June 2008

Are people blogging less?

Maybe its a bug with google reader or something but for the first time in ages my great and good folders of feeds I track (my kinda 2 tier way of keeping on top of blogs) are nearly empty. Do folks just twitter now or something?

Tuesday 3 June 2008

TimeCapsule & TimeMachine saved my ass!

My MacBookPro died on me. It kinda kept freezing so I did a hard reboot then after that it wouldn't boot at all :) Took it to the Apple Store; they figured out it was some kinda disc corruption; so wiped the disk (after managing to restore the files I was hacking on, bless that genius at the bar), reinstalled Leopard and things are OK (the disk may be faulty, we'll see soon).

Luckily the TimeCapsule had all my stuff so I could use the Migration Assistant to restore my apps & user accounts from the backup on the Time Machine. The UI did freak me out a bit - when the thing started it kept saying 'connecting...' then hanging for ages. I kept thinking it wasn't working so trying all kinds of things. Turns out, its just wacky slow. The next screen shows the list of user accounts - again thats wacky slow - takes maybe an hour for a 100Gb backup to show the few user accounts in the backup!

The 2 massive delays in the UI are kinda irritating; I mean why can't it keep a little index of what machines & users its got in the backup and let me pick 'em in a second then leave the thing for a few hours while it restores?

Anyway - all is well - once I got past the 2nd screen, chose the things to restore I left it chugging away for a few hours and I'm now restored. The only thing I've missed so far is I had to reinstall my VPN client as it shoved stuff in /System and maven is hardwired in /usr/bin to point to mvn 2.0.6 in /usr/share - other than that it worked fine.

One final tip if you try and restore from Time Capsule/Time Machine; when you reinstall Leopard don't create a user account with the same ID as the one you are gonna restore - as the Migration Assistant forced me to rename the restored one (which caused some problems that took me a little while and some 'chown'ing to fix :).

Other than those little gremlins; nice job Apple! If I ever have another catastrophic failure, the next restore should be pretty painless

I'm liking JAX-RS and Jersey

A great post by Paul Sandoz on MVCJ. Jersey rocks!

I'm loving the simple JAX-RS POJO based programming model (quite Rails-ish) for writing controllers and models which work beautifully in a hi-RESTful way which also now support a rails-like way of implicit templates via JSP/Velocity/whatever with a minimal amount of fuss.

I'm liking the controller-is-the-model-facade option with implicit MVC too; so the model is totally decoupled from the web and the controller just has a few annotations to deal with binding methods nicely to the URI/REST/content types and so forth - then you can have as many representations of a model as you want - just write views (e.g. index.jsp, detail.jsp, brief.jsp or whatever). Lovely and Rails-ish

Its now pretty easy to write hi-rest web apps in Java which render content as (X)HTML, XML, JSON with nice RESTful content negotiation and using good URIs.