Initial SQLITE refactor.
Add checkpointing ability.
Add periodic checkpointing.
Add checkpoint on signal handler.
Put single CPU check in the right place.
Add some documentation for the checkpointing options.