Wait until exit to write status caches

Uses a destructor to write out at the end, avoid unnecessary/repetitive disk io