Closed Bug 1221816 Opened 9 years ago Closed 9 years ago

Limit the length of `foo__in` API parameters (eg `result_set_id__in=21015,21014,...`)

Categories

(Tree Management :: Treeherder: API, defect, P1)

defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: emorley, Unassigned)

References

Details

In bug 1211415 comment 4 there was a request being made to: treeherder.mozilla.org/api/project/mozilla-inbound/jobs/?count=2000&last_modified__gt=2015-09-25T20:36:20.000&result_set_id__in=21015,21014,21013,21012,21011,**SNIP**,20369,20368,20367,20366,20365,20364,20363,20362&return_type=list ...where there were 654 result_set ids passed to result_set_id__in. IMO this is not something we should support (and it's not surprising it caused load issues on our API). Whilst we're reducing the gunicorn timeout and also recently the /jobs/ endpoint was made more performant, due to removing the resultset join and ORDER BY, I still think people should be able to pass in at most say 100 resultsets at a time. In addition, I wonder if we should apply a similar limitation to other __in parameters (eg for the resultset endpoint, job artifacts etc). Mauro - thoughts?
Flags: needinfo?(mdoglio)
I don't think we need this anymore now that bug 1221064 is fixed. I would call this a WONTFIX.
Flags: needinfo?(mdoglio)
Yeah the query now only takes 7s :-)
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.