async fn store_answer_uploads(
conn: &mut PgConnection,
destination: AnswerUploadDestination,
payload: Multipart,
file_store: &dyn FileStore,
uploaded_paths: &mut Vec<ExerciseServiceUploadCleanup>,
base_url: &str,
) -> Result<Vec<ExerciseServiceUpload>, ControllerError>Expand description
Stores the multipart parts and binds them to the exercise and user, so that a failure to record the binding cannot leave uploads the reaper is unable to find.
The transaction opens only after the last byte has been streamed: the multipart body has no time
limit, so opening it first would pin a pool connection idle in transaction for the whole
upload.