[oe] [PATCH] oestats-client: only send report when task has failed

Eric Bénard eric at eukrea.com
Fri Feb 18 10:46:06 UTC 2011


actual behaviour is to send a report for *each* task runned by bitbake
this is ok for one personnal oestat server but doesn't scale well when
dozen of peoples are running test builders which all send reports to
the OE's infrastructure.

Signed-off-by: Eric Bénard <eric at eukrea.com>
---
 classes/oestats-client.bbclass |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/classes/oestats-client.bbclass b/classes/oestats-client.bbclass
index 4233d4a..b568442 100644
--- a/classes/oestats-client.bbclass
+++ b/classes/oestats-client.bbclass
@@ -172,8 +172,8 @@ def oestats_task(server, d, task, status):
 	# send report
 	# FIXME: resend on http/url error?
 	try:
-		response = oestats_send(d, server, "/tasks/", vars, files)
 		if status == 'Failed':
+			response = oestats_send(d, server, "/tasks/", vars, files)
 			bb.warn("oestats: task failed, see %s%s" % (server, response))
 	except:
 		bb.warn("oestats: error sending task (%s), disabling stats" % get_exc_info())
-- 
1.7.0.4





More information about the Openembedded-devel mailing list