[Bug] Task could not get resources when resource file was deleted and re-uploaded again#13593
[Bug] Task could not get resources when resource file was deleted and re-uploaded again#13593QuantumXiecao wants to merge 1 commit intoapache:devfrom
Conversation
… re-uploaded again
SbloodyS
left a comment
There was a problem hiding this comment.
Please associate your issue.
|
|
Related Issure: #13583 |
We've refactored the resources center in #12076. So the behavior between version 3.1.X and dev are quite huge. You should coding base on the 3.1.4-prepare branch and push it to 3.1.4-prepare branch if you want to fix it. |
|
@SbloodyS ok |
|
SonarCloud Quality Gate failed. |
|
Hi, @QuantumXiecao I just find that some fixes in this pr also work for dev, you can separate them and create another pr base on dev. In addition, can we disallow resource deletion when it binds to a task whether the task is online or offline? cc @SbloodyS |
In my personal opinion, we can't prevent such operations because users can delete them from third-party storage. I think we can throw an error message to tell the user that the file cannot be found instead of NPE during task execution. WDYT? |
Good suggestion, agree with you : ) |









Purpose of the pull request
Task could not get resources when resource file was deleted and re-uploaded again.
Related Issure:
close #13583
Brief change log
Before fixing:
After fixing:
Before fixing:

Delete resource failed when related process/task info already removed.
After fixing: We could delete resource normally when related process/task info already removed.
Verify this pull request
This pull request is code cleanup without any test coverage.
(or)
This pull request is already covered by existing tests, such as (please describe tests).
(or)
This change added tests and can be verified as follows:
yes
(or)
If your pull request contain incompatible change, you should also add it to
docs/docs/en/guide/upgrede/incompatible.md