Upgrade to java7
Reworked to be better at try finally
comment in dbspec