You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Uploaded files: any file of the upload directory given as input is deleted, also before a retry #228
UploadedFileManager::deleteInput() deletes any input that is a file directly in upload_directory, not only the files the bundle has just written (the comment "never a file given by its path" is wrong):
an API user (ROLE_USER + token) sending input=/…/uploads/<file of another user> deletes it, e.g. a file still waiting in the asynchronous queue, whose execution then fails; the same with the launch form when entrypoint_type is text;
a ProcessSchedule (or a ui.default.input) whose input is a reference file of this directory loses it after its first execution.
Also, the input is deleted in a finally, so when the execution fails too: when the application configures retries (retry_strategy, failure_transport, messenger:failed:retry), the retried message runs without its file.
And a file written by HttpProcessExecuteValueResolver is never deleted when the request is rejected by the validation (422).
Fix:
an explicit flag in ProcessExecuteMessage (and for the synchronous HTTP execution), set only by LaunchAction and HttpProcessExecuteValueResolver for the file they have just written; never decide from the path only;
in the Messenger handler path, keep the file while the message will be retried;
delete the written file on a 422.
Found during the audit after the 3.4 release (audit-v4-post-release.md#216, #221, #222).
Activity
#228 - Only delete the uploaded files written for the execution, keep…
Merge pull request #231 from cleverage/228