MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Hakan Kuecuekyilmaz Date:July 1 2008 8:04pm
Subject:bzr commit into mysql-falcon branch (hakan:221)
View as plain text  
#At bzr+ssh://bk-internal.mysql.com/bzrroot/mysql-falcon/

  221 Hakan Kuecuekyilmaz	2008-07-01 [merge]
      Merge.
added:
  falcon_bug_statistic/falcon_bug_inflow_last_seven_days.php
  falcon_bug_statistic/falcon_bug_statistic.sh
modified:
  falcon_bug_statistic/include/config.inc.php
  falcon_bug_statistic/include/fbs_query.php

=== added file 'falcon_bug_statistic/falcon_bug_inflow_last_seven_days.php'
--- a/falcon_bug_statistic/falcon_bug_inflow_last_seven_days.php	1970-01-01 00:00:00 +0000
+++ b/falcon_bug_statistic/falcon_bug_inflow_last_seven_days.php	2008-07-01 19:28:07 +0000
@@ -0,0 +1,29 @@
+<?php
+/**
+ * Print out Falcon related bug inflow of last seven days.
+ *
+ * Hakan Kuecuekyilmaz, <hakan at mysql dot com>, 2008-07-01.
+ * $Id$
+ */
+
+require_once 'include/config.inc.php';
+
+$dbh = @mysql_connect(DATABASE_HOST, DATABASE_USER, DATABASE_PASS);
+
+if (!$dbh) {
+    echo '[ERROR]: Could not connect to database.' . "\n";
+    exit;
+}
+
+mysql_select_db(DATABASE_NAME);
+
+$date_last_seven = date('Y-m-d', time() - 60 * 60 * 24 * 8);
+$sql_last_seven = "SELECT count(*) AS count FROM bugdb
+                     WHERE bug_type = 'Server: Falcon'
+                       AND ts1 > '$date_last_seven'";
+
+$res_last_seven = mysql_query($sql_last_seven);
+$row = mysql_fetch_assoc($res_last_seven);
+
+echo date('Y-m-d') . ' ' . $row['count'] . "\n";
+?>

=== added file 'falcon_bug_statistic/falcon_bug_statistic.sh'
--- a/falcon_bug_statistic/falcon_bug_statistic.sh	1970-01-01 00:00:00 +0000
+++ b/falcon_bug_statistic/falcon_bug_statistic.sh	2008-07-01 19:28:07 +0000
@@ -0,0 +1,14 @@
+#!/bin/bash
+#
+# Mail out Falcon Bug Statistic.
+#
+# Script is run via cronjob on shella@stripped.
+#
+# Hakan Kuecuekyilmaz, <hakan at mysql dot com>, 2006-07-01.
+# $Id$
+#
+cd $HOME/work
+scp -p -r production.mysql.com:~/work/mysql-falcon/falcon_bug_statistic .
+
+cd falcon_bug_statistic
+/usr/local/bin/php falcon_bug_statistic_text.php | mail -s"Falcon Bug Statistic as of $(date)" dev-falcon@stripped

=== modified file 'falcon_bug_statistic/include/config.inc.php'
--- a/falcon_bug_statistic/include/config.inc.php	2008-06-30 10:30:36 +0000
+++ b/falcon_bug_statistic/include/config.inc.php	2008-07-01 19:28:07 +0000
@@ -79,9 +79,4 @@ define('URL', 'http://bugs.mysql.com/sea
   . '&fix_effort=all'
 );
 
-/**
- * Array of email addresses who will get a report.
- */
-$receiver[] = 'hakan@stripped';
-$receiver[] = 'klewis@stripped';
 ?>

=== modified file 'falcon_bug_statistic/include/fbs_query.php'
--- a/falcon_bug_statistic/include/fbs_query.php	2008-06-30 18:05:11 +0000
+++ b/falcon_bug_statistic/include/fbs_query.php	2008-07-01 19:28:07 +0000
@@ -59,7 +59,7 @@ $sql_prio_stat =  "SELECT priority, stat
                        AND bug_type = 'Server: Falcon'
                      GROUP BY priority, status";
 
-$date_last_seven = date('Y-m-d',time() - 60 * 60 * 24 * 8);
+$date_last_seven = date('Y-m-d', time() - 60 * 60 * 24 * 8);
 $sql_last_seven = "SELECT id, priority, status, sdesc FROM bugdb
                      WHERE bug_type = 'Server: Falcon'
                        AND ts1 > '$date_last_seven'";

Thread
bzr commit into mysql-falcon branch (hakan:221) Hakan Kuecuekyilmaz1 Jul