Storage manager

Full set of changes to add the storage manager.