I see single process mode uses 'app_id.empty()' for Update() checking.
How about change this way?
if  ( !application_service_->Install(file_path, &app_id) &&
      (app_id.empty() || !application_service_->Update(app_id, file_path)))