GWicke has uploaded a new change for review.
https://gerrit.wikimedia.org/r/191686
Change subject: Set the cassandra localDc parameter
......................................................................
Set the cassandra localDc parameter
This tells the client which datacenter it should consider local for
localQuorum and preferred connection purposes. We also use this currently as a
proxy for which DC we should create tables in, but plan to move to adjusting
the replication dynamically based on the cluster info exposed by cassandra
itself in the future.
Change-Id: I003c4c27d412fe94118c30ecad30aae3d188e4fb
---
M modules/cassandra
M modules/cdh
M modules/restbase/manifests/init.pp
M modules/restbase/templates/config.yaml.erb
4 files changed, 4 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/86/191686/1
diff --git a/modules/cassandra b/modules/cassandra
index 3445282..0894302 160000
--- a/modules/cassandra
+++ b/modules/cassandra
-Subproject commit 34452828ad2b76cbf17e8c8a1c3e6cbddcf07b24
+Subproject commit 08943021b2e5a39ce48ad369b64fcf9ef0899c45
diff --git a/modules/cdh b/modules/cdh
index f71f942..6e5d310 160000
--- a/modules/cdh
+++ b/modules/cdh
-Subproject commit f71f942b035e70c16e17cff9b42b6b697e17bf44
+Subproject commit 6e5d3103894cd1a64ffa323a28fdc40611a576a1
diff --git a/modules/restbase/manifests/init.pp
b/modules/restbase/manifests/init.pp
index 7be52d0..456b430 100644
--- a/modules/restbase/manifests/init.pp
+++ b/modules/restbase/manifests/init.pp
@@ -15,6 +15,8 @@
# [*cassandra_defaultConsistency*]
# Default cassandra query consistency level. Typically 'one' or
# 'localQuorum'. Default: 'localQuorum'.
+# [*cassandra_localDc*]
+# Which DC should be considered local. Default: 'datacenter1'.
# [*port*]
# Port where to run the restbase service. Default: 7231
# [*logstash_host*]
@@ -34,6 +36,7 @@
$cassandra_password = 'cassandra',
$seeds = [$::ipaddress],
$cassandra_defaultConsistency = 'localQuorum',
+ $cassandra_localDc = 'datacenter1',
$port = 7231,
$logstash_host = 'localhost',
$logstash_port = 12201,
diff --git a/modules/restbase/templates/config.yaml.erb
b/modules/restbase/templates/config.yaml.erb
index 80164f9..bd6a3db 100644
--- a/modules/restbase/templates/config.yaml.erb
+++ b/modules/restbase/templates/config.yaml.erb
@@ -62,6 +62,7 @@
conf:
hosts: [<%= Array(@seeds).join(',') %>]
keyspace: system
+ localDc: <%= @cassandra_localDc %>
username: <%= @cassandra_user %>
password: <%= @cassandra_password %>
defaultConsistency: <%= @cassandra_defaultConsistency %>
--
To view, visit https://gerrit.wikimedia.org/r/191686
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I003c4c27d412fe94118c30ecad30aae3d188e4fb
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: GWicke <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits