Zack Cerza
adc51e1c69
Drop usage of safe_while
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-29 16:41:45 -05:00
Zack Cerza
ea9c034f3c
Use the new ResultsReporter.session object
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-29 16:17:08 -05:00
Zack Cerza
ec72137e1b
Add a requests.Session object to ResultsReporter
...
By default it is set up to retry requests 10 times
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-29 16:17:08 -05:00
Zack Cerza
61e469b632
Remove unused timeout arg to ResultsReporter init
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-29 16:17:07 -05:00
Zack Cerza
3faeb08db2
When deleting all of a run's jobs, delete the run
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-29 15:18:42 -05:00
Zack Cerza
1448cdf5fc
Work around #8166
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-21 10:11:15 -05:00
Zack Cerza
e9a1c778f1
Update requests version
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-17 15:33:26 -05:00
Zack Cerza
03b8cdac38
Refactor try_delete_jobs()
...
Also tweak its error message
2014-04-17 12:27:42 -05:00
Zack Cerza
d12e6f4e00
Be slightly less verbose about logging
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-17 12:27:41 -05:00
Zack Cerza
741c773be6
Look for archive_base in config
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-17 12:27:41 -05:00
Zack Cerza
66a2742211
Add methods for querying and deleting jobs
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-04-17 12:27:41 -05:00
Alfredo Deza
b476ec297e
remove unused import
...
Signed-off-by: Alfredo Deza <alfredo.deza@inktank.com>
2014-04-09 16:27:25 -04:00
Zack Cerza
2e997aa7b1
Report job updated time
...
When reading job information from archive files, use the mtime of
teuthology.log as the job updated time
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-03-31 23:12:34 -05:00
Zack Cerza
c404be6162
Postpone creation of logger object
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-03-25 10:07:52 -05:00
Zack Cerza
e471f404e6
Make try_push_job_info() retry using safe_while
...
I've noticed sometimes try_push_job_info() fails because of server load
issues. It should try more than once (and now does).
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-03-08 15:36:22 -06:00
Zack Cerza
0dcf3f4d71
--dead implies --refresh
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-02-26 16:41:43 -06:00
Zack Cerza
f8a2a53c59
Push complete info when reporting jobs as dead
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-02-26 12:09:04 -06:00
Zack Cerza
5c0496633c
Enable reporting of entire runs as dead
2014-01-06 11:08:12 -06:00
Zack Cerza
027929e0cb
Use response.text if response.json is None
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2014-01-03 15:08:45 -06:00
Zack Cerza
56c70e1145
Set the content-type in report_job()
2013-12-30 17:30:14 -06:00
Zack Cerza
ba8f99991a
Split out ResultsSerializer.job_info()
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-12-30 17:30:14 -06:00
Zack Cerza
e985ca2aab
Port from httplib2 to requests module
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-12-30 17:30:14 -06:00
Zack Cerza
f8ce69cb9b
Add ability to mark jobs as 'dead'
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-12-20 10:01:03 -06:00
Zack Cerza
7f135ec94a
Enable reporting of single jobs
...
(also switch to docopt)
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-12-12 17:00:43 -06:00
Zack Cerza
deec86c703
Also catch httplib2.ServerNotFoundError
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-11-22 17:03:29 -06:00
Zack Cerza
88792d62e1
Make report_job() always return an int
2013-11-12 17:07:15 -06:00
Zack Cerza
b3e730e346
Also catch socket.error in try_push_job_info
2013-11-07 18:39:16 -06:00
Zack Cerza
ed81960242
Don't use create_run() unless necessary
...
Runs are created automatically now.
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-11-04 14:56:13 -06:00
Zack Cerza
c31d747640
Fix broken logic in running_jobs_for_run()
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-16 13:43:05 -05:00
Zack Cerza
bac2965af6
ResultsSerializer.running_jobs_for_run() and test
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-14 16:34:45 -05:00
Zack Cerza
494c3b1fbe
Make verbosity propagate correctly to modules
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 17:10:57 -05:00
Zack Cerza
3905ab993f
Debug output for all http requests
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 16:29:42 -05:00
Zack Cerza
7d99de72bd
Give reporting a verbose flag
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 16:24:54 -05:00
Zack Cerza
2e3e127e72
Lack of a job_id should be a warning
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 14:32:21 -05:00
Zack Cerza
636dc8676e
Move part of report_all_runs() into report_runs()
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 10:48:02 -05:00
Zack Cerza
61606fe0fa
Set a default timeout of 20s for HTTP connections
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-11 10:23:00 -05:00
Zack Cerza
bd9cbdba03
Don't attempt to report if there's no job_id
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-10 19:09:35 -05:00
Zack Cerza
7ab9726737
Move teuthology-report's arg parsing to scripts/
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-10 19:09:34 -05:00
Zack Cerza
1c32b1b886
Reflect paddles API change: jobs in jobs/
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-07 10:01:48 -05:00
Zack Cerza
972ab1cf22
Tweak logic of try_push_job_info()
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-04 15:01:16 -05:00
Zack Cerza
2270db724d
Add (and use) try_push_job_info() for easy pushin'
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-04 11:07:33 -05:00
Zack Cerza
ff120d7fb5
Escape reserved characters in URIs
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-03 16:08:12 -05:00
Zack Cerza
f0b35fca70
Add more documentation.
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-03 16:08:12 -05:00
Zack Cerza
058a27bf59
Add create_run() and push_job_info() with docs.
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
fe64887ec6
s/submit_/report_/g
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
555e55ff61
Rename ResultsPoster to ResultsReporter
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
79e27abfe9
Add create_run; allow passing json to submit_job
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
52282fb7f4
Overhaul posting logic to avoid some corner cases
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
4bcae4b18b
Add flag for refreshing already-pushed runs
...
Also tweak implementation of save_last_run
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00
Zack Cerza
da4a7b860d
Remove old method used for testing
...
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
2013-10-02 18:34:04 -05:00