allow result reporting by build, use it in CLI (for now?) T619
ClosedPublic

Authored by adamwill on Sep 17 2015, 3:43 AM.

Details

Summary

This rejigs things so that result reporting can be done by
BUILD as well as by list of job IDs. This is specifically
intended to help with T619: it will handle cases where jobs
get restarted by openQA. It has another significant benefit,
though. As things stand, for a list of job IDs, the client has
to run one API query per job, which takes longer and increases
the risk of hitting a timeout or something. For a build, the
client only has to run a single query. So this should be more
robust as well.

I have a PR upstream to allow for retrieving a bunch of jobs by
ID in a single query:
https://github.com/os-autoinst/openQA/pull/434
so if that gets merged, we could re-consider this. We'd still
need some code for catching when jobs get cloned, though.

You can imagine cases where this reports results from jobs
that weren't actually created by this specific submission,
but I can't think of any cases where it would do anything
*wrong*, really.

Test Plan

Check that result submission still works as before,
except that cloned jobs are handled and there are fewer API
calls.

Diff Detail

Repository
rOPENQA fedora_openqa
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
adamwill retitled this revision from to allow result reporting by build, use it in CLI (for now?) T619.Sep 17 2015, 3:43 AM
adamwill updated this object.
adamwill edited the test plan for this revision. (Show Details)
adamwill added reviewers: jskladan, garretraziel.
garretraziel accepted this revision.Sep 21 2015, 10:58 AM

Looks OK.

fedora_openqa_schedule/report.py
47–91

This is much better now!

This revision is now accepted and ready to land.Sep 21 2015, 10:58 AM
This revision was automatically updated to reflect the committed changes.