minor cleanups to persistence code
added simple wrapper over ets and dets