Rebase of checksum work onto develop

This PR is a manual rebase of #788, #827 and #897 onto develop, sprinkled with a couple of extra commits accommodating the differences caused by FS work and a cherry-pick of two commits by @mtbc from #890.

The server builds fine and imports images ok. ``/build.py -f components/common/build.xml clean install test-compile integration`` doesn't fail. The Spring context wiring would need a second pair of eyes to look at (no startup errors though).