Select sets and not datasets in processes
see #1712 (closed)
Migration:
- Create the
ProcessDatasetSetmodel. - Create
ProcessDatasetSetinstances for all of the sets fromProcessDataset, using anUNNESTlike forDatasetSet. You will need to join onDatasetSetto find theset_id, and that should implicitly exclude any set names that were inProcessDataset.setsand that do not exist. - Drop
ProcessDataset.
The ProcessDataset model is replaced by ProcessDatasetSet, linking a process to a DatasetSet. Dataset processes will now require users to select sets directly, rather than select datasets and then play around with checkboxes.
Endpoints:
ListProcessDatasets is used by base-worker, but we got the greenlight to mess with it, as MLProd seems to actually prefer working with sets rather than datasets. It should be renamed ListProcessSets, because ListProcessDatasetSets is quite a mouthful. Its response now includes the set ID, set name, and dataset.
CreateProcessDataset and DestroyProcessDataset are renamed CreateProcessSet and DestroyProcessSet. It might be easiest to have them use /api/v1/<process_id>/set/<set_id>/ directly, but there is more freedom here as these endpoints are only used by the frontend.
UpdateProcessDataset and PartialUpdateProcessDataset are removed, since they were used to select sets within a dataset.