controller for upload file and retrieve