[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [OSSTEST PATCH 10/15] sg-run-job: Spawn ts-syslog-server



Every job now gets a syslog server, which starts up after host
allocation.

The server's address and port are recorded by ts-syslog-server in a
runvar and can be used by subsequent test steps.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
v2: Change mistaken TESTID `.' to `='.  `.' means literally `.'.
    Do not start ts-syslog-server if !$ok.
    Do not start ts-syslog-server if job is being truncated now.
    Use new | (stdin pipe) spawn-ts feature; avoids total failure.
---
 sg-run-job | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/sg-run-job b/sg-run-job
index 620d89a..66c2c19 100755
--- a/sg-run-job
+++ b/sg-run-job
@@ -76,6 +76,8 @@ proc run-job {job} {
     if {$ok && ![catch { info args prep-job/$jobinfo(recipe) }]} \
         {      catching-otherwise fail     prep-job/$jobinfo(recipe)      }
 
+    if {$ok} { set syslog [spawn-ts broken = | ts-syslog-server]          }
+
     if {$ok && $need_build_host} \
         { catching-otherwise broken prepare-build-host }
 
@@ -99,6 +101,10 @@ proc run-job {job} {
        run-ts  !broken capture-logs      ts-logs-capture + host
     }
 
+    if {[info exists syslog]} {
+        reap-ts $syslog
+    }
+
     if {$ok} {
         if {[jobdb::job-check-escaped-steps $flight $job]} {
             set ok 0
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.