[autotest] Save parent job id, build, board and suite info to tko_jobs.

parent job id is passed in through autoserv commandline. autoserv saves the
value to keyval file in results folder. The parser job then reads the parent
job id from keyval file.

build, board and suite info are parsed from job name. The label column in
tko_jobs is essentially the job name. However, that column has a size limit of
100 characters, thus the name could be truncated. This CL parse the actual job
name to get the build, board and suite info and save to tko_jobs table.

BUG=chromium:509770,chromium:509901
TEST=local test
CQ-DEPEND=CL:285026

Change-Id: I06b073b052a9d07ffd36308b1682a7bc12699898
Reviewed-on: https://chromium-review.googlesource.com/286265
Tested-by: Dan Shi <dshi@chromium.org>
Reviewed-by: Mungyung Ryu <mkryu@google.com>
Commit-Queue: Dan Shi <dshi@chromium.org>
diff --git a/frontend/afe/site_rpc_interface.py b/frontend/afe/site_rpc_interface.py
index 997ec10..97ef017 100644
--- a/frontend/afe/site_rpc_interface.py
+++ b/frontend/afe/site_rpc_interface.py
@@ -42,6 +42,8 @@
 
 
 def canonicalize_suite_name(suite_name):
+    # Do not change this naming convention without updating
+    # site_utils.parse_job_name.
     return 'test_suites/control.%s' % suite_name
 
 
@@ -207,6 +209,8 @@
         suite_name = canonicalize_suite_name(name)
         control_file = _get_control_file_contents_by_name(test_source_build,
                                                           ds, suite_name)
+        # Do not change this naming convention without updating
+        # site_utils.parse_job_name.
         name = '%s-%s' % (test_source_build, suite_name)
 
     timeout_mins = timeout_mins or timeout * 60