fixed #1464 - change so persistence dir is only backed up if node is HA ...

...master or HA disabled; handles the case of HA autodetect selecting master hence the complexity.

also fixes some leaks in test and improves atomic file update support in FileBasedObjectStore.
(incorporates new logging from #1469)
Or is that hard because only the individual implementations of `PersistenceObjectStore` know what the `persistMode` is and whether the data dir was initially empty - so hard for anyone else to tell it to backup? In which case a `backupIfNonEmpty()` method? It feels right to have the caller know if it's setting this management node to be writing data or not.