diff options
author | Jenkins <jenkins@review.openstack.org> | 2016-04-22 23:29:23 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2016-04-22 23:29:23 +0000 |
commit | d1624aa6e6cac3b70f2344800bba09c8e2d20670 (patch) | |
tree | 9ba09553485a93abd94e0f845ef9635011f96974 | |
parent | df72829d479a32ac07c6420316f7515c13b50447 (diff) | |
parent | 3bfaed934b27896886833ce2b0d5c10a0ce85b8f (diff) | |
download | trove-integration-d1624aa6e6cac3b70f2344800bba09c8e2d20670.tar.gz |
Merge "Fix "trove_volume_size" test prop type"
-rw-r--r-- | scripts/conf/cassandra.conf | 8 | ||||
-rw-r--r-- | scripts/conf/couchbase.conf | 8 | ||||
-rw-r--r-- | scripts/conf/couchdb.conf | 8 | ||||
-rw-r--r-- | scripts/conf/db2.conf | 8 | ||||
-rw-r--r-- | scripts/conf/mariadb.conf | 8 | ||||
-rw-r--r-- | scripts/conf/mongodb.conf | 10 | ||||
-rw-r--r-- | scripts/conf/mysql.conf | 8 | ||||
-rw-r--r-- | scripts/conf/percona.conf | 8 | ||||
-rw-r--r-- | scripts/conf/postgresql.conf | 8 | ||||
-rw-r--r-- | scripts/conf/pxc.conf | 8 | ||||
-rw-r--r-- | scripts/conf/redis.conf | 8 | ||||
-rw-r--r-- | scripts/conf/vertica.conf | 8 | ||||
-rwxr-xr-x | scripts/redstack | 72 |
13 files changed, 96 insertions, 74 deletions
diff --git a/scripts/conf/cassandra.conf b/scripts/conf/cassandra.conf index 09a6e00..5a2f0ac 100644 --- a/scripts/conf/cassandra.conf +++ b/scripts/conf/cassandra.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.large", - "instance_bigger_flavor_name": "test.large.resize", - "instance_eph_flavor_name": "test.eph.large", - "instance_bigger_eph_flavor_name": "test.eph.large.resize", + "instance_flavor_name": "test.large-5", + "instance_bigger_flavor_name": "test.large-5.resize", + "instance_eph_flavor_name": "test.eph.large-5", + "instance_bigger_eph_flavor_name": "test.eph.large-5.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/couchbase.conf b/scripts/conf/couchbase.conf index 09a6e00..5a2f0ac 100644 --- a/scripts/conf/couchbase.conf +++ b/scripts/conf/couchbase.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.large", - "instance_bigger_flavor_name": "test.large.resize", - "instance_eph_flavor_name": "test.eph.large", - "instance_bigger_eph_flavor_name": "test.eph.large.resize", + "instance_flavor_name": "test.large-5", + "instance_bigger_flavor_name": "test.large-5.resize", + "instance_eph_flavor_name": "test.eph.large-5", + "instance_bigger_eph_flavor_name": "test.eph.large-5.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/couchdb.conf b/scripts/conf/couchdb.conf index 0b84987..65bd382 100644 --- a/scripts/conf/couchdb.conf +++ b/scripts/conf/couchdb.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.tiny", - "instance_bigger_flavor_name": "test.tiny.resize", - "instance_eph_flavor_name": "test.eph.tiny", - "instance_bigger_eph_flavor_name": "test.eph.tiny.resize", + "instance_flavor_name": "test.tiny-3", + "instance_bigger_flavor_name": "test.tiny-3.resize", + "instance_eph_flavor_name": "test.eph.tiny-3", + "instance_bigger_eph_flavor_name": "test.eph.tiny-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/db2.conf b/scripts/conf/db2.conf index 2d0d31f..a842ea0 100644 --- a/scripts/conf/db2.conf +++ b/scripts/conf/db2.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.small", - "instance_bigger_flavor_name": "test.small.resize", - "instance_eph_flavor_name": "test.eph.small", - "instance_bigger_eph_flavor_name": "test.eph.small.resize", + "instance_flavor_name": "test.small-5", + "instance_bigger_flavor_name": "test.small-5.resize", + "instance_eph_flavor_name": "test.eph.small-5", + "instance_bigger_eph_flavor_name": "test.eph.small-5.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/mariadb.conf b/scripts/conf/mariadb.conf index 2d0d31f..eac3c57 100644 --- a/scripts/conf/mariadb.conf +++ b/scripts/conf/mariadb.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.small", - "instance_bigger_flavor_name": "test.small.resize", - "instance_eph_flavor_name": "test.eph.small", - "instance_bigger_eph_flavor_name": "test.eph.small.resize", + "instance_flavor_name": "test.small-3", + "instance_bigger_flavor_name": "test.small-3.resize", + "instance_eph_flavor_name": "test.eph.small-3", + "instance_bigger_eph_flavor_name": "test.eph.small-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/mongodb.conf b/scripts/conf/mongodb.conf index ba94115..0e0aae0 100644 --- a/scripts/conf/mongodb.conf +++ b/scripts/conf/mongodb.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.large", - "instance_bigger_flavor_name": "test.large.resize", - "instance_eph_flavor_name": "test.eph.large", - "instance_bigger_eph_flavor_name": "test.eph.large.resize", + "instance_flavor_name": "test.large-5", + "instance_bigger_flavor_name": "test.large-5.resize", + "instance_eph_flavor_name": "test.eph.large-5", + "instance_bigger_eph_flavor_name": "test.eph.large-5.resize", "trove_volume_support": true, - "trove_volume_size": "5", + "trove_volume_size": 5, diff --git a/scripts/conf/mysql.conf b/scripts/conf/mysql.conf index 2d0d31f..eac3c57 100644 --- a/scripts/conf/mysql.conf +++ b/scripts/conf/mysql.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.small", - "instance_bigger_flavor_name": "test.small.resize", - "instance_eph_flavor_name": "test.eph.small", - "instance_bigger_eph_flavor_name": "test.eph.small.resize", + "instance_flavor_name": "test.small-3", + "instance_bigger_flavor_name": "test.small-3.resize", + "instance_eph_flavor_name": "test.eph.small-3", + "instance_bigger_eph_flavor_name": "test.eph.small-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/percona.conf b/scripts/conf/percona.conf index 2d0d31f..eac3c57 100644 --- a/scripts/conf/percona.conf +++ b/scripts/conf/percona.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.small", - "instance_bigger_flavor_name": "test.small.resize", - "instance_eph_flavor_name": "test.eph.small", - "instance_bigger_eph_flavor_name": "test.eph.small.resize", + "instance_flavor_name": "test.small-3", + "instance_bigger_flavor_name": "test.small-3.resize", + "instance_eph_flavor_name": "test.eph.small-3", + "instance_bigger_eph_flavor_name": "test.eph.small-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/postgresql.conf b/scripts/conf/postgresql.conf index 9972a2e..8033f58 100644 --- a/scripts/conf/postgresql.conf +++ b/scripts/conf/postgresql.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.medium", - "instance_bigger_flavor_name": "test.medium.resize", - "instance_eph_flavor_name": "test.eph.medium", - "instance_bigger_eph_flavor_name": "test.eph.medium.resize", + "instance_flavor_name": "test.medium-4", + "instance_bigger_flavor_name": "test.medium-4.resize", + "instance_eph_flavor_name": "test.eph.medium-4", + "instance_bigger_eph_flavor_name": "test.eph.medium-4.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/pxc.conf b/scripts/conf/pxc.conf index 2d0d31f..eac3c57 100644 --- a/scripts/conf/pxc.conf +++ b/scripts/conf/pxc.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.small", - "instance_bigger_flavor_name": "test.small.resize", - "instance_eph_flavor_name": "test.eph.small", - "instance_bigger_eph_flavor_name": "test.eph.small.resize", + "instance_flavor_name": "test.small-3", + "instance_bigger_flavor_name": "test.small-3.resize", + "instance_eph_flavor_name": "test.eph.small-3", + "instance_bigger_eph_flavor_name": "test.eph.small-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/redis.conf b/scripts/conf/redis.conf index 0b84987..65bd382 100644 --- a/scripts/conf/redis.conf +++ b/scripts/conf/redis.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.tiny", - "instance_bigger_flavor_name": "test.tiny.resize", - "instance_eph_flavor_name": "test.eph.tiny", - "instance_bigger_eph_flavor_name": "test.eph.tiny.resize", + "instance_flavor_name": "test.tiny-3", + "instance_bigger_flavor_name": "test.tiny-3.resize", + "instance_eph_flavor_name": "test.eph.tiny-3", + "instance_bigger_eph_flavor_name": "test.eph.tiny-3.resize", "trove_volume_support": true, "trove_volume_size": 1, diff --git a/scripts/conf/vertica.conf b/scripts/conf/vertica.conf index 5c142a4..242d7fa 100644 --- a/scripts/conf/vertica.conf +++ b/scripts/conf/vertica.conf @@ -1,6 +1,6 @@ - "instance_flavor_name": "test.large", - "instance_bigger_flavor_name": "test.large.resize", - "instance_eph_flavor_name": "test.eph.large", - "instance_bigger_eph_flavor_name": "test.eph.large.resize", + "instance_flavor_name": "test.large-10", + "instance_bigger_flavor_name": "test.large-10.resize", + "instance_eph_flavor_name": "test.eph.large-10", + "instance_bigger_eph_flavor_name": "test.eph.large-10.resize", "trove_volume_support": true, "trove_volume_size": 5, diff --git a/scripts/redstack b/scripts/redstack index b26b5e5..ce66058 100755 --- a/scripts/redstack +++ b/scripts/redstack @@ -201,26 +201,43 @@ function add_flavor() { FLAVOR_MEMORY_MB=$3 FLAVOR_ROOT_GB=$4 FLAVOR_VCPUS=$5 - FLAVOR_EPHEMERAL=$6 credentials="--os-username=admin --os-password=$ADMIN_PASSWORD --os-tenant-name=admin --os-auth-url=$TROVE_AUTH_ENDPOINT" - resize_name=${FLAVOR_NAME}.resize - for name in ${FLAVOR_NAME} ${resize_name}; do - id=${FLAVOR_ID} - memory=${FLAVOR_MEMORY_MB} - vcpus=${FLAVOR_VCPUS} - if [[ $name == ${resize_name} ]]; then - id=${FLAVOR_ID}r - if [[ $BRANCH_OVERRIDE == "stable/juno" || $BRANCH_OVERRIDE == "stable/kilo" ]]; then - id=1${FLAVOR_ID} - fi - memory=$((${FLAVOR_MEMORY_MB} + 16)) - vcpus=$((${FLAVOR_VCPUS} + 1)) - fi - if [[ -z $(nova $credentials flavor-list | grep "| $name[ ]* |") ]]; then - nova $credentials flavor-create $name $id $memory $FLAVOR_ROOT_GB $vcpus --ephemeral $FLAVOR_EPHEMERAL + base_id=${FLAVOR_ID} + base_name_prefix=test + ephemeral_name_prefix=${base_name_prefix}.eph + for name_prefix in $base_name_prefix $ephemeral_name_prefix; do + reg_name=${name_prefix}.${FLAVOR_NAME}-${FLAVOR_ROOT_GB} + resize_name=${reg_name}.resize + ephemeral=0 + if [[ $name_prefix == $ephemeral_name_prefix ]]; then + ephemeral=1 fi + for name in ${reg_name} ${resize_name}; do + id=$base_id + memory=${FLAVOR_MEMORY_MB} + vcpus=${FLAVOR_VCPUS} + if [[ $ephemeral != 0 ]]; then + if [[ $BRANCH_OVERRIDE == "stable/juno" || $BRANCH_OVERRIDE == "stable/kilo" ]]; then + id=1${id} + else + id=${id}e + fi + fi + if [[ $name == ${resize_name} ]]; then + if [[ $BRANCH_OVERRIDE == "stable/juno" || $BRANCH_OVERRIDE == "stable/kilo" ]]; then + id=2${id} + else + id=${id}r + fi + memory=$((${FLAVOR_MEMORY_MB} + 16)) + vcpus=$((${FLAVOR_VCPUS} + 1)) + fi + if [[ -z $(nova $credentials flavor-list | grep "| $name[ ]* |") ]]; then + nova $credentials flavor-create $name $id $memory $FLAVOR_ROOT_GB $vcpus --ephemeral $ephemeral + fi + done done } @@ -728,16 +745,21 @@ function setup_cluster_configs() { # Add useful flavors for testing (with corresponding *.resize flavors) function add_test_flavors() { - # name id ram root_vol vcpu eph_vol + # name id ram root_vol vcpu # the ram and vcpu for name.resize are automatically calculated - add_flavor 'test.tiny' 10 512 3 1 0 - add_flavor 'test.eph.tiny' 11 512 3 1 1 - add_flavor 'test.small' 12 768 3 1 0 - add_flavor 'test.eph.small' 13 768 3 1 1 - add_flavor 'test.medium' 14 1024 4 1 0 - add_flavor 'test.eph.medium' 15 1024 4 1 1 - add_flavor 'test.large' 16 2048 5 1 0 - add_flavor 'test.eph.large' 17 2048 5 1 1 + # eph and non-eph flavors are created for each entry + add_flavor 'tiny' 10 512 3 1 + + add_flavor 'small' 15 768 3 1 + add_flavor 'small' 16 768 4 1 + add_flavor 'small' 17 768 5 1 + + add_flavor 'medium' 20 1024 4 1 + add_flavor 'medium' 21 1024 5 1 + + add_flavor 'large' 25 2048 5 1 + add_flavor 'large' 26 2048 10 1 + add_flavor 'large' 27 2048 15 1 } function cmd_test_init() { |