Addshore has submitted this change and it was merged.

Change subject: Track propertycreators and bots
......................................................................


Track propertycreators and bots

Change-Id: Ib6d7115e35ced30a5f9cbfa012b3f20663d136c5
---
M cron
A graphite/site_stats/bots.sh
A graphite/site_stats/propertycreators.sh
3 files changed, 26 insertions(+), 0 deletions(-)

Approvals:
  Addshore: Verified; Looks good to me, approved



diff --git a/cron b/cron
index 7ce988f..f92d069 100644
--- a/cron
+++ b/cron
@@ -29,3 +29,5 @@
 13 6 * * * ~/wikidata-data/graphite/site_stats/users.sh
 14 6 * * * ~/wikidata-data/graphite/site_stats/admins.sh
 15 6 * * * ~/wikidata-data/graphite/site_stats/bureaucrats.sh
+16 6 * * * ~/wikidata-data/graphite/site_stats/bots.sh
+17 6 * * * ~/wikidata-data/graphite/site_stats/propertycreators.sh
diff --git a/graphite/site_stats/bots.sh b/graphite/site_stats/bots.sh
new file mode 100644
index 0000000..a34ca33
--- /dev/null
+++ b/graphite/site_stats/bots.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+#
+# @author Addshore
+#
+# The number of users in the bots on a give day.
+# Generated using the user_groups table.
+#
+# SELECT ug_group, count(*) AS count FROM user_groups GROUP BY ug_group;
+
+value=$(mysql --defaults-file=/etc/mysql/conf.d/analytics-research-client.cnf 
-h analytics-store.eqiad.wmnet -A -se "select count(*) as count from 
user_groups where ug_group = 'bot' group by ug_group" wikidatawiki)
+
+echo "daily.wikidata.site_stats.user_groups.bots $value `date +%s`" | nc -q0 
graphite.eqiad.wmnet 2003
diff --git a/graphite/site_stats/propertycreators.sh 
b/graphite/site_stats/propertycreators.sh
new file mode 100644
index 0000000..3f8196f
--- /dev/null
+++ b/graphite/site_stats/propertycreators.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+#
+# @author Addshore
+#
+# The number of users in the propertycreators on a give day.
+# Generated using the user_groups table.
+#
+# SELECT ug_group, count(*) AS count FROM user_groups GROUP BY ug_group;
+
+value=$(mysql --defaults-file=/etc/mysql/conf.d/analytics-research-client.cnf 
-h analytics-store.eqiad.wmnet -A -se "select count(*) as count from 
user_groups where ug_group = 'propertycreator' group by ug_group" wikidatawiki)
+
+echo "daily.wikidata.site_stats.user_groups.propertycreators $value `date 
+%s`" | nc -q0 graphite.eqiad.wmnet 2003

-- 
To view, visit https://gerrit.wikimedia.org/r/253923
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib6d7115e35ced30a5f9cbfa012b3f20663d136c5
Gerrit-PatchSet: 1
Gerrit-Project: analytics/limn-wikidata-data
Gerrit-Branch: master
Gerrit-Owner: Addshore <[email protected]>
Gerrit-Reviewer: Addshore <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to