Splits pillowfight into separate (referable) YAML file, rebases on master
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/fbb86438 Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/fbb86438 Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/fbb86438 Branch: refs/heads/master Commit: fbb86438a19a693de25244d09bfe066e00d571c9 Parents: f2d05ff Author: Martin Harris <[email protected]> Authored: Mon Aug 18 15:40:05 2014 +0100 Committer: Martin Harris <[email protected]> Committed: Mon Aug 18 15:40:05 2014 +0100 ---------------------------------------------------------------------- .../launcher/src/test/resources/couchbase.yaml | 74 +--------------- .../src/test/resources/pillowfight.yaml | 91 ++++++++++++++++++++ 2 files changed, 93 insertions(+), 72 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/fbb86438/usage/launcher/src/test/resources/couchbase.yaml ---------------------------------------------------------------------- diff --git a/usage/launcher/src/test/resources/couchbase.yaml b/usage/launcher/src/test/resources/couchbase.yaml index f22d4f5..d2ae0ed 100644 --- a/usage/launcher/src/test/resources/couchbase.yaml +++ b/usage/launcher/src/test/resources/couchbase.yaml @@ -18,82 +18,12 @@ # name: Couchbase -location: aws-ec2:eu-west-1 +location: softlayer:ams01 services: - type: brooklyn.entity.nosql.couchbase.CouchbaseCluster adminUsername: Administrator adminPassword: Password initialSize: 3 -- type: brooklyn.entity.basic.VanillaSoftwareProcess - name: CBC Pillowfight - checkRunning.command: "" - stop.command: "" - launch.command: | - sudo wget -O/etc/apt/sources.list.d/couchbase.list http://packages.couchbase.com/ubuntu/couchbase-ubuntu1204.list - sudo wget -O- http://packages.couchbase.com/ubuntu/couchbase.key | sudo apt-key add - - sudo apt-get update - sudo apt-get install -y libcouchbase2-libevent libcouchbase-dev libcouchbase2-bin - brooklyn.initializers: - - type: brooklyn.entity.software.ssh.SshCommandEffector - brooklyn.config: - name: cbcPillowFight - description: runs cbc pillowfight - command: > - cbc pillowfight - `if [ -n "$host" ]; then echo -h $host; fi` - `if [ -n "$bucket" ]; then echo -b $bucket; fi` - `if [ -n "$username" ]; then echo -u $username; fi` - `if [ -n "$password" ]; then echo -p $password; fi` - `if [ -n "$iterations" ]; then echo -i $iterations; fi` - `if [ -n "$numItems" ]; then echo -I $numItems; fi` - `if [ -n "$keyPrefix" ]; then echo -p $keyPrefix; fi` - `if [ -n "$numThreads" ]; then echo -t $numThreads; fi` - `if [ -n "$numInstances" ]; then echo -Q $numInstances; fi` - `if [ -n "$randomSeed" ]; then echo -s $randomSeed; fi` - `if [ -n "$minSize" ]; then echo -m $minSize; fi` - `if [ -n "$maxSize" ]; then echo -M $maxSize; fi` - parameters: - host: - description: list of hosts to connect to - defaultValue: 127.0.0.1:8091 - bucket: - description: bucket to use - defaultValue: default - username: - description: username used for authentication to the cluster - password: - description: password used for authentication to the cluster - iterations: - description: number of iterations to run - defaultValue: 1000 - numItems: - description: number of items to operate on - defaultValue: 1000 - keyPrefix: - description: prefix for keys - numThreads: - description: number of threads to use - defaultValue: 1 - numInstances: - description: number of connection instances to put into the shared connection pool - defaultValue: 1 - randomSeed: - description: random seed - defaultValue: 0 - ratio: - description: "specify SET/GET command ratio (default: 33, i.e. 33% SETs and 67% GETs)" - defaultValue: 33 - minSize: - description: minimum size of payload, i.e. document body - defaultValue: 50 - maxSize: - description: maximum size of payload, i.e. document body - defaultValue: 5120 -# For CentOS, use the following launch command: -# launch.command: | -# sudo wget -O/etc/yum.repos.d/couchbase.repo http://packages.couchbase.com/rpm/couchbase-centos55-x86_64.repo -# sudo yum check-update -# sudo yum install -y libcouchbase2-libevent libcouchbase-devel libcouchbase2-bin - +- type: "classpath://pillowfight.yaml" http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/fbb86438/usage/launcher/src/test/resources/pillowfight.yaml ---------------------------------------------------------------------- diff --git a/usage/launcher/src/test/resources/pillowfight.yaml b/usage/launcher/src/test/resources/pillowfight.yaml new file mode 100644 index 0000000..9442725 --- /dev/null +++ b/usage/launcher/src/test/resources/pillowfight.yaml @@ -0,0 +1,91 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +services: +- type: brooklyn.entity.basic.VanillaSoftwareProcess + name: CBC Pillowfight + checkRunning.command: "" + stop.command: "" + launch.command: | + sudo wget -O/etc/apt/sources.list.d/couchbase.list http://packages.couchbase.com/ubuntu/couchbase-ubuntu1204.list + sudo wget -O- http://packages.couchbase.com/ubuntu/couchbase.key | sudo apt-key add - + sudo apt-get update + sudo apt-get install -y libcouchbase2-libevent libcouchbase-dev libcouchbase2-bin + brooklyn.initializers: + - type: brooklyn.entity.software.ssh.SshCommandEffector + brooklyn.config: + name: cbcPillowFight + description: runs cbc pillowfight + command: > + cbc pillowfight + `if [ -n "$host" ]; then echo -h $host; fi` + `if [ -n "$bucket" ]; then echo -b $bucket; fi` + `if [ -n "$username" ]; then echo -u $username; fi` + `if [ -n "$password" ]; then echo -p $password; fi` + `if [ -n "$iterations" ]; then echo -i $iterations; fi` + `if [ -n "$numItems" ]; then echo -I $numItems; fi` + `if [ -n "$keyPrefix" ]; then echo -p $keyPrefix; fi` + `if [ -n "$numThreads" ]; then echo -t $numThreads; fi` + `if [ -n "$numInstances" ]; then echo -Q $numInstances; fi` + `if [ -n "$randomSeed" ]; then echo -s $randomSeed; fi` + `if [ -n "$minSize" ]; then echo -m $minSize; fi` + `if [ -n "$maxSize" ]; then echo -M $maxSize; fi` + parameters: + host: + description: list of hosts to connect to + defaultValue: 127.0.0.1:8091 + bucket: + description: bucket to use + defaultValue: default + username: + description: username used for authentication to the cluster + password: + description: password used for authentication to the cluster + iterations: + description: number of iterations to run + defaultValue: 1000 + numItems: + description: number of items to operate on + defaultValue: 1000 + keyPrefix: + description: prefix for keys + numThreads: + description: number of threads to use + defaultValue: 1 + numInstances: + description: number of connection instances to put into the shared connection pool + defaultValue: 1 + randomSeed: + description: random seed + defaultValue: 0 + ratio: + description: "specify SET/GET command ratio (default: 33, i.e. 33% SETs and 67% GETs)" + defaultValue: 33 + minSize: + description: minimum size of payload, i.e. document body + defaultValue: 50 + maxSize: + description: maximum size of payload, i.e. document body + defaultValue: 5120 + +# For CentOS, use the following launch command: +# launch.command: | +# sudo wget -O/etc/yum.repos.d/couchbase.repo http://packages.couchbase.com/rpm/couchbase-centos55-x86_64.repo +# sudo yum check-update +# sudo yum install -y libcouchbase2-libevent libcouchbase-devel libcouchbase2-bin + \ No newline at end of file
