def upload(self, system, file_path, upload_file): f = BaseFileResource(self._ag, system, file_path) resp = f.upload(upload_file) reindex_agave.apply_async(kwargs = {'username': '******', 'file_id': '{}/{}'.format(system, file_path), 'levels': 1}) return resp