Upgrade SDC to use common cassandra cluster
Change-Id: Ib6a45de3b10cb57466b7b3ef2e18b2fe07639c0f
Issue-ID: SDC-2199
Signed-off-by: mahendrr <mahendra.raghuwanshi@amdocs.com>
diff --git a/sdc-os-chef/environments/Template.json b/sdc-os-chef/environments/Template.json
index 3fee2a2..8b5866b 100644
--- a/sdc-os-chef/environments/Template.json
+++ b/sdc-os-chef/environments/Template.json
@@ -79,8 +79,8 @@
"cassandra_user": "asdc_user",
"cassandra_password": "Aa1234%^!",
"concurrent_writes": "32",
- "cluster_name": "SDC-CS-",
- "datacenter_name": "SDC-CS-",
+ "cluster_name": "SDC-CS",
+ "datacenter_name": "SDC-CS",
"multithreaded_compaction": "false",
"cache_dir": "/var/lib/cassandra/saved_caches",
"log_file": "/var/lib/cassandra/log/system.log",
@@ -88,7 +88,8 @@
"commitlog_dir": "/var/lib/cassandra/commitlog",
"socket_read_timeout": "20000",
"socket_connect_timeout": "20000",
- "titan_connection_timeout": "10000"
+ "titan_connection_timeout": "10000",
+ "replication_factor": "1"
}
}
}
diff --git a/sdc-os-chef/sdc-cassandra/chef-repo/cookbooks/cassandra-actions/recipes/01-configureCassandra.rb b/sdc-os-chef/sdc-cassandra/chef-repo/cookbooks/cassandra-actions/recipes/01-configureCassandra.rb
index 47ab456..5b05e9b 100644
--- a/sdc-os-chef/sdc-cassandra/chef-repo/cookbooks/cassandra-actions/recipes/01-configureCassandra.rb
+++ b/sdc-os-chef/sdc-cassandra/chef-repo/cookbooks/cassandra-actions/recipes/01-configureCassandra.rb
@@ -1,5 +1,5 @@
cluster_name = ''
-cluster_name = node['cassandra'][:cluster_name]+node.chef_environment
+cluster_name = node['cassandra'][:cluster_name]
cas_ips=''
cas_ips=node['Nodes'][:CS]
@@ -45,7 +45,7 @@
group "cassandra"
mode "0755"
variables ({
- :dc => cluster_name,
- :rack => "Rack"+"#{rackNum}-"+node.chef_environment
+ :dc => node['cassandra']['datacenter_name'],
+ :rack => "Rack"+"#{rackNum}"
})
-end
\ No newline at end of file
+end