Added missing flush() in MetadataHandler.