Idea #9867
closed[API] [Crunch] Permit UUIDs to be used in crunch1 job script_parameters
Description
Background¶
For some clients/workflows it makes sense to run a job using "whatever collection UUID=X looks like right now" as an input -- even if the collection is expected to change while the job is running.
However, currently, if a client submits a Job with a collection UUID as a script_parameter value, the API responds 422.
This check was in place (IIRC) since the move from "collection UUID is really a PDH" to "collection has a UUID and a PDH", when we wanted to catch clients accidentally submitting the wrong value.
There is no philosophical reason we should refuse to run non-pure jobs.
Improvement¶
Instead of refusing non-PDH collections like this...
source:services/api/app/models/job.rb#L435
...just set the "nondeterministic" flag when we notice UUIDs here.
Related¶
Currently, crunch-job runs arv-mount with "--mount-by-pdh". Unless this is also changed, jobs won't be able to access their UUID-addressed inputs through FUSE. Consider changing this to --mount-by-id (?) based on whether the job's "nondeterministic" flag is set or whether it has any UUIDs in its script_parameters.