Rfaulk has uploaded a new change for review.
https://gerrit.wikimedia.org/r/51615
Change subject: mod. update config info for E3 user metrics deployment.
......................................................................
mod. update config info for E3 user metrics deployment.
Change-Id: I43d5f418fa34c73eba0c97c8f808b429fb9930db
---
M manifests/misc/statistics.pp
M templates/misc/e3-metrics-api.settings.py.erb
2 files changed, 54 insertions(+), 16 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/15/51615/1
diff --git a/manifests/misc/statistics.pp b/manifests/misc/statistics.pp
index c4e0494..2f8f16f 100644
--- a/manifests/misc/statistics.pp
+++ b/manifests/misc/statistics.pp
@@ -252,7 +252,7 @@
$e3_analysis_path = "$e3_home/E3Analysis"
$e3_user = $misc::statistics::user::username
- # these get rendered in $e3_analysis_path/config/settings.py
+ # these get rendered in
$e3_analysis_path/user_metrics/config/settings.py
$mysql_user = $passwords::mysql::research::user
$mysql_pass = $passwords::mysql::research::pass
$mysql_db = "staging"
@@ -289,7 +289,7 @@
# Need settings.py to configure metrics-api python application
# Make this only readable by stats user; it has db passwords in it.
- file { "$e3_analysis_path/config/settings.py":
+ file { "$e3_analysis_path/user_metrics/config/settings.py":
content => template("misc/e3-metrics-api.settings.py.erb"),
owner => $e3_user,
group => "root",
diff --git a/templates/misc/e3-metrics-api.settings.py.erb
b/templates/misc/e3-metrics-api.settings.py.erb
index 2d7d823..6284bd8 100644
--- a/templates/misc/e3-metrics-api.settings.py.erb
+++ b/templates/misc/e3-metrics-api.settings.py.erb
@@ -1,23 +1,61 @@
# Project settings
# ================
-__home__ = '<%= e3_home %>'
-__project_home__ = '<%= e3_analysis_path %>'
-__web_home__ = ''.join([__project_home__, 'web_interface/'])
-__sql_home__ = ''.join([__project_home__, 'SQL/'])
-__server_log_local_home__ = ''.join([__project_home__, 'logs/'])
-__data_file_dir__ = ''.join([__project_home__, 'data/'])
-__web_app_module__ = 'web_interface'
-__system_user__ = 'stats'
+__project_home__ = '<%= e3_analysis_path %>'
+__web_home__ = ''.join([__project_home__, 'src/api/'])
+__data_file_dir__ = ''.join([__project_home__, 'data/'])
+
+__query_module__ = 'query_calls_sql'
+__user_thread_max__ = 100
+__rev_thread_max__ = 50
+
+__cohort_data_instance__ = 'cohorts'
+__cohort_db__ = 'usertags'
+__cohort_meta_db__ = 'usertags_meta'
+__cohort_meta_instance__ = 'prod'
+
# Database connection settings
# ============================
connections = {
'slave': {
- 'user' : '<%= mysql_user %>',
- 'passwd' : '<%= mysql_pass %>',
- 'host' : '<%= mysql_host %>',
- 'db' : '<%= mysql_db %>',
- 'port' : <%= mysql_port %>}
-}
\ No newline at end of file
+ 'user' : '<%= mysql_user_1 %>',
+ 'passwd' : '<%= mysql_pass_1 %>',
+ 'host' : '<%= mysql_host_1 %>',
+ 'db' : '<%= mysql_db_1 %>',
+ 'port' : <%= mysql_port_1 %>}
+ 's1': {
+ 'user' : '<%= mysql_user_2 %>',
+ 'passwd' : '<%= mysql_pass_2 %>',
+ 'host' : '<%= mysql_host_2 %>',
+ 'port' : <%= mysql_port_2 %>}
+ 's2': {
+ 'user' : '<%= mysql_user_3 %>',
+ 'passwd' : '<%= mysql_pass_3 %>',
+ 'host' : '<%= mysql_host_3 %>',
+ 'port' : <%= mysql_port_3 %>}
+ 's3': {
+ 'user' : '<%= mysql_user_4 %>',
+ 'passwd' : '<%= mysql_pass_4 %>',
+ 'host' : '<%= mysql_host_4 %>',
+ 'port' : <%= mysql_port_4 %>}
+ 's4': {
+ 'user' : '<%= mysql_user_5 %>',
+ 'passwd' : '<%= mysql_pass_5 %>',
+ 'host' : '<%= mysql_host_5 %>',
+ 'port' : <%= mysql_port_5 %>}
+ 's5': {
+ 'user' : '<%= mysql_user_6 %>',
+ 'passwd' : '<%= mysql_pass_6 %>',
+ 'host' : '<%= mysql_host_6 %>',
+ 'port' : <%= mysql_port_6 %>}
+}
+
+PROJECT_DB_MAP = {
+ 'enwiki': 's1',
+ 'dewiki': 's5',
+ 'itwiki': 's2',
+ 'commonswiki': 's4',
+}
+
--
To view, visit https://gerrit.wikimedia.org/r/51615
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I43d5f418fa34c73eba0c97c8f808b429fb9930db
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Rfaulk <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits