Signed-off-by: Cao Xueliang caoxl78320@163.com --- src/delimiter/utils.rb | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/src/delimiter/utils.rb b/src/delimiter/utils.rb index 679c8d9..2be99b5 100644 --- a/src/delimiter/utils.rb +++ b/src/delimiter/utils.rb @@ -88,16 +88,24 @@ module Utils return 'good' end
+ def get_account_info + ESQuery.new(index: 'accounts').query_by_id('compass-ci@qq.com') + end + def init_job_content(job_id) es = ESQuery.new job = es.query_by_id(job_id) raise "es query job id: #{job_id} failed!" unless job
+ account_info = get_account_info + raise "query compass-ci@qq.com account info failed!" unless account_info + job['bad_job_id'] = job_id job['suite'] = 'bisect' + job['my_email'] = account_info['my_email'] + job['my_name'] = account_info['my_name'] + job['my_uuid'] = account_info['my_uuid']
- job.delete('id') - job.delete('uuid') job.delete('error_ids') job.delete('start_time') job.delete('end_time')