Bug #3586
closed
[API] Job "priority" field defaults to "null", should default to "0"
Added by Peter Amstutz over 10 years ago.
Updated over 10 years ago.
Estimated time:
(Total: 0.00 h)
Description
The "priority" field is used to sort the job queue, and it defaults to null. Unfortunately, the database automatically puts "null" values first in the sorting order, preventing priority from working as intended. The API server should assign a default numeric priority of 0 when creating the model and a NOT NULL constraint should be added to the schema.
- Subject changed from Job "priority" field defaults to "null", should default to "0" to [API] Job "priority" field defaults to "null", should default to "0"
- Description updated (diff)
- Category set to API
- Target version deleted (
2014-08-27 Sprint)
- Target version set to Arvados Future Sprints
- Target version changed from Arvados Future Sprints to 2014-09-17 sprint
- Assigned To set to Peter Amstutz
- Status changed from New to In Progress
This index seems to have been removed from structure.sql in 80cbf4d9, not sure why/how:
-- Name: pipeline_instance_owner_uuid_name_unique; Type: INDEX; Schema: public; Owner: -; Tablespace:
--
CREATE UNIQUE INDEX pipeline_instance_owner_uuid_name_unique ON pipeline_instances USING btree (owner_uuid, name);
--
It comes back automatically if I do rake db:migrate.
Other than that, LGTM. Thanks.
Ah, I get it (I think): the jobs_owner_uuid_name_unique and pipeline_instance_owner_uuid_name_unique indices stayed in db/structure.sql in the 3036 merge, even though they had been removed from the migration.
I've fixed my own database, so now it agrees with the migrations instead of agreeing with db/structure.sql. Now we just have to remove those two db/structure.sql entries so it agrees with the migrations. (Perhaps best to do it in a separate commit with refs #3036?)
- Status changed from In Progress to Resolved
Also available in: Atom
PDF