Moved ReconnectDelayManager to make it accessible for mocking

and added creation of directory structure to MetadataHandler.