You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by to...@apache.org on 2014/11/05 23:48:24 UTC

[4/5] git commit: Fixes the init calls in the rest tier and docker io issues

Fixes the init calls in the rest tier and docker io issues


Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/f89d1fd5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/f89d1fd5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/f89d1fd5

Branch: refs/heads/key-row-sharding
Commit: f89d1fd57d56e24f275258ae29d8dec80324ac49
Parents: 30dad61
Author: Todd Nine <tn...@apigee.com>
Authored: Wed Nov 5 15:47:09 2014 -0700
Committer: Todd Nine <tn...@apigee.com>
Committed: Wed Nov 5 15:47:09 2014 -0700

----------------------------------------------------------------------
 .../src/main/dist/init_instance/init_graphite_server.sh      | 2 ++
 .../src/main/dist/init_instance/init_rest_server.sh          | 2 +-
 .../src/main/groovy/configure_elasticsearch.groovy           | 2 ++
 stack/awscluster/src/main/groovy/configure_usergrid.groovy   | 8 +++++---
 stack/awscluster/ugcluster-cf.json                           | 3 +++
 5 files changed, 13 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f89d1fd5/stack/awscluster/src/main/dist/init_instance/init_graphite_server.sh
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/dist/init_instance/init_graphite_server.sh b/stack/awscluster/src/main/dist/init_instance/init_graphite_server.sh
index 64d82bc..689c08e 100644
--- a/stack/awscluster/src/main/dist/init_instance/init_graphite_server.sh
+++ b/stack/awscluster/src/main/dist/init_instance/init_graphite_server.sh
@@ -56,6 +56,8 @@ groovy tag_instance.groovy -BUILD-IN-PROGRESS
 cd /usr/share/usergrid/init_instance
 ./install_oraclejdk.sh
 
+sudo apt-get -y --force-yes install docker.io
+
 #Install graphite
 sudo docker run -d --name graphite -p 80:80 -p 2003:2003 -p 8125:8125/udp hopsoft/graphite-statsd
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f89d1fd5/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh b/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
index a255d31..1fe4bb8 100644
--- a/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
+++ b/stack/awscluster/src/main/dist/init_instance/init_rest_server.sh
@@ -207,7 +207,7 @@ sh /etc/init.d/tomcat7 start
 until curl -m 1 -I -X GET http://localhost:8080/status | grep "200 OK";  do sleep 5; done
 
 #Run the migration
-curl -X PUT http://ugtest.usergrid.com/system/migrate/run  -u superuser:test
+curl -X PUT http://localhost:8080/system/migrate/run  -u superuser:test
 
 #Run the system database setup
 curl -X GET http://localhost:8080/system/database/setup -u superuser:test

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f89d1fd5/stack/awscluster/src/main/groovy/configure_elasticsearch.groovy
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/groovy/configure_elasticsearch.groovy b/stack/awscluster/src/main/groovy/configure_elasticsearch.groovy
index 6dec000..79d5c35 100644
--- a/stack/awscluster/src/main/groovy/configure_elasticsearch.groovy
+++ b/stack/awscluster/src/main/groovy/configure_elasticsearch.groovy
@@ -70,9 +70,11 @@ threadpool:
     bulk:
         type: fixed
         size: 5000
+#        size: 16
         queue_size: 100
     search:
         size: 10000
+#        size: 48
         type: fixed
         queue_size: 100
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f89d1fd5/stack/awscluster/src/main/groovy/configure_usergrid.groovy
----------------------------------------------------------------------
diff --git a/stack/awscluster/src/main/groovy/configure_usergrid.groovy b/stack/awscluster/src/main/groovy/configure_usergrid.groovy
index d18c995..c42d84a 100644
--- a/stack/awscluster/src/main/groovy/configure_usergrid.groovy
+++ b/stack/awscluster/src/main/groovy/configure_usergrid.groovy
@@ -42,16 +42,18 @@ def testAdminUserEmail = System.getenv().get("TEST_ADMIN_USER_EMAIL")
 
 def numEsNodes = Integer.parseInt(System.getenv().get("ES_NUM_SERVERS"))
 //Override number of shards.  Set it to 2x the cluster size
-def esShards = numEsNodes*2;
+def esShards = numEsNodes*4;
 
 
+//This gives us 3 copies, which means we'll have a quorum with primary + 1 replica
 def esReplicas = 2;
 
 def cassThreads = System.getenv().get("TOMCAT_THREADS")
 def hystrixThreads = Integer.parseInt(cassThreads) / 100
 
 //if we end in -1, we remove it
-def ec2Region = System.getenv().get("EC2_REGION").replace("-1", "")
+def ec2Region = System.getenv().get("EC2_REGION")
+def cassEc2Region = ec2Region.replace("-1", "")
 
 
 NodeRegistry registry = new NodeRegistry();
@@ -91,7 +93,7 @@ def usergridConfig = """
 cassandra.url=${cassandras}
 cassandra.cluster=${clusterName}
 cassandra.keyspace.strategy=org.apache.cassandra.locator.NetworkTopologyStrategy
-cassandra.keyspace.replication=${ec2Region}:${replFactor}
+cassandra.keyspace.replication=${cassEc2Region}:${replFactor}
 
 cassandra.timeout=5000
 cassandra.connections=${cassThreads}

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/f89d1fd5/stack/awscluster/ugcluster-cf.json
----------------------------------------------------------------------
diff --git a/stack/awscluster/ugcluster-cf.json b/stack/awscluster/ugcluster-cf.json
index c8b96ee..c432923 100644
--- a/stack/awscluster/ugcluster-cf.json
+++ b/stack/awscluster/ugcluster-cf.json
@@ -188,6 +188,9 @@
             "m3.xlarge": {
                 "Arch": "64"
             },
+            "c3.large": {
+                "Arch": "64"
+            },
             "c3.xlarge": {
                 "Arch": "64"
             },