Add missing includes and tidy up
Clean up and restructure sources
Remove unused macros, config variables, and file
[WIP] Add 'visitNodes' function and implement 'visitLeaves' with it
(this specific commit was David Schwartz. All subsequent Mark Travis)

Add config sections for rotate-delete:
[rotate_delete] #: number of ledgers in between rotation intervals
[keep_ledgers] #: number of recent ledgers to keep when deleting
[advisory_delete] 0|1: if enabled, require rpc call (not yet implemented)
to indicate the latest allowable ledger to delete

add RotateDelete class

launch RotateDelete thread

In RotateDelete, recover database and rotation state from shutdown or crash,
clean old database directories, start new backend if no previous database

Remove rocksdb contents and directory in destructor.

function to copy rotate of ledger from previous to current backend

some logic in rotation loop

WIP need cross-platform way to open file for writing to get file descriptor
for fsync()

write dbstate, rotation logic

Database::copyToCurrent(). Broken, need to modify fetchInternal() next.

WIP DatabaseImpl::fetchInternalRotateDelete()

database functions work with rotate-delete (fetch, store)

no batch writes for rotate delete in RocksDB

log RocksDB errors

rpc command "can_delete" used with ADVISORY_DELETE to let user allow
the earliest ledger to delete

remove [keep_ledgers] config, use [ledger_history] instead

don't start if [rotate_delete] is set and [ledger_history] is full

write dbStateFile for non-POSIX platforms. Does not write synchronously.

formatting cleanup

setup SQLite to persist rotate db state

can_delete RPC uses SQLite to set/get deletable ledger

[WIP] functions added to RotateDelete to replace monolithic functor

uncomment copyToCurrent

modularize RotateDelete::operator()() components

remove unused code

debug RotateDelete

Add config options to example config. Add log entries for RotateDelete.
modify log message.node.getString() changed recently
fix CREATE TABLE so all 5 columns are created
no need for <memory> header
clarify comment
fix SQL and add debugging messages
create [node_db] path if it doesn't exist for [rotate_delete]
fix SQL and return from cleanDbs if the path doesn't exist
remove logging entries
remove trailing whitespace
default journal mode for rotate.db and remove duplicate semi-colon
fetch currentdb before previous
remove gratuitous ;
keeping 2 backends at all times for rotation
non-portable, debugging only print memory usage looking for leak
WIP troubleshooting unbounded memory growth in rotation process
troubleshooting unbounded memory, using recursive shamap walker