You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2014/07/25 18:45:38 UTC

[1/8] git commit: Deprecate JcloudsUtil unused methods

Repository: incubator-brooklyn
Updated Branches:
  refs/heads/master 1107f2f15 -> 2a4de4d72


Deprecate JcloudsUtil unused methods


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

Branch: refs/heads/master
Commit: f5eb35b323266f97bdc79d5b560fc861737ee875
Parents: b5ea764
Author: Aled Sage <al...@gmail.com>
Authored: Mon Jul 21 17:47:42 2014 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Tue Jul 22 12:37:04 2014 +0100

----------------------------------------------------------------------
 .../brooklyn/location/jclouds/JcloudsUtil.java     | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/f5eb35b3/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsUtil.java
----------------------------------------------------------------------
diff --git a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsUtil.java b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsUtil.java
index c0f6555..f3fdb34 100644
--- a/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsUtil.java
+++ b/locations/jclouds/src/main/java/brooklyn/location/jclouds/JcloudsUtil.java
@@ -77,6 +77,7 @@ import brooklyn.util.collections.MutableList;
 import brooklyn.util.collections.MutableMap;
 import brooklyn.util.config.ConfigBag;
 import brooklyn.util.net.Protocol;
+import brooklyn.util.ssh.BashCommands;
 import brooklyn.util.ssh.IptablesCommands;
 import brooklyn.util.ssh.IptablesCommands.Chain;
 import brooklyn.util.ssh.IptablesCommands.Policy;
@@ -154,6 +155,10 @@ public class JcloudsUtil implements JcloudsLocationConfig {
         }
     }
     
+    /**
+     * @deprecated since 0.7; {@see #installJavaAndCurl(OperatingSystem)}
+     */
+    @Deprecated
     public static final Statement APT_RUN_SCRIPT = newStatementList(//
           exec(installAfterUpdatingIfNotPresent("curl")),//
           exec("(which java && java -fullversion 2>&1|egrep -q 1.6 ) ||"),//
@@ -165,6 +170,10 @@ public class JcloudsUtil implements JcloudsLocationConfig {
                 .append("echo \"export PATH=\\\"$JAVA_HOME/bin/:$PATH\\\"\" >> /root/.bashrc")//
                 .toString()));
 
+    /**
+     * @deprecated since 0.7; {@see #installJavaAndCurl(OperatingSystem)}
+     */
+    @Deprecated
     public static final Statement YUM_RUN_SCRIPT = newStatementList(
           exec("which curl ||yum --nogpgcheck -y install curl"),//
           exec("(which java && java -fullversion 2>&1|egrep -q 1.6 ) ||"),//
@@ -174,6 +183,10 @@ public class JcloudsUtil implements JcloudsLocationConfig {
                 .append("echo \"export PATH=\\\"$JAVA_HOME/bin/:$PATH\\\"\" >> /root/.bashrc")//
                 .toString()));
 
+    /**
+     * @deprecated since 0.7; {@see #installJavaAndCurl(OperatingSystem)}
+     */
+    @Deprecated
     public static final Statement ZYPPER_RUN_SCRIPT = exec(new StringBuilder()//
           .append("echo nameserver 208.67.222.222 >> /etc/resolv.conf\n")//
           .append("which curl || zypper install curl\n")//
@@ -181,6 +194,10 @@ public class JcloudsUtil implements JcloudsLocationConfig {
           .toString());
 
     // Code taken from RunScriptData
+    /**
+     * @deprecated since 0.7; see {@link BashCommands#installJava7()} and {@link BashCommands#INSTALL_CURL}
+     */
+    @Deprecated
     public static Statement installJavaAndCurl(OperatingSystem os) {
        if (os == null || OperatingSystemPredicates.supportsApt().apply(os))
           return APT_RUN_SCRIPT;


[5/8] git commit: Deleted whirr/hadoop

Posted by he...@apache.org.
Deleted whirr/hadoop

- moving code out of core, into separate repo


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

Branch: refs/heads/master
Commit: 0388875583d7039ccdc70ecb10cd94ca84c120e0
Parents: f5eb35b
Author: Aled Sage <al...@gmail.com>
Authored: Tue Jul 22 12:30:41 2014 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Tue Jul 22 12:37:05 2014 +0100

----------------------------------------------------------------------
 examples/hadoop-and-whirr/.gitignore            |   2 -
 examples/hadoop-and-whirr/README.txt            |  51 ----
 examples/hadoop-and-whirr/pom.xml               |  97 -------
 .../main/java/brooklyn/extras/whirr/ReadMe.java |  28 --
 .../whirr/WebClusterWithHadoopExample.java      | 208 --------------
 .../whirr/WebFabricWithHadoopExample.java       | 278 -------------------
 .../brooklyn/extras/whirr/WhirrExample.java     |  71 -----
 .../extras/whirr/WhirrHadoopExample.java        |  68 -----
 examples/pom.xml                                |   1 -
 examples/simple-open-loop-policy/pom.xml        |  11 -
 examples/simple-web-cluster/pom.xml             |  11 -
 examples/webapps/hello-world-hadoop-jar/pom.xml |  60 ----
 .../brooklyn/demo/webapp/hello/DemoUtils.java   |  48 ----
 .../demo/webapp/hello/HadoopWordCount.java      | 165 -----------
 examples/webapps/hello-world-hadoop/pom.xml     |  89 ------
 .../hello/SerializeHelloWorldHadoopJar.java     |  82 ------
 .../src/main/webapp/WEB-INF/web.xml             |  26 --
 .../src/main/webapp/available.jsp               |  73 -----
 .../src/main/webapp/configure.jsp               | 122 --------
 .../hello-world-hadoop/src/main/webapp/db.jsp   | 123 --------
 .../src/main/webapp/hadoop-chat.jsp             | 112 --------
 .../src/main/webapp/hadoop-wordcount.jsp        | 121 --------
 .../src/main/webapp/images/bridge-small.png     | Bin 42335 -> 0 bytes
 .../src/main/webapp/index.html                  |  45 ---
 examples/webapps/pom.xml                        |   2 -
 pom.xml                                         |   3 -
 systems/whirr/base/pom.xml                      | 177 ------------
 .../extras/whirr/core/WhirrCluster.java         |  70 -----
 .../extras/whirr/core/WhirrClusterImpl.java     | 249 -----------------
 .../extras/whirr/core/WhirrInstance.java        |  46 ---
 .../extras/whirr/core/WhirrInstanceImpl.java    |  65 -----
 .../brooklyn/extras/whirr/core/WhirrRole.java   |  34 ---
 .../extras/whirr/core/WhirrRoleImpl.java        |  29 --
 .../extras/whirr/core/WhirrClusterTest.java     |  52 ----
 systems/whirr/hadoop/pom.xml                    |  62 -----
 .../extras/whirr/hadoop/WhirrHadoopCluster.java |  63 -----
 .../whirr/hadoop/WhirrHadoopClusterImpl.java    | 135 ---------
 .../hadoop/WhirrHadoopClusterLiveTest.java      |  74 -----
 .../whirr/hadoop/WhirrHadoopClusterTest.java    |  66 -----
 usage/all/pom.xml                               |  10 -
 40 files changed, 3029 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/.gitignore
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/.gitignore b/examples/hadoop-and-whirr/.gitignore
deleted file mode 100644
index 8e27592..0000000
--- a/examples/hadoop-and-whirr/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-brooklyn-example-hadoop-and-whirr/
-brooklyn-example-hadoop-and-whirr.tar.gz
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/README.txt
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/README.txt b/examples/hadoop-and-whirr/README.txt
deleted file mode 100644
index abdb166..0000000
--- a/examples/hadoop-and-whirr/README.txt
+++ /dev/null
@@ -1,51 +0,0 @@
-Instructions for running examples
-=================================
-
-The commands below assume that the `brooklyn` script is already on your $PATH, and you are in the "examples" directory:
-
-  cd hadoop-and-whirr
-  export BROOKLYN_CLASSPATH=$(pwd)/target/classes
-  
-  # Runs hadoop in aws-ec2 us-east-1
-  brooklyn launch --app brooklyn.extras.whirr.WhirrHadoopExample --stopOnKeyPress --location aws-ec2:us-east-1
-  
-  # Runs whirr with a custom recipe in aws-ec2 us-east-1
-  brooklyn launch --app brooklyn.extras.whirr.WhirrExample --stopOnKeyPress --location aws-ec2:us-east-1
-
-  # Runs a web-cluster along with hadoop in aws-ec2, region us-east-1
-  brooklyn launch --app brooklyn.extras.whirr.WebClusterWithHadoopExample --location aws-ec2:us-east-1
-
-  # Runs web-clusters in eu-west-1 and us-east-1, along with hadoop
-  brooklyn -v launch --app brooklyn.extras.whirr.WebFabricWithHadoopExample --stopOnKeyPress --location "aws-ec2:eu-west-1,aws-ec2:us-east-1"
-
----
-
-The aws-ec2 credentials are retrieved from ~/.brooklyn/brooklyn.properties
-
-This file should contain something like:
-  brooklyn.jclouds.aws-ec2.identity=AKA50M30N3S1DFR0MAW55
-  brooklyn.jclouds.aws-ec2.credential=aT0Ps3cr3tC0D3wh1chAW5w1llG1V3y0uTOus333
-
-Brooklyn defaults to using ~/.ssh/id_rsa and ~/.ssh/id_rsa.pub
-
----
-
-For more information, please visit: http://brooklyncentral.github.com/use/examples/whirrhadoop/
-
-----
-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.
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/pom.xml
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/pom.xml b/examples/hadoop-and-whirr/pom.xml
deleted file mode 100644
index eaa03bb..0000000
--- a/examples/hadoop-and-whirr/pom.xml
+++ /dev/null
@@ -1,97 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-    <packaging>jar</packaging>
-    <artifactId>brooklyn-example-hadoop-and-whirr</artifactId>
-    <name>Brooklyn Hadoop and Whirr Example</name>
-
-    <parent>
-        <groupId>io.brooklyn.example</groupId>
-        <artifactId>brooklyn-examples-parent</artifactId>
-        <version>0.7.0-SNAPSHOT</version>   <!-- BROOKLYN_VERSION -->
-        <relativePath>../pom.xml</relativePath>
-    </parent>
-
-    <dependencies>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-all</artifactId>
-            <version>${project.version}</version>
-            <classifier>with-dependencies</classifier>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.whirr</groupId>
-            <artifactId>whirr-elasticsearch</artifactId>
-            <version>${whirr.version}</version>
-        </dependency>
-    </dependencies>
-
-    <build>
-        <plugins>
-            <plugin>
-                <artifactId>maven-dependency-plugin</artifactId>
-                <!-- copy the WAR so it is available on the classpath for programmatic deployment -->
-                <executions>
-                    <execution>
-                        <id>copy</id>
-                        <phase>process-classes</phase>
-                        <goals>
-                            <goal>copy</goal>
-                        </goals>
-                        <configuration>
-                            <artifactItems>
-                                <!-- these can fail in eclipse trying to copy _from_ target/classes.
-                                         see http://jira.codehaus.org/browse/MDEP-259 -->
-                                <artifactItem>
-                                    <groupId>${project.groupId}</groupId>
-                                    <artifactId>brooklyn-example-hello-world-hadoop-webapp</artifactId>
-                                    <version>${project.version}</version>
-                                    <type>war</type>
-                                    <overWrite>true</overWrite>
-                                    <outputDirectory>target/classes</outputDirectory>
-                                    <destFileName>hello-world-hadoop-webapp.war</destFileName>
-                                </artifactItem>
-                            </artifactItems>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
-            <plugin>
-                <artifactId>maven-clean-plugin</artifactId>
-                <configuration>
-                    <filesets>
-                        <fileset>
-                            <directory>${project.basedir}</directory>
-							<includes>
-                                <include>${project.artifactId}/</include>
-                                <include>brooklyn*.log</include>
-                                <include>brooklyn*.log.*</include>
-                                <include>stacktrace.log</include>
-                            </includes>
-                        </fileset>
-                    </filesets>
-                </configuration>
-            </plugin>            
-        </plugins>
-    </build>
-    
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/ReadMe.java
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/ReadMe.java b/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/ReadMe.java
deleted file mode 100644
index 18ee564..0000000
--- a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/ReadMe.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr;
-
-public class ReadMe {
-
-/* This class exists only so that javadoc is generated and artifacts can be staged at sonatype for deployment to maven central.
- * See: https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide
- *
- * (The actual examples are in other classes in this package / project.) */
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebClusterWithHadoopExample.java
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebClusterWithHadoopExample.java b/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebClusterWithHadoopExample.java
deleted file mode 100644
index f8bf618..0000000
--- a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebClusterWithHadoopExample.java
+++ /dev/null
@@ -1,208 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URI;
-import java.net.URLEncoder;
-import java.util.Collection;
-import java.util.List;
-import java.util.Set;
-
-import org.apache.http.impl.client.DefaultHttpClient;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.config.StringConfigMap;
-import brooklyn.entity.Entity;
-import brooklyn.entity.Group;
-import brooklyn.entity.basic.AbstractApplication;
-import brooklyn.entity.basic.DynamicGroup;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.basic.StartableApplication;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.entity.trait.Startable;
-import brooklyn.entity.webapp.ControlledDynamicWebAppCluster;
-import brooklyn.entity.webapp.DynamicWebAppCluster;
-import brooklyn.entity.webapp.jboss.JBoss7Server;
-import brooklyn.event.SensorEvent;
-import brooklyn.event.SensorEventListener;
-import brooklyn.extras.whirr.hadoop.WhirrHadoopCluster;
-import brooklyn.launcher.BrooklynLauncher;
-import brooklyn.location.Location;
-import brooklyn.policy.autoscaling.AutoScalerPolicy;
-import brooklyn.policy.basic.AbstractPolicy;
-import brooklyn.util.CommandLineUtil;
-import brooklyn.util.exceptions.Exceptions;
-import brooklyn.util.http.HttpTool;
-import brooklyn.util.http.HttpToolResponse;
-
-import com.google.common.base.Charsets;
-import com.google.common.base.Joiner;
-import com.google.common.base.Predicates;
-import com.google.common.collect.ImmutableList;
-import com.google.common.collect.ImmutableMap;
-import com.google.common.collect.Iterables;
-import com.google.common.collect.Lists;
-import com.google.common.collect.Sets;
-import com.google.common.io.Files;
-
-/**
- * Starts hadoop and a webapp using hadoop in the location supplied (just one location),
- * configuring the webapp to connect to hadoop
- */
-public class WebClusterWithHadoopExample extends AbstractApplication implements StartableApplication {
-
-    private static final Logger log = LoggerFactory.getLogger(WebClusterWithHadoopExample.class);
-
-    static final List<String> DEFAULT_LOCATIONS = ImmutableList.of(
-        // note the 1d: we need our machines to be in the same availability zone 
-        // so they can see each other on the internal IPs (where hadoop binds)
-        // (cross-site magic is shown in the hadoop fabric example)
-        // ((also note some availability zones don't work, that's amazon for you...))
-        // most other clouds "just work" :)
-        "aws-ec2:us-east-1c");
-
-    public static final String WAR_PATH = "classpath://hello-world-hadoop-webapp.war";
-    
-    private WhirrHadoopCluster hadoopCluster;
-    private ControlledDynamicWebAppCluster webCluster;
-    private DynamicGroup webVms;
-    
-    public WebClusterWithHadoopExample() {
-    }
-    
-    @Override
-    public void init() {
-        StringConfigMap config = getManagementContext().getConfig();
-    
-        hadoopCluster = addChild(EntitySpec.create(WhirrHadoopCluster.class)
-                .configure("size", 2)
-                .configure("memory", 2048)
-                .configure("name", "Whirr Hadoop Cluster"));
-
-        // TODO Can't just set RECIPE config in spec, because that overwrites defaults in WhirrHadoopCluster!
-        // specify hadoop version (1.0.2 has a nice, smaller hadoop client jar)
-        hadoopCluster.addRecipeLine("whirr.hadoop.version=1.0.2"); 
-        // for this example we'll allow access from anywhere
-        hadoopCluster.addRecipeLine("whirr.client-cidrs=0.0.0.0/0");
-        hadoopCluster.addRecipeLine("whirr.firewall-rules=8020,8021,50010");
-    
-        webCluster = addChild(EntitySpec.create(ControlledDynamicWebAppCluster.class)
-                .configure("war", WAR_PATH)
-                .policy(AutoScalerPolicy.builder()
-                        .metric(DynamicWebAppCluster.REQUESTS_PER_SECOND_LAST_PER_NODE)
-                        .sizeRange(1, 5)
-                        .metricRange(10, 100)
-                        .build()));
-        
-        webVms = addChild(EntitySpec.create(DynamicGroup.class)
-                .displayName("Web VMs")
-                .configure(DynamicGroup.ENTITY_FILTER, Predicates.instanceOf(JBoss7Server.class)));
-    }
-    
-    @Override
-    public void start(Collection<? extends Location> locations) {
-        Iterables.getOnlyElement(locations);
-        log.debug("starting "+this);
-        super.start(locations);
-        
-        // start the web cluster, and hadoop cluster, in the single location (above)
-        // then register a policy to configure the appservers to use hadoop
-        log.debug("started "+this+", now starting policy");
-        PrepVmsForHadoop.newPolicyFromGroupToHadoop(webVms, hadoopCluster);
-    }
-    
-    public static class PrepVmsForHadoop extends AbstractPolicy {
-        WhirrHadoopCluster hadoopCluster;
-        String hadoopSiteXmlContents;
-        Set<String> configuredIds = Sets.newLinkedHashSet();
-        
-        public PrepVmsForHadoop(WhirrHadoopCluster hadoopCluster) {
-            this.hadoopCluster = hadoopCluster;
-        }
-        
-        public void start() {
-            //read the contents, and disable socks proxy since we're in the same cluster
-            try {
-                File hadoopSiteXmlFile = new File(System.getProperty("user.home")+"/.whirr/"+
-                        hadoopCluster.getClusterSpec().getClusterName()+"/hadoop-site.xml");
-                hadoopSiteXmlContents = Files.toString(hadoopSiteXmlFile, Charsets.UTF_8);
-                hadoopSiteXmlContents = hadoopSiteXmlContents.replaceAll("<\\?xml.*\\?>\\s*", "");
-                hadoopSiteXmlContents = hadoopSiteXmlContents.replaceAll("hadoop.socks.server", "ignore.hadoop.socks.server");
-                
-                subscribeToMembers((Group)entity, Startable.SERVICE_UP, new SensorEventListener<Boolean>() {
-                    @Override public void onEvent(SensorEvent<Boolean> event) {
-                        log.debug("hadoop set up policy recieved {}", event);
-                        if (event.getValue() != null && !configuredIds.contains(event.getSource().getId())) 
-                            setupMachine(event.getSource());
-                    }});
-            } catch (IOException e) {
-                throw Exceptions.propagate(e);
-            }
-        }
-        
-        public void setupMachine(Entity e) {
-            try {
-                if (!e.getAttribute(Startable.SERVICE_UP)) return;
-                if (!configuredIds.add(e.getId())) return;
-                if (log.isDebugEnabled()) log.debug("setting up machine for hadoop at {}", e);
-
-                URI updateConfigUri = new URI(e.getAttribute(JBoss7Server.ROOT_URL)+
-                        "configure.jsp?"+
-                        "key=brooklyn.example.hadoop.site.xml.contents"+"&"+
-                        "value="+URLEncoder.encode(hadoopSiteXmlContents));
-                
-                HttpToolResponse result = HttpTool.httpGet(new DefaultHttpClient(), updateConfigUri, ImmutableMap.<String,String>of());
-                if (log.isDebugEnabled()) log.debug("http config update for {} got: {}, {}", new Object[] {e, result.getResponseCode(), new String(result.getContent())});
-            } catch (Exception err) {
-                log.warn("unable to configure "+e+" for hadoop", err);
-                configuredIds.remove(e.getId());
-            }
-        }
-        
-        public static PrepVmsForHadoop newPolicyFromGroupToHadoop(DynamicGroup target, WhirrHadoopCluster hadoopCluster) {
-            log.debug("creating policy for hadoop clusters target {} hadoop ", target, hadoopCluster);
-            PrepVmsForHadoop prepVmsForHadoop = new PrepVmsForHadoop(hadoopCluster);
-            target.addPolicy(prepVmsForHadoop);
-            prepVmsForHadoop.start();
-            log.debug("running policy over existing members {}", target.getMembers());
-            for (Entity member : target.getMembers()) {
-                prepVmsForHadoop.setupMachine(member);
-            }
-            return prepVmsForHadoop;
-        }
-    }
-        
-    public static void main(String[] argv) {
-        List<String> args = Lists.newArrayList(argv);
-        String port =  CommandLineUtil.getCommandLineOption(args, "--port", "8081+");
-        String location = CommandLineUtil.getCommandLineOption(args, "--location", Joiner.on(",").join(DEFAULT_LOCATIONS));
-
-        BrooklynLauncher launcher = BrooklynLauncher.newInstance()
-                .application(EntitySpec.create(StartableApplication.class, WebClusterWithHadoopExample.class)
-                        .displayName("Brooklyn Global Web Fabric with Hadoop Example"))
-                .webconsolePort(port)
-                .location(location)
-                .start();
-         
-        Entities.dumpInfo(launcher.getApplications());
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebFabricWithHadoopExample.java
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebFabricWithHadoopExample.java b/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebFabricWithHadoopExample.java
deleted file mode 100644
index aaf6350..0000000
--- a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WebFabricWithHadoopExample.java
+++ /dev/null
@@ -1,278 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.io.File;
-import java.io.StringReader;
-import java.net.InetAddress;
-import java.net.URI;
-import java.util.Collection;
-import java.util.List;
-import java.util.Set;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-import org.apache.http.impl.client.DefaultHttpClient;
-import org.apache.whirr.service.hadoop.HadoopCluster;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.config.StringConfigMap;
-import brooklyn.entity.Entity;
-import brooklyn.entity.Group;
-import brooklyn.entity.basic.AbstractApplication;
-import brooklyn.entity.basic.DynamicGroup;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.basic.StartableApplication;
-import brooklyn.entity.dns.geoscaling.GeoscalingDnsService;
-import brooklyn.entity.group.DynamicFabric;
-import brooklyn.entity.proxy.AbstractController;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.entity.trait.Startable;
-import brooklyn.entity.webapp.ElasticJavaWebAppService;
-import brooklyn.entity.webapp.jboss.JBoss7Server;
-import brooklyn.event.SensorEvent;
-import brooklyn.event.SensorEventListener;
-import brooklyn.extras.whirr.hadoop.WhirrHadoopCluster;
-import brooklyn.launcher.BrooklynLauncher;
-import brooklyn.location.Location;
-import brooklyn.location.basic.PortRanges;
-import brooklyn.location.basic.SshMachineLocation;
-import brooklyn.management.Task;
-import brooklyn.policy.basic.AbstractPolicy;
-import brooklyn.util.CommandLineUtil;
-import brooklyn.util.http.HttpTool;
-import brooklyn.util.http.HttpToolResponse;
-import brooklyn.util.task.ParallelTask;
-
-import com.google.common.base.Charsets;
-import com.google.common.base.Joiner;
-import com.google.common.base.Predicates;
-import com.google.common.collect.ImmutableList;
-import com.google.common.collect.ImmutableMap;
-import com.google.common.collect.Iterables;
-import com.google.common.collect.Lists;
-import com.google.common.collect.Sets;
-import com.google.common.io.Files;
-
-/**
- * Starts hadoop in the first location supplied, and the hadoop-friendly webapp in all other locations.
- * Webapp get configured via the configure.jsp page, plus supplying the proxy command, to connect to hadoop.
- */
-public class WebFabricWithHadoopExample extends AbstractApplication implements StartableApplication {
-
-    private static final Logger log = LoggerFactory.getLogger(WebFabricWithHadoopExample.class);
-
-    static final List<String> DEFAULT_LOCATIONS = ImmutableList.of(
-        // hadoop location
-        "aws-ec2:eu-west-1",
-          
-        //web locations
-        "aws-ec2:eu-west-1",
-        "aws-ec2:ap-southeast-1",
-        "aws-ec2:us-west-1");
-
-    public static final String WAR_PATH = "classpath://hello-world-hadoop-webapp.war";
-    
-    private WhirrHadoopCluster hadoopCluster;
-    private GeoscalingDnsService geoDns;
-    private DynamicFabric webFabric;
-    private DynamicGroup webVms;
-    
-    public WebFabricWithHadoopExample() {
-    }
-    
-    @Override
-    public void init() {
-        StringConfigMap config = getManagementContext().getConfig();
-        
-        hadoopCluster = addChild(EntitySpec.create(WhirrHadoopCluster.class)
-                .configure("size", 2)
-                .configure("memory", 2048)
-                .configure("name", "Whirr Hadoop Cluster"));
-        
-        // TODO Can't just set RECIPE config in spec, because that overwrites defaults in WhirrHadoopCluster!
-        // specify hadoop version (1.0.2 has a nice, smaller hadoop client jar)
-        hadoopCluster.addRecipeLine("whirr.hadoop.version=1.0.2");
-    
-        GeoscalingDnsService geoDns = addChild(EntitySpec.create(GeoscalingDnsService.class)
-                .displayName("GeoScaling DNS")
-                .configure("username", checkNotNull(config.getFirst("brooklyn.geoscaling.username"), "username"))
-                .configure("password", checkNotNull(config.getFirst("brooklyn.geoscaling.password"), "password"))
-                .configure("primaryDomainName", checkNotNull(config.getFirst("brooklyn.geoscaling.primaryDomain"), "primaryDomain"))
-                .configure("smartSubdomainName", "brooklyn"));
-        
-        webFabric = addChild(EntitySpec.create(DynamicFabric.class)
-                .displayName("Web Fabric")
-                .configure("factory", new ElasticJavaWebAppService.Factory())
-                //specify the WAR file to use
-                .configure(ElasticJavaWebAppService.ROOT_WAR, WAR_PATH)
-                //load-balancer instances must run on 80 to work with GeoDNS (default is 8000)
-                .configure(AbstractController.PROXY_HTTP_PORT, PortRanges.fromInteger(80))
-                );
-//                .policy(AutoScalerPolicy.builder()
-//                        .metric(DynamicWebAppCluster.AVERAGE_REQUESTS_PER_SECOND)
-//                        .sizeRange(1, 5)
-//                        .metricRange(10, 100)
-//                        .build()));
-        
-        webVms = addChild(EntitySpec.create(DynamicGroup.class)
-                .displayName("Web VMs")
-                .configure(DynamicGroup.ENTITY_FILTER, Predicates.instanceOf(JBoss7Server.class)));
-        
-        //tell GeoDNS what to monitor
-        geoDns.setTargetEntityProvider(webFabric);
-    }
-    
-    @Override
-    public void start(Collection<? extends Location> locations) {
-        if (locations.isEmpty()) throw new IllegalStateException("location required to start "+this);
-        final Location hadoopLocation = Iterables.getFirst(locations, null);
-        // start hadoop in first, web in others (unless there is just one location supplied)
-        final List<Location> webLocations = (locations.size() > 1) ? ImmutableList.copyOf(Iterables.skip(locations, 1)) : ImmutableList.of(hadoopLocation);
-
-        Task<List<?>> starts = getExecutionContext().submit(new ParallelTask(
-                new Runnable() {
-                    public void run() {
-                        webFabric.start(webLocations);
-                    }
-                },
-                new Runnable() {
-                    public void run() {
-                        hadoopCluster.start(ImmutableList.of(hadoopLocation)); 
-                        // collect the hadoop-site.xml and feed it to all existing and new appservers,
-                        // and start the proxies there
-                        PrepVmsForHadoop.newPolicyFromGroupToHadoop(webVms, hadoopCluster);
-                    }
-                }));
-        starts.blockUntilEnded();
-    }    
-    
-    public static class PrepVmsForHadoop extends AbstractPolicy {
-        WhirrHadoopCluster hadoopCluster;
-        Set<String> configuredIds = Sets.newLinkedHashSet();
-        
-        public PrepVmsForHadoop(WhirrHadoopCluster hadoopCluster) {
-            this.hadoopCluster = hadoopCluster;
-        }
-        
-        public static PrepVmsForHadoop newPolicyFromGroupToHadoop(DynamicGroup target, WhirrHadoopCluster hadoopCluster) {
-            log.debug("creating policy for hadoop clusters target {} hadoop ", target, hadoopCluster);
-            PrepVmsForHadoop prepVmsForHadoop = new PrepVmsForHadoop(hadoopCluster);
-            target.addPolicy(prepVmsForHadoop);
-            prepVmsForHadoop.start();
-            log.debug("running policy over existing members {}", target.getMembers());
-            for (Entity member : target.getMembers()) {
-                prepVmsForHadoop.setupMachine(member);
-            }
-            return prepVmsForHadoop;
-        }
-        
-        public void start() {
-        	subscribeToMembers((Group)entity, Startable.SERVICE_UP, new SensorEventListener<Boolean>() {
-                // track if previously up, so only execute when transitions from false->true
-                private final AtomicBoolean up = new AtomicBoolean();
-                
-                @Override public void onEvent(SensorEvent<Boolean> event) {
-                    log.debug("hadoop set up policy recieved {}", event);
-                    if (Boolean.TRUE.equals(event.getValue()) && !up.get()) {
-                        up.set(true);
-                        setupMachine(event.getSource());
-                    }
-                }});
-        }
-        
-        public void setupMachine(Entity e) {
-            try {
-                if (log.isDebugEnabled()) log.debug("setting up machine for hadoop at {}", e);
-                if (!e.getAttribute(Startable.SERVICE_UP)) return;
-                if (!configuredIds.add(e.getId())) return;
-                SshMachineLocation ssh = (SshMachineLocation) Iterables.getOnlyElement(e.getLocations());
-                // TODO would prefer to extract content from HadoopNameNodeClusterActionHandler (but that class would need refactoring)
-                ssh.copyTo(new File(System.getProperty("user.home")+"/.whirr/"+hadoopCluster.getClusterSpec().getClusterName()+"/hadoop-site.xml"), "/tmp/hadoop-site.xml");
-
-                File identity = hadoopCluster.getClusterSpec().getPrivateKeyFile();
-                if (identity == null){
-                    identity = File.createTempFile("hadoop", "key");
-                    identity.deleteOnExit();
-                    Files.write(hadoopCluster.getClusterSpec().getPrivateKey(), identity, Charsets.UTF_8);
-                }
-                if (log.isDebugEnabled()) log.debug("http config update for {}, identity file: {}", e, identity);
-                ssh.copyTo(identity, "/tmp/hadoop-proxy-private-key");
-
-                //copied from HadoopProxy, would prefer to reference (but again refactoring there is needed) 
-                String user = hadoopCluster.getClusterSpec().getClusterUser();
-                InetAddress namenode = HadoopCluster.getNamenodePublicAddress(hadoopCluster.getCluster());
-                String server = namenode.getHostName();
-                // TODO: the `ssh -D` command keeps failing because of incorrect ssh key. Tested in "aws-ec2:us-west-2", AMI ubuntu-saucy-13.10-i386-server-20131015 (ami-aae67f9a)
-                String proxyCommand = Joiner.on(" ").join(ImmutableList.of(
-                        "ssh",
-                        "-i", "/tmp/hadoop-proxy-private-key",
-                        "-o", "ConnectTimeout=10",
-                        "-o", "ServerAliveInterval=60",
-                        "-o", "StrictHostKeyChecking=no",
-                        "-o", "UserKnownHostsFile=/dev/null",
-                        "-o", "StrictHostKeyChecking=no",
-                        "-N",
-                        "-D 6666",
-                        String.format("%s@%s", user, server)));
-                if (log.isDebugEnabled()) log.debug("http config update for {}, proxy command: {}", e, proxyCommand);
-
-                String hadoopProxyForeverContent = 
-            		 "#!/bin/bash"+"\n"+ 
-                        "while [ true ] ; do"+"\n"+ 
-                        "    date"+"\n"+
-                        "    echo starting proxy for hadoop to "+String.format("%s@%s", user, server)+"\n"+
-                        "    nohup "+proxyCommand+"\n"+
-                        "    echo proxy ended"+"\n"+
-                        "done"+"\n";
-                
-                ssh.copyTo(new StringReader(hadoopProxyForeverContent), "/tmp/hadoop-proxy-forever.sh");
-                  
-                //  TODO: the `nohup hadoop-proxy-forever.sh &`  script is not returning. Tested in "aws-ec2:us-west-2", AMI ubuntu-saucy-13.10-i386-server-20131015 (ami-aae67f9a)
-                ssh.execCommands("chmod", ImmutableList.of("chmod 600 /tmp/hadoop-proxy-private-key", "chmod +x /tmp/hadoop-proxy-forever.sh", "nohup /tmp/hadoop-proxy-forever.sh < /dev/null &"));
-
-                URI updateConfigUri = new URI(e.getAttribute(JBoss7Server.ROOT_URL)+
-                        "configure.jsp?key=brooklyn.example.hadoop.site.xml.url&value=file:///tmp/hadoop-site.xml");
-                
-                HttpToolResponse result = HttpTool.httpGet(new DefaultHttpClient(), updateConfigUri, ImmutableMap.<String,String>of());
-                if (log.isDebugEnabled()) log.debug("http config update for {} got: {}, {}", new Object[] {e, result.getResponseCode(), new String(result.getContent())});
-            } catch (Exception err) {
-                log.warn("unable to configure "+e+" for hadoop", err);
-                configuredIds.remove(e.getId());
-            }
-        }
-    }
-    
-    public static void main(String[] argv) {
-        List<String> args = Lists.newArrayList(argv);
-        String port =  CommandLineUtil.getCommandLineOption(args, "--port", "8081+");
-        String location = CommandLineUtil.getCommandLineOption(args, "--location", Joiner.on(",").join(DEFAULT_LOCATIONS));
-
-        BrooklynLauncher launcher = BrooklynLauncher.newInstance()
-                .application(EntitySpec.create(StartableApplication.class, WebFabricWithHadoopExample.class)
-                        .displayName("Brooklyn Global Web Fabric with Hadoop Example"))
-                .webconsolePort(port)
-                .location(location)
-                .start();
-         
-        Entities.dumpInfo(launcher.getApplications());
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrExample.java
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrExample.java b/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrExample.java
deleted file mode 100644
index a04386d..0000000
--- a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrExample.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr;
-
-import java.util.List;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.entity.basic.AbstractApplication;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.basic.StartableApplication;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.extras.whirr.core.WhirrCluster;
-import brooklyn.launcher.BrooklynLauncher;
-import brooklyn.util.CommandLineUtil;
-
-import com.google.common.collect.Lists;
-
-public class WhirrExample extends AbstractApplication {
-
-    private static final Logger LOG = LoggerFactory.getLogger(WhirrExample.class);
-
-    public static final String DEFAULT_LOCATION = "aws-ec2:eu-west-1";
-
-    public static final String RECIPE =
-            "whirr.cluster-name=brooklyn-whirr"+"\n"+
-            "whirr.hardware-min-ram=1024"+"\n"+
-            "whirr.instance-templates=1 noop, 1 elasticsearch"+"\n";
-
-    @Override
-    public void init() {
-        addChild(EntitySpec.create(WhirrCluster.class)
-                .configure("recipe", RECIPE));
-    }
-
-    public static void main(String[] argv) throws Exception {
-        List<String> args = Lists.newArrayList(argv);
-        String port =  CommandLineUtil.getCommandLineOption(args, "--port", "8081+");
-        String location = CommandLineUtil.getCommandLineOption(args, "--location", DEFAULT_LOCATION);
-
-        BrooklynLauncher launcher = BrooklynLauncher.newInstance()
-                .application(EntitySpec.create(StartableApplication.class, WhirrExample.class))
-                .webconsolePort(port)
-                .location(location)
-                .start();
-         
-        StartableApplication app = (StartableApplication) launcher.getApplications().get(0);
-        Entities.dumpInfo(app);
-        
-        LOG.info("Press return to shut down the cluster");
-        System.in.read(); //wait for the user to type a key
-        app.stop();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrHadoopExample.java
----------------------------------------------------------------------
diff --git a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrHadoopExample.java b/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrHadoopExample.java
deleted file mode 100644
index 94d359c..0000000
--- a/examples/hadoop-and-whirr/src/main/java/brooklyn/extras/whirr/WhirrHadoopExample.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr;
-
-import java.util.List;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.entity.basic.AbstractApplication;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.basic.StartableApplication;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.extras.whirr.hadoop.WhirrHadoopCluster;
-import brooklyn.launcher.BrooklynLauncher;
-import brooklyn.util.CommandLineUtil;
-
-import com.google.common.collect.Lists;
-
-public class WhirrHadoopExample extends AbstractApplication {
-
-    private static final Logger LOG = LoggerFactory.getLogger(WhirrHadoopExample.class);
-
-    public static final String DEFAULT_LOCATION = "aws-ec2:eu-west-1";
-
-    @Override
-    public void init() {
-        addChild(EntitySpec.create(WhirrHadoopCluster.class)
-                .displayName("brooklyn-hadoop-example")
-                .configure("size", 2)
-                .configure("memory", 2048));
-    }
-
-    public static void main(String[] argv) throws Exception {
-        List<String> args = Lists.newArrayList(argv);
-        String port =  CommandLineUtil.getCommandLineOption(args, "--port", "8081+");
-        String location = CommandLineUtil.getCommandLineOption(args, "--location", DEFAULT_LOCATION);
-
-        BrooklynLauncher launcher = BrooklynLauncher.newInstance()
-                .application(EntitySpec.create(StartableApplication.class, WhirrHadoopExample.class))
-                .webconsolePort(port)
-                .location(location)
-                .start();
-         
-        StartableApplication app = (StartableApplication) launcher.getApplications().get(0);
-        Entities.dumpInfo(app);
-        
-        LOG.info("Press return to shut down the cluster");
-        System.in.read(); //wait for the user to type a key
-        app.stop();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/pom.xml
----------------------------------------------------------------------
diff --git a/examples/pom.xml b/examples/pom.xml
index 63c709c..23c8929 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -52,7 +52,6 @@
         <module>webapps</module>
         <module>simple-web-cluster</module>
         <module>global-web-fabric</module>
-        <module>hadoop-and-whirr</module>
         <module>simple-messaging-pubsub</module>
         <module>simple-nosql-cluster</module>
     </modules>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/simple-open-loop-policy/pom.xml
----------------------------------------------------------------------
diff --git a/examples/simple-open-loop-policy/pom.xml b/examples/simple-open-loop-policy/pom.xml
index bd9627e..fba0529 100644
--- a/examples/simple-open-loop-policy/pom.xml
+++ b/examples/simple-open-loop-policy/pom.xml
@@ -99,17 +99,6 @@
                                     <outputDirectory>target/classes</outputDirectory>
                                     <destFileName>hello-world-sql-webapp.war</destFileName>
                                 </artifactItem>
-<!-- if you want the hadoop example:
-                                <artifactItem>
-                                    <groupId>${project.groupId}</groupId>
-                                    <artifactId>brooklyn-example-hello-world-hadoop-webapp</artifactId>
-                                    <version>${project.version}</version>
-                                    <type>war</type>
-                                    <overWrite>true</overWrite>
-                                    <outputDirectory>target/classes</outputDirectory>
-                                    <destFileName>hello-world-hadoop-webapp.war</destFileName>
-                                </artifactItem>
--->
                             </artifactItems>
                         </configuration>
                     </execution>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/simple-web-cluster/pom.xml
----------------------------------------------------------------------
diff --git a/examples/simple-web-cluster/pom.xml b/examples/simple-web-cluster/pom.xml
index 5b845e2..d94208b 100644
--- a/examples/simple-web-cluster/pom.xml
+++ b/examples/simple-web-cluster/pom.xml
@@ -99,17 +99,6 @@
                                     <outputDirectory>target/classes</outputDirectory>
                                     <destFileName>hello-world-sql-webapp.war</destFileName>
                                 </artifactItem>
-<!-- if you want the hadoop example:
-                                <artifactItem>
-                                    <groupId>${project.groupId}</groupId>
-                                    <artifactId>brooklyn-example-hello-world-hadoop-webapp</artifactId>
-                                    <version>${project.version}</version>
-                                    <type>war</type>
-                                    <overWrite>true</overWrite>
-                                    <outputDirectory>target/classes</outputDirectory>
-                                    <destFileName>hello-world-hadoop-webapp.war</destFileName>
-                                </artifactItem>
--->
                             </artifactItems>
                         </configuration>
                     </execution>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop-jar/pom.xml
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop-jar/pom.xml b/examples/webapps/hello-world-hadoop-jar/pom.xml
deleted file mode 100644
index 58cfc36..0000000
--- a/examples/webapps/hello-world-hadoop-jar/pom.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-
-    <artifactId>brooklyn-example-hello-world-hadoop-jar</artifactId>
-    <packaging>jar</packaging>
-
-    <name>Jar Code for Hadoop Webapp</name>
-
-    <properties>
-        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
-    </properties>
-
-    <build>
-        <finalName>brooklyn-example-hello-world-hadoop-jar</finalName>
-    </build>
-
-    <parent>
-        <groupId>io.brooklyn.example</groupId>
-        <artifactId>brooklyn-examples-webapps-parent</artifactId>
-        <version>0.7.0-SNAPSHOT</version>   <!-- BROOKLYN_VERSION -->
-        <relativePath>../pom.xml</relativePath>
-    </parent>
-
-    <dependencies>
-        <dependency>
-            <groupId>org.apache.hadoop</groupId>
-            <artifactId>hadoop-core</artifactId>
-            <version>${hadoop.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>commons-cli</groupId>
-            <artifactId>commons-cli</artifactId>
-            <version>${commons-cli.version}</version>
-        </dependency>
-        <!-- fix for https://issues.apache.org/jira/browse/HADOOP-7461 needed if hadoop is pre 1.0.0 <dependency> <groupId>org.codehaus.jackson</groupId> 
-            <artifactId>jackson-mapper-asl</artifactId> <version>1.0.1</version> </dependency> -->
-    </dependencies>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/DemoUtils.java
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/DemoUtils.java b/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/DemoUtils.java
deleted file mode 100644
index f0acaf2..0000000
--- a/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/DemoUtils.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.demo.webapp.hello;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.PrintWriter;
-import java.io.StringWriter;
-
-public class DemoUtils {
-
-
-    public static String stringFromInputStream(InputStream is) throws IOException {
-        BufferedReader reader = new BufferedReader(new InputStreamReader(is));
-        StringBuffer sb = new StringBuffer();
-        String line;
-        while ((line = reader.readLine()) != null)
-            sb.append(line).append("\n");
-        return sb.toString();
-    }
-    
-    public static String getStackTrace(Throwable t) {
-        StringWriter s = new StringWriter();
-        PrintWriter pw = new PrintWriter(s);
-        t.printStackTrace(pw);
-        pw.flush();
-        return s.getBuffer().toString();
-    }
-    
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/HadoopWordCount.java
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/HadoopWordCount.java b/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/HadoopWordCount.java
deleted file mode 100644
index 8700758..0000000
--- a/examples/webapps/hello-world-hadoop-jar/src/main/java/brooklyn/demo/webapp/hello/HadoopWordCount.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.demo.webapp.hello;
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.util.StringTokenizer;
-
-import org.apache.hadoop.conf.Configuration;
-import org.apache.hadoop.fs.FSDataOutputStream;
-import org.apache.hadoop.fs.FileStatus;
-import org.apache.hadoop.fs.FileSystem;
-import org.apache.hadoop.fs.Path;
-import org.apache.hadoop.io.IntWritable;
-import org.apache.hadoop.io.Text;
-import org.apache.hadoop.mapreduce.Job;
-import org.apache.hadoop.mapreduce.Mapper;
-import org.apache.hadoop.mapreduce.Reducer;
-import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
-import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
-import org.apache.hadoop.util.GenericOptionsParser;
-
-public class HadoopWordCount {
-
-    public static class TokenizerMapper extends Mapper<Object, Text, Text, IntWritable>{
-
-        private final static IntWritable one = new IntWritable(1);
-        private Text word = new Text();
-
-        public void map(Object key, Text value, Context context) throws IOException, InterruptedException {
-            StringTokenizer itr = new StringTokenizer(value.toString());
-            while (itr.hasMoreTokens()) {
-                String w = itr.nextToken();
-                // words (in our world) consist of [A-Za-z0-9_]+
-                w = w.replaceAll("[^A-Za-z0-9_]+", " ").replaceAll("\\s+", " ").trim().toLowerCase();
-                if (w.length()>0) {
-                    StringTokenizer itr2 = new StringTokenizer(w);
-                    while (itr2.hasMoreTokens()) {
-                        String w2 = itr2.nextToken();
-                        word.set(w2);
-                        context.write(word, one);
-                    }
-                }
-            }
-        }
-    }
-
-    public static class IntSumReducer 
-    extends Reducer<Text,IntWritable,Text,IntWritable> {
-        private IntWritable result = new IntWritable();
-
-        public void reduce(Text key, Iterable<IntWritable> values, 
-                Context context
-                ) throws IOException, InterruptedException {
-            int sum = 0;
-            for (IntWritable val : values) {
-                sum += val.get();
-            }
-            result.set(sum);
-            context.write(key, result);
-        }
-    }
-
-    public static Job makeJob(Configuration conf) throws IOException {
-        Job job = new Job(conf, "word count");
-        job.setJarByClass(HadoopWordCount.class);
-        job.setMapperClass(TokenizerMapper.class);
-        job.setCombinerClass(IntSumReducer.class);
-        job.setReducerClass(IntSumReducer.class);
-        job.setOutputKeyClass(Text.class);
-        job.setOutputValueClass(IntWritable.class);
-        return job;
-    }
-    
-    public static String stringFromInputStream(InputStream is) throws IOException {
-        BufferedReader reader = new BufferedReader(new InputStreamReader(is));
-        StringBuffer sb = new StringBuffer();
-        String line;
-        while ((line = reader.readLine()) != null)
-            sb.append(line).append("\n");
-        return sb.toString();
-    }
-
-    public static Job runWordCountWithArgs(Configuration conf, String ...args) throws FileNotFoundException, IOException, InterruptedException {
-        if (args.length > 2) {
-            System.err.println("Usage: wordcount [/tmp/sample.txt] [/tmp/out]");
-            System.exit(2);
-        }
-        if (args.length > 0 && (args[0].equals("-h") || args[0].equals("--help"))) {
-            System.err.println("Usage: wordcount [/tmp/sample.txt] [/tmp/out]");
-            System.exit(0);
-        }
-        
-        FileSystem fsClient = FileSystem.get(conf);
-        
-        // read from /tmp/sample.txt (by default), creating it if it doesn't exist
-        String inN = args.length > 0 ? args[0] : "/tmp/sample.txt";
-        Path in = new Path(inN);
-        if (!fsClient.exists(in)) {
-            FSDataOutputStream inS = fsClient.create(in);
-            
-            String textForInputFile = "This is a test.\nHow is this test working?\nSeems this is okay to me.\n";
-            if (new File(inN).exists()) {
-                //upload from local file system
-                textForInputFile = stringFromInputStream(new FileInputStream(inN));
-            }
-            inS.write(textForInputFile.getBytes());
-            inS.close();
-        }
-        
-        // write to /tmp/out (by default), wipe it if it exists
-        String outN = args.length > 1 ? args[1] : "/tmp/out";
-        Path out = new Path(outN);
-        if (fsClient.exists(out)) {
-            fsClient.delete(out, true);
-//            if (!out.delete()) {
-//                Runtime.getRuntime().exec(new String[] { "rm", "-rf", "/tmp/out" }).waitFor();
-//            }
-        }
-        
-        Job job = makeJob(conf);
-        FileInputFormat.addInputPath(job, new Path(inN));
-        FileOutputFormat.setOutputPath(job, new Path(outN));
-        return job;
-    }
-
-    public static void main(String[] args) throws Exception {
-        Configuration conf = new Configuration();
-//        String confFileName = System.getProperty("user.home")+"/"+".whirr"+"/"+"whirr-hadoop-sample-"+System.getProperty("user.name")+"/"+"hadoop-site.xml";
-//        conf.addResource(new URL("file://"+confFileName));
-//        conf.set("mapred.jar", "/tmp/jar-for-my-hadoop-app.jar");
-        
-        String[] otherArgs = new GenericOptionsParser(conf, args).getRemainingArgs();
-        Job job = runWordCountWithArgs(conf, otherArgs);
-        
-        boolean result = job.waitForCompletion(true);
-        if (!result) System.out.println("Job returned non-zero result code.");
-        
-        for (FileStatus f: FileSystem.get(conf).listStatus(new Path(args.length > 1 ? args[1] : "/tmp/out"))) {
-            if (!f.isDir())
-                System.out.println("Output "+f.getPath()+":\n"+stringFromInputStream(FileSystem.get(conf).open(f.getPath())));
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/pom.xml
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/pom.xml b/examples/webapps/hello-world-hadoop/pom.xml
deleted file mode 100644
index 8be62be..0000000
--- a/examples/webapps/hello-world-hadoop/pom.xml
+++ /dev/null
@@ -1,89 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>brooklyn-example-hello-world-hadoop-webapp</artifactId>
-    <packaging>war</packaging>
-    <name>hello-world-hadoop-webapp Maven Webapp</name>
-
-    <parent>
-        <groupId>io.brooklyn.example</groupId>
-        <artifactId>brooklyn-examples-webapps-parent</artifactId>
-        <version>0.7.0-SNAPSHOT</version>   <!-- BROOKLYN_VERSION -->
-        <relativePath>../pom.xml</relativePath>
-    </parent>
-
-    <dependencies>
-        <dependency>
-            <groupId>mysql</groupId>
-            <artifactId>mysql-connector-java</artifactId>
-            <version>${mysql-connector-java.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.hadoop</groupId>
-            <artifactId>hadoop-client</artifactId>
-            <version>${hadoop.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn.example</groupId>
-            <artifactId>brooklyn-example-hello-world-hadoop-jar</artifactId>
-            <version>${project.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.slf4j</groupId>
-            <artifactId>slf4j-api</artifactId>
-            <version>${slf4j.version}</version>
-        </dependency>
-    </dependencies>
-
-    <build>
-        <finalName>brooklyn-example-hello-world-hadoop-webapp</finalName>
-        <plugins>
-            <plugin>
-                <artifactId>maven-dependency-plugin</artifactId>
-                <!-- copy the JAR so it is available in the WAR to deploy to hadoop -->
-                <executions>
-                    <execution>
-                        <id>copy</id>
-                        <phase>process-classes</phase>
-                        <goals>
-                            <goal>copy</goal>
-                        </goals>
-                        <configuration>
-                            <artifactItems>
-                                <artifactItem>
-                                    <!-- this can fail in eclipse trying to copy _from_ target/classes. see http://jira.codehaus.org/browse/MDEP-259 -->
-                                    <groupId>${project.groupId}</groupId>
-                                    <artifactId>brooklyn-example-hello-world-hadoop-jar</artifactId>
-                                    <version>${project.version}</version>
-                                    <type>jar</type>
-                                    <overWrite>true</overWrite>
-                                    <outputDirectory>target/classes</outputDirectory>
-                                    <destFileName>brooklyn-example-hello-world-hadoop-jar.jar</destFileName>
-                                </artifactItem>
-                            </artifactItems>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
-        </plugins>
-    </build>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/java/brooklyn/demo/webapp/hello/SerializeHelloWorldHadoopJar.java
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/java/brooklyn/demo/webapp/hello/SerializeHelloWorldHadoopJar.java b/examples/webapps/hello-world-hadoop/src/main/java/brooklyn/demo/webapp/hello/SerializeHelloWorldHadoopJar.java
deleted file mode 100644
index 03fa331..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/java/brooklyn/demo/webapp/hello/SerializeHelloWorldHadoopJar.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.demo.webapp.hello;
-
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.URL;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * The remote hadoop needs access to a jar file containing the code.
- * We jump through some maven hoops to have that JAR in our classpath,
- * then on the web server we serialize that JAR then pass the filename
- * to the JobConf which gets sent to hadoop.
- */
-public class SerializeHelloWorldHadoopJar {
-    
-    public static final Logger LOG = LoggerFactory.getLogger(SerializeHelloWorldHadoopJar.class);
-    
-    private static final String JAR_RESOURCE_NAME = "brooklyn-example-hello-world-hadoop-jar.jar";
-    private static AtomicBoolean initialized = new AtomicBoolean(false);
-    private static String jarFileName;
-    
-    public static void init() {
-        if (initialized.get()) return;
-        synchronized (initialized) {
-            if (initialized.get()) return;
-            try {
-                URL u = SerializeHelloWorldHadoopJar.class.getClassLoader().getResource(JAR_RESOURCE_NAME);
-                if (u==null) {
-                    throw new FileNotFoundException("jar "+JAR_RESOURCE_NAME+" not on classpath");
-                } else {
-                    OutputStream out = new FileOutputStream("/tmp/brooklyn-example-hello-world-hadoop-jar.jar");
-                    copy(u.openStream(), out);
-                    out.close();
-                    jarFileName = "/tmp/brooklyn-example-hello-world-hadoop-jar.jar";
-                }
-            } catch (Exception e) {
-                LOG.warn("Cannot copy "+JAR_RESOURCE_NAME+"; hadoop will likely fail: "+e);
-            }
-            initialized.set(true);
-        }
-    }
-
-    public static String getJarName() {
-        init();
-        return jarFileName;
-    }
-
-    private static void copy(InputStream input, OutputStream output) throws IOException {
-        byte[] buf = new byte[1024];
-        int bytesRead = input.read(buf);
-        while (bytesRead != -1) {
-            output.write(buf, 0, bytesRead);
-            bytesRead = input.read(buf);
-        }
-        output.flush();
-    }
-    
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/WEB-INF/web.xml b/examples/webapps/hello-world-hadoop/src/main/webapp/WEB-INF/web.xml
deleted file mode 100644
index 8b6f078..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/WEB-INF/web.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<!DOCTYPE web-app PUBLIC
- "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
- "http://java.sun.com/dtd/web-app_2_3.dtd" >
-
-<web-app>
-  <display-name>Archetype Created Web Application</display-name>
-</web-app>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/available.jsp
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/available.jsp b/examples/webapps/hello-world-hadoop/src/main/webapp/available.jsp
deleted file mode 100644
index f1c1fbf..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/available.jsp
+++ /dev/null
@@ -1,73 +0,0 @@
-<html>
-<!--
-    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.
--->
-<head>
-<title>Sample "Hello, World" Application</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed "Hello, World" Application</h1>
-<p>This is the home page for a sample application used to illustrate 
-how web applications can be deployed to multi-cloud environments using Brooklyn.
-</td>
-</tr>
-</table>
-
-<p>
-The following apps are available:
-<p>
-
-<ul>
-<%
-String url=System.getProperty("brooklyn.example.db.url");
-//URL should be supplied e.g. "-Dbrooklyn.example.db.url=jdbc:mysql://localhost/visitors?user=brooklyn&password=br00k11n"
-//(note quoting needed due to ampersand)
-if (url!=null) {
-%>
-<li><a href="db.jsp">SQL database chatroom</a></li>
-<% } %>
-
-<%
-String hadoopConfigUrl=System.getProperty("brooklyn.example.hadoop.site.xml.url");
-String hadoopConfigContents=System.getProperty("brooklyn.example.hadoop.site.xml.contents");
-boolean hasHadoop = (hadoopConfigUrl!=null || hadoopConfigContents!=null);
-//URL or contents should be supplied e.g. -Dbrooklyn.example.hadoop.site.xml.url=file://tmp/hadoop-site.xml
-if (hasHadoop) {
-%>
-<li><a href="hadoop-chat.jsp">Hadoop chatroom</a></li>
-<li><a href="hadoop-wordcount.jsp">Hadoop wordcount</a> (inevitably!) run over the chats</li>
-<% } %>
-
-<%
-if (!hasHadoop && url==null) {
-%>
-<li><i>None.</i> Try one of the other Brooklyn examples to see SQL or Hadoop.</li>
-<% } %>
-</ul>
-
-<p>Or you can supply or edit the <a href="configure.jsp">configuration</a>.</p>
-
-</body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/configure.jsp
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/configure.jsp b/examples/webapps/hello-world-hadoop/src/main/webapp/configure.jsp
deleted file mode 100644
index 84f3819..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/configure.jsp
+++ /dev/null
@@ -1,122 +0,0 @@
-<%@ page language="java" import="java.sql.*"%>
-
-<html>
-<!--
-    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.
--->
-<head>
-<title>Sample Application Database JSP Page</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td align=center>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed WebApp</h1>
-This is the output of a JSP page that is part of the Hello, World application,
-deployed by brooklyn, to allow <b>configuration<b>.
-</td>
-</tr>
-</table>
-
-<%
-if (request.getParameter("key")!=null) {
-    String key = request.getParameter("key"); 
-    String value = request.getParameter("value");
-    Object oldValue = System.getProperties().setProperty(key, value);
-%>
-    <p><i>Applied new value for '<%= key %>'.</i></p>
-<% } %>
-
-<table border="1">
-
-<tr>
-<td><b>Key</b></td>
-<td><b>Current/New Value</b></td>
-<td><b>Sample Value</b></td>
-</tr>
-
-<tr>
-<td>brooklyn.example.db.url</td>
-<td>
-<form action="configure.jsp" method="GET">
-  <input type="hidden" name="key" value="brooklyn.example.db.url">
-  <input type="text" name="value" value="<%= System.getProperty("brooklyn.example.db.url", "") %>" width="30">
-  <input type="submit" value="Set"/>
-</form>
-</td>
-<td>jdbc:mysql://localhost/visitors?user=brooklyn&password=br00k11n</td>
-</tr>
-
-<tr>
-<td>brooklyn.example.hadoop.site.xml.url</td>
-<td>
-<form action="configure.jsp" method="GET">
-  <input type="hidden" name="key" value="brooklyn.example.hadoop.site.xml.url">
-  <input type="text" name="value" value="<%= System.getProperty("brooklyn.example.hadoop.site.xml.url", "") %>" width="30">
-  <input type="submit" value="Set"/>
-</form>
-</td>
-<td>file:///tmp/hadoop-site.xml</td>
-</tr>
-
-<tr>
-<td>brooklyn.example.hadoop.site.xml.contents</td>
-<td>
-<form action="configure.jsp" method="GET">
-  <input type="hidden" name="key" value="brooklyn.example.hadoop.site.xml.contents">
-  <textarea name="value" cols="40" rows="8"><%= System.getProperty("brooklyn.example.hadoop.site.xml.contents", "") %></textarea>
-  <input type="submit" value="Set"/>
-</form>
-</td>
-<td>
-<pre>
-&lt;configuration&gt;
-  &lt;property&gt;
-    &lt;name&gt;mapred.job.tracker&lt;/name&gt;
-    &lt;value&gt;ec2-184-169-225-252.us-west-1.compute.amazonaws.com:8021&lt;/value&gt;
-  &lt;/property&gt;
-  &lt;property&gt;
-    &lt;name&gt;fs.default.name&lt;/name&gt;
-    &lt;value&gt;hdfs://ec2-184-169-225-252.us-west-1.compute.amazonaws.com:8020/&lt;/value&gt;
-  &lt;/property&gt;
-  &lt;property&gt;
-    &lt;name&gt;hadoop.socks.server&lt;/name&gt;
-    &lt;value&gt;localhost:6666&lt;/value&gt;
-  &lt;/property&gt;
-  &lt;property&gt;
-    &lt;name&gt;fs.s3n.awsAccessKeyId&lt;/name&gt;
-    &lt;value&gt;XXX&lt;/value&gt;
-  &lt;property&gt;
-    &lt;name&gt;fs.s3.awsSecretAccessKey&lt;/name&gt;
-    &lt;value&gt;XXX&lt;/value&gt;
-  &lt;/property&gt;
-&lt;/configuration&gt;
-</pre>
-</td>
-</tr>
-
-</table>
-
-<p>Click <a href="index.html">here</a> to go back to the main page.</p>
-
-</body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/db.jsp
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/db.jsp b/examples/webapps/hello-world-hadoop/src/main/webapp/db.jsp
deleted file mode 100644
index b6954eb..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/db.jsp
+++ /dev/null
@@ -1,123 +0,0 @@
-<%@ page language="java" import="java.sql.*"%>
-
-<html>
-<!--
-    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.
--->
-<head>
-<title>Sample Application Database JSP Page</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td align=center>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed WebApp (Database JSP)</h1>
-This is the output of a JSP page that is part of the Hello, World application,
-deployed by brooklyn, to show <b>SQL database interactivity</b>.
-</td>
-</tr>
-</table>
-
-<%
-String url=System.getProperty("brooklyn.example.db.url");
-//URL should be supplied e.g. ""-Dbrooklyn.example.db.url=jdbc:mysql://localhost/visitors?user=brooklyn&password=br00k11n"
-//(note quoting needed due to ampersand)
-if (url==null) {
-%>
-    <p>(There is no database included as part of this example.)</p>
-<% } else { /* begin database-enabled block */ %>
-
-<br/>
-<p>Visitors:</p>
-<ul>
-
-<%
-Connection con=null;
-ResultSet rst=null;
-Statement stmt=null;
-int i=0;
-
-try {
-  
-  String DRIVER = "com.mysql.jdbc.Driver";
-  Class.forName(DRIVER).newInstance();
-
-  con=DriverManager.getConnection(url);
-  stmt=con.createStatement();
-  
-  if (request.getParameter("name")!=null) {
-      //add a message
-      stmt.execute("INSERT INTO MESSAGES values (default, '"+
-              //better escaping and security desired... 
-              //this essentially does StringEscapeUtils.escapeSql (either brooklyn.util or apache commons)
-              request.getParameter("name").replaceAll("'", "''")+
-              "', '"+
-              request.getParameter("message").replaceAll("'", "''")+
-              "')");
-  }
-  
-  rst=stmt.executeQuery("select * from MESSAGES");
-  while (rst.next()) {
-%>
-    <li> <b><%= rst.getString(2) %></b>: <%= rst.getString(3) %> </li>
-<%
-    i++;
-  }
-} catch (Exception e) {
-  i=-1;
-%>
-  <li> <b>The database does not appear to be connected.</b> </li>
-  <li> ERROR: <%= e %> </li>
-<%
-} finally {
-  if (rst!=null) rst.close();
-  if (stmt!=null) stmt.close();
-  if (con!=null) con.close();
-}
-
-if (i==0) {
-%>
-  <li> <i>None.</i> </li>
-<%
-}
-%>
-
-</ul>
-
-<br/>
-
-<p>Please enter a message:</p>
-
-<form action="db.jsp" method="GET">
-  <table>
-    <tr><td>Name: </td><td><input type="text" name="name"></td></tr>
-    <tr><td>Message: </td><td><input type="text" name="message"></td></tr>
-  </table>
-  <input type="submit" value="Submit"/>
-</form>
-
-<% } /* end of database-enabled block */ %>
-
-<br/>
-<p>Click <a href="index.html">here</a> to go back to the main page.</p>
-
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-chat.jsp
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-chat.jsp b/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-chat.jsp
deleted file mode 100644
index 2f30752..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-chat.jsp
+++ /dev/null
@@ -1,112 +0,0 @@
-<%@ page language="java" import="java.sql.*"%>
-
-<html>
-<!--
-    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.
--->
-<head>
-<title>Sample Application HDFS JSP Page</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td align=center>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed WebApp (Hadoop JSP)</h1>
-This is the output of a JSP page that is part of the Hello, World application,
-deployed by brooklyn, to show <b>hadoop hdfs used as the data store</b>.
-</td>
-</tr>
-</table>
-
-<%
-String hadoopConfigUrl=System.getProperty("brooklyn.example.hadoop.site.xml.url");
-String hadoopConfigContents=System.getProperty("brooklyn.example.hadoop.site.xml.contents");
-if (hadoopConfigUrl==null && hadoopConfigContents==null) {
-%>
-    <p>There is no hadoop included as part of this example. Set brooklyn.example.hadoop.site.xml.url 
-    or brooklyn.example.hadoop.site.xml.contents to proceed.</p>
-<% } else { /* begin hadoop-enabled block */ 
-
-try {
-    org.apache.hadoop.conf.Configuration conf = new org.apache.hadoop.conf.Configuration();
-    conf.setClassLoader(brooklyn.demo.webapp.hello.HadoopWordCount.class.getClassLoader());
-    if (hadoopConfigUrl!=null) conf.addResource(new java.net.URL(hadoopConfigUrl));
-    if (hadoopConfigContents!=null) conf.addResource(new java.io.ByteArrayInputStream(hadoopConfigContents.getBytes()));
-    org.apache.hadoop.fs.FileSystem fsClient = org.apache.hadoop.fs.FileSystem.get(conf);
-    if (fsClient==null) throw new NullPointerException("Can't access fsClient");
-    
-    if (request.getParameter("name")!=null) {
-        java.io.OutputStream os1 = fsClient.create(new org.apache.hadoop.fs.Path("chats", ""+System.currentTimeMillis()+"-"+((int)(Math.random()*10000))));
-        os1.write(request.getParameter("name").getBytes());
-        os1.write(" : ".getBytes());
-        os1.write(request.getParameter("message").getBytes());
-        os1.flush(); os1.close();
-    }
-%>
-    <br/>
-    <p>Visitors:</p>
-    <ul>
-<%
-    org.apache.hadoop.fs.FileStatus[] files = fsClient.listStatus(new org.apache.hadoop.fs.Path("chats"));
-    if (files==null) files = new org.apache.hadoop.fs.FileStatus[0]; 
-    for (org.apache.hadoop.fs.FileStatus f: files) {
-%>
-        <li> <%= brooklyn.demo.webapp.hello.DemoUtils.stringFromInputStream(fsClient.open(f.getPath())) %> </li>
-<%
-    }
-    if (files.length==0) {
-    %>
-      <li> <i>None.</i> </li>
-    <%
-    }
-    %>
-
-    </ul>
-    <br/>
-
-    <p>Please enter a message:</p>
-
-    <form action="hadoop-chat.jsp" method="GET">
-      <table>
-        <tr><td>Name: </td><td><input type="text" name="name"></td></tr>
-        <tr><td>Message: </td><td><input type="text" name="message"></td></tr>
-      </table>
-      <input type="submit" value="Submit"/>
-    </form>
-
-<%
-} catch (Exception e) {
-%>
-    <b>Error connecting to Hadoop.</b><br/>
-    ERROR: <%= e %><br/><br/>
-    <pre> <%= brooklyn.demo.webapp.hello.DemoUtils.getStackTrace(e) %></pre>
-<%
-}
-}
-%>
-
-    <br/>
-    <p>Click <a href="hadoop-wordcount.jsp">here</a> to run a map-reduce job counting the words in these comments.</p>
-    <p>Click <a href="index.html">here</a> to go back to the main page.</p>
-
-</body>
-</html>


[6/8] git commit: Use guava instead of com.beust Lists

Posted by he...@apache.org.
Use guava instead of com.beust Lists 

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

Branch: refs/heads/master
Commit: 0b8a639d6350a59504f91961a27cc7a8c6efc75a
Parents: e315de3
Author: Aled Sage <al...@gmail.com>
Authored: Tue Jul 22 12:52:37 2014 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Tue Jul 22 12:52:37 2014 +0100

----------------------------------------------------------------------
 .../brooklyn/internal/storage/impl/BrooklynStorageImplTest.java  | 4 ++--
 .../java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java   | 2 +-
 .../brooklyn/policy/loadbalancing/MockContainerEntityImpl.java   | 2 +-
 .../test/java/brooklyn/entity/database/VogellaExampleAccess.java | 3 ++-
 4 files changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/0b8a639d/core/src/test/java/brooklyn/internal/storage/impl/BrooklynStorageImplTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/brooklyn/internal/storage/impl/BrooklynStorageImplTest.java b/core/src/test/java/brooklyn/internal/storage/impl/BrooklynStorageImplTest.java
index 6fb396d..50b7ba3 100644
--- a/core/src/test/java/brooklyn/internal/storage/impl/BrooklynStorageImplTest.java
+++ b/core/src/test/java/brooklyn/internal/storage/impl/BrooklynStorageImplTest.java
@@ -28,18 +28,18 @@ import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 
-import brooklyn.internal.storage.impl.inmemory.InmemoryDatagrid;
 import org.testng.annotations.BeforeMethod;
 import org.testng.annotations.Test;
 
 import brooklyn.internal.storage.BrooklynStorage;
 import brooklyn.internal.storage.DataGrid;
 import brooklyn.internal.storage.Reference;
+import brooklyn.internal.storage.impl.inmemory.InmemoryDatagrid;
 
-import com.beust.jcommander.internal.Lists;
 import com.google.common.collect.ImmutableList;
 import com.google.common.collect.ImmutableMap;
 import com.google.common.collect.ImmutableSet;
+import com.google.common.collect.Lists;
 
 public class BrooklynStorageImplTest {
     

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/0b8a639d/core/src/test/java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java b/core/src/test/java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java
index 9914e0b..886e473 100644
--- a/core/src/test/java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java
+++ b/core/src/test/java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java
@@ -42,11 +42,11 @@ import brooklyn.util.config.ConfigBag;
 import brooklyn.util.text.Identifiers;
 import brooklyn.util.time.Time;
 
-import com.beust.jcommander.internal.Lists;
 import com.google.common.base.Stopwatch;
 import com.google.common.base.Strings;
 import com.google.common.collect.ImmutableList;
 import com.google.common.collect.ImmutableMap;
+import com.google.common.collect.Lists;
 import com.google.common.util.concurrent.Futures;
 import com.google.common.util.concurrent.ListenableFuture;
 import com.google.common.util.concurrent.ListeningExecutorService;

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/0b8a639d/policy/src/test/java/brooklyn/policy/loadbalancing/MockContainerEntityImpl.java
----------------------------------------------------------------------
diff --git a/policy/src/test/java/brooklyn/policy/loadbalancing/MockContainerEntityImpl.java b/policy/src/test/java/brooklyn/policy/loadbalancing/MockContainerEntityImpl.java
index 85a5893..13baec5 100644
--- a/policy/src/test/java/brooklyn/policy/loadbalancing/MockContainerEntityImpl.java
+++ b/policy/src/test/java/brooklyn/policy/loadbalancing/MockContainerEntityImpl.java
@@ -37,10 +37,10 @@ import brooklyn.location.Location;
 import brooklyn.util.collections.MutableList;
 import brooklyn.util.time.Time;
 
-import com.beust.jcommander.internal.Lists;
 import com.google.common.base.Predicates;
 import com.google.common.collect.ImmutableList;
 import com.google.common.collect.Iterables;
+import com.google.common.collect.Lists;
 import com.google.common.collect.Maps;
 import com.google.common.collect.Sets;
 

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/0b8a639d/software/database/src/test/java/brooklyn/entity/database/VogellaExampleAccess.java
----------------------------------------------------------------------
diff --git a/software/database/src/test/java/brooklyn/entity/database/VogellaExampleAccess.java b/software/database/src/test/java/brooklyn/entity/database/VogellaExampleAccess.java
index a8c1d4c..962a294 100644
--- a/software/database/src/test/java/brooklyn/entity/database/VogellaExampleAccess.java
+++ b/software/database/src/test/java/brooklyn/entity/database/VogellaExampleAccess.java
@@ -18,10 +18,11 @@
  */
 package brooklyn.entity.database;
 
-import com.beust.jcommander.internal.Lists;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import com.google.common.collect.Lists;
+
 import java.sql.*;
 import java.util.List;
 


[3/8] git commit: Cleanup docs

Posted by he...@apache.org.
Cleanup docs

- remove out-of-date (misleading) wish list
- removes unused/old catalog.md
- tidies up “writing an entity” docs a little bit
- tidies up Brooklyn projects / sub-projects listing


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

Branch: refs/heads/master
Commit: e5e0fd8c9aa40beae3befde5a6e8b42dfdda33db
Parents: e315de3
Author: Aled Sage <al...@gmail.com>
Authored: Mon Jul 21 17:47:15 2014 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Tue Jul 22 12:37:04 2014 +0100

----------------------------------------------------------------------
 .../java/brooklyn/catalog/internal/catalog.md   |  59 -----------
 docs/dev/build/index.md                         | 105 +++++++++++++------
 docs/dev/code/entity.md                         |  28 +++--
 docs/dev/code/index.include.md                  |  35 +++++--
 docs/dev/toc.json                               |   2 -
 docs/dev/wishlist.md                            |  28 -----
 docs/use/guide/extras/index.md                  |  51 +++++++--
 7 files changed, 156 insertions(+), 152 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/core/src/main/java/brooklyn/catalog/internal/catalog.md
----------------------------------------------------------------------
diff --git a/core/src/main/java/brooklyn/catalog/internal/catalog.md b/core/src/main/java/brooklyn/catalog/internal/catalog.md
deleted file mode 100644
index 2a001f2..0000000
--- a/core/src/main/java/brooklyn/catalog/internal/catalog.md
+++ /dev/null
@@ -1,59 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<catalog>
-  <name>My Local Catalog</name>
-  <!-- scan means it will load templates based on @CatalogTemplate annotations on entities;
-       recommended only for local elements to prevent having to download JARs just to populate catalog.
-       (from a local scan you can generate the XML for publishing by saying  
-        `mgmt.getCatalog().toXmlString()` in JS gui groovy page, then tweaking.)  
-       also, for a local (non-linked) reference, an empty classpath means to use the default classpath. -->
-  <classpath scan="types"/>
-
-  <!-- now (for illustration) we define some other sources which weren't on our classpath but
-       which we want included in our catalog on our brooklyn server -->
-  <catalog>
-    <classpath>
-      <entry>file://~/.m2/repository/io/cloudsoft/mapr/brooklyn-mapr/0.0.1-SNAPSHOT/brooklyn-mapr-0.0.1-SNAPSHOT.jar</entry>
-    </classpath>
-    <!-- templates explicitly listed since we didn't scan above (NB scan=false is the default) -->
-    <template type="io.brooklyn.mapr.M3App" name="MapR M3">
-        <description>MapR Apache Hadoop M3 resizable cluster deployed to a wide variety of clouds</description>
-        <iconUrl>http://releng3.cloudsoftcorp.com/downloads/brooklyn/img/mapr_logo.png</iconUrl>
-    </template>
-  </catalog>
-  
-  <catalog>
-    <description>Extra local jars I've got on my machine, added so I can pull in the CDH easily.</description>
-    <classpath scan="annotations">
-      <entry>file://~/.m2/repository/io/cloudsoft/cloudera/brooklyn-cdh/1.0.0-SNAPSHOT/brooklyn-cdh-1.0.0-SNAPSHOT.jar</entry>
-      <entry>file://~/.m2/repository/com/cloudera/whirr-cm/1.1-SNAPSHOT/whirr-cm-1.1-SNAPSHOT.jar</entry>
-    </classpath>
-    <!-- templates here were autodetected (scan=true), so we don't _need_ to list any entities;
-         but here we illustrate how we can add our own (or even override, if we left out id) -->
-    <template type="io.cloudsoft.cloudera.SampleClouderaManagedCluster" id="my_cdh" name="MY CDH">
-      <description>I've just overrridden the default and supplied my own name and description, to show what can be done.</description>
-    </template>
-  </catalog>
-  
-  <!-- and a few remote catalogs -->
-  <catalog url="http://cloudsoftcorp.com/amp-brooklyn-catalog.xml"/>
-  <catalog url="http://microsoot.com/oofice-catalog.xml"/>
-    
-</catalog>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/dev/build/index.md
----------------------------------------------------------------------
diff --git a/docs/dev/build/index.md b/docs/dev/build/index.md
index d5bee19..927c42d 100644
--- a/docs/dev/build/index.md
+++ b/docs/dev/build/index.md
@@ -63,58 +63,95 @@ brooklyn% mvn clean install
 [INFO] Reactor Build Order:
 [INFO] 
 [INFO] Brooklyn Parent Project
+[INFO] Brooklyn Utilities to Support Testing (listeners etc)
+[INFO] Brooklyn Logback Includable Configuration
+[INFO] Brooklyn Common Utilities
+[INFO] Brooklyn Groovy Utilities
 [INFO] Brooklyn API
-[INFO] Brooklyn Test Support
-[INFO] Brooklyn Core
 
 ...
 
-Mar 29, 2012 4:30:17 PM java.util.jar.Attributes read
-WARNING: Duplicate name in Manifest: Manifest-Version.
-Ensure that the manifest does not have duplicate entries, and
-that blank lines separate individual sections in both your
-manifest and in the META-INF/MANIFEST.MF entry in the jar file.
+[WARNING] Ignoring project type war - supportedProjectTypes = [jar]
 
 ...
 
-[WARNING] We have a duplicate org/jclouds/cloudsigma/CloudSigmaAsyncClient.class in 
-/Users/alex/.m2/repository/org/jclouds/provider/cloudsigma-zrh/1.4.0/cloudsigma-zrh-1.4.0.jar
+[WARNING] We have a duplicate org/xmlpull/v1/XmlPullParser.class in /Users/aled/.m2/repository/xpp3/xpp3_min/1.1.4c/xpp3_min-1.1.4c.jar
 
 ...
 
-[INFO] --- maven-jar-plugin:2.3.1:jar (default-jar) @ brooklyn-all ---
-[WARNING] JAR will be empty - no content was marked for inclusion!
+[INFO] — maven-assembly-plugin:2.3:single (build-distribution-dir) @ brooklyn-dist —
+[INFO] Reading assembly descriptor: src/main/config/build-distribution-dir.xml
+[WARNING] Cannot include project artifact: io.brooklyn:brooklyn-dist:jar:0.7.0-SNAPSHOT; it doesn't have an associated file or directory.
+[INFO] Copying files to /Users/aled/repos/apache/incubator-brooklyn/usage/dist/target/brooklyn-dist
+[WARNING] Assembly file: /Users/aled/repos/apache/incubator-brooklyn/usage/dist/target/brooklyn-dist is not a regular file (it may be a directory). It cannot be attached to the project build for installation or deployment.
+
+...
+
+[INFO] — maven-assembly-plugin:2.3:single (build-distribution-archive) @ brooklyn-dist —
+[INFO] Reading assembly descriptor: src/main/config/build-distribution-archive.xml
+[WARNING] Cannot include project artifact: io.brooklyn:brooklyn-dist:jar:0.7.0-SNAPSHOT; it doesn't have an associated file or directory.
+[INFO] Building tar: /Users/aled/repos/apache/incubator-brooklyn/usage/dist/target/brooklyn-0.7.0-SNAPSHOT-dist.tar.gz
+[WARNING] Cannot include project artifact: io.brooklyn:brooklyn-dist:jar:0.7.0-SNAPSHOT; it doesn't have an associated file or directory.
+
+...
+
+[WARNING] Don't override file /Users/aled/repos/apache/incubator-brooklyn/usage/archetypes/quickstart/target/test-classes/projects/integration-test-1/project/brooklyn-sample/src/main/resources/sample-icon.png
 
 ...
 
-[INFO] ------------------------------------------------------------------------
 [INFO] Reactor Summary:
 [INFO] 
-[INFO] Brooklyn Parent Project ........................... SUCCESS [0.813s]
-[INFO] Brooklyn API ...................................... SUCCESS [6.115s]
-[INFO] Brooklyn Test Support ............................. SUCCESS [4.592s]
-[INFO] Brooklyn Core ..................................... SUCCESS [1:20.536s]
-[INFO] Brooklyn Policies ................................. SUCCESS [57.996s]
-[INFO] Brooklyn Software Base ............................ SUCCESS [29.869s]
-[INFO] Brooklyn OSGi Software Entities ................... SUCCESS [9.392s]
-[INFO] Brooklyn Web App Software Entities ................ SUCCESS [49.606s]
-[INFO] Brooklyn Messaging Software Entities .............. SUCCESS [12.198s]
-[INFO] Brooklyn NoSQL Data Store Software Entities ....... SUCCESS [9.205s]
-[INFO] Brooklyn Database Software Entities ............... SUCCESS [7.815s]
-[INFO] Brooklyn Whirr Base Entities ...................... SUCCESS [21.292s]
-[INFO] Brooklyn Hadoop System Entities ................... SUCCESS [9.972s]
-[INFO] Brooklyn Web Console .............................. SUCCESS [1:00.814s]
-[INFO] Brooklyn Launcher ................................. SUCCESS [1:00.603s]
-[INFO] Brooklyn All Things ............................... SUCCESS [23.358s]
-[INFO] hello-world-webapp Maven Webapp ................... SUCCESS [2.521s]
-[INFO] Brooklyn Simple Web Cluster Example ............... SUCCESS [5.860s]
-[INFO] Brooklyn Hadoop and Whirr Example ................. SUCCESS [4.892s]
+[INFO] Brooklyn Parent Project ........................... SUCCESS [3.072s]
+[INFO] Brooklyn Utilities to Support Testing (listeners etc)  SUCCESS [3.114s]
+[INFO] Brooklyn Logback Includable Configuration ......... SUCCESS [0.680s]
+[INFO] Brooklyn Common Utilities ......................... SUCCESS [7.263s]
+[INFO] Brooklyn Groovy Utilities ......................... SUCCESS [5.193s]
+[INFO] Brooklyn API ...................................... SUCCESS [2.146s]
+[INFO] Brooklyn Test Support ............................. SUCCESS [2.517s]
+[INFO] CAMP Server Parent Project ........................ SUCCESS [0.075s]
+[INFO] CAMP Base ......................................... SUCCESS [4.079s]
+[INFO] Brooklyn REST Swagger Apidoc Utilities ............ SUCCESS [1.983s]
+[INFO] Brooklyn Logback Configuration .................... SUCCESS [0.625s]
+[INFO] CAMP Server ....................................... SUCCESS [5.446s]
+[INFO] Brooklyn Core ..................................... SUCCESS [1:24.122s]
+[INFO] Brooklyn Policies ................................. SUCCESS [44.425s]
+[INFO] Brooklyn Hazelcast Storage ........................ SUCCESS [7.143s]
+[INFO] Brooklyn Jclouds Location Targets ................. SUCCESS [16.488s]
+[INFO] Brooklyn Secure JMXMP Agent ....................... SUCCESS [8.634s]
+[INFO] Brooklyn JMX RMI Agent ............................ SUCCESS [2.315s]
+[INFO] Brooklyn Software Base ............................ SUCCESS [28.538s]
+[INFO] Brooklyn Network Software Entities ................ SUCCESS [3.896s]
+[INFO] Brooklyn OSGi Software Entities ................... SUCCESS [4.589s]
+[INFO] Brooklyn Web App Software Entities ................ SUCCESS [17.484s]
+[INFO] Brooklyn Messaging Software Entities .............. SUCCESS [7.106s]
+[INFO] Brooklyn Database Software Entities ............... SUCCESS [5.229s]
+[INFO] Brooklyn NoSQL Data Store Software Entities ....... SUCCESS [11.901s]
+[INFO] Brooklyn Monitoring Software Entities ............. SUCCESS [4.027s]
+[INFO] Brooklyn CAMP REST API ............................ SUCCESS [15.285s]
+[INFO] Brooklyn REST API ................................. SUCCESS [4.489s]
+[INFO] Brooklyn REST Server .............................. SUCCESS [30.270s]
+[INFO] Brooklyn REST Client .............................. SUCCESS [7.007s]
+[INFO] Brooklyn REST JavaScript Web GUI .................. SUCCESS [24.397s]
+[INFO] Brooklyn Launcher ................................. SUCCESS [15.923s]
+[INFO] Brooklyn Command Line Interface ................... SUCCESS [9.279s]
+[INFO] Brooklyn All Things ............................... SUCCESS [13.875s]
+[INFO] Brooklyn Distribution ............................. SUCCESS [49.370s]
+[INFO] Brooklyn Quick-Start Project Archetype ............ SUCCESS [12.053s]
+[INFO] Brooklyn Examples Aggregator Project .............. SUCCESS [0.085s]
+[INFO] Brooklyn Examples Support Aggregator Project - Webapps  SUCCESS [0.053s]
+[INFO] hello-world-webapp Maven Webapp ................... SUCCESS [0.751s]
+[INFO] hello-world-sql-webapp Maven Webapp ............... SUCCESS [0.623s]
+[INFO] Brooklyn Simple Web Cluster Example ............... SUCCESS [5.398s]
+[INFO] Brooklyn Global Web Fabric Example ................ SUCCESS [3.176s]
+[INFO] Brooklyn Simple Messaging Publish-Subscribe Example  SUCCESS [3.217s]
+[INFO] Brooklyn NoSQL Cluster Examples ................... SUCCESS [6.790s]
+[INFO] Brooklyn QA ....................................... SUCCESS [7.117s]
 [INFO] ------------------------------------------------------------------------
 [INFO] BUILD SUCCESS
 [INFO] ------------------------------------------------------------------------
-[INFO] Total time: 7:52.328s
-[INFO] Finished at: Thu Mar 29 16:30:17 BST 2012
-[INFO] Final Memory: 180M/528M
+[INFO] Total time: 8:33.983s
+[INFO] Finished at: Mon Jul 21 14:56:46 BST 2014
+[INFO] Final Memory: 66M/554M
 [INFO] ------------------------------------------------------------------------
 
 {% endhighlight %}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/dev/code/entity.md
----------------------------------------------------------------------
diff --git a/docs/dev/code/entity.md b/docs/dev/code/entity.md
index 4c497d9..fda984a 100644
--- a/docs/dev/code/entity.md
+++ b/docs/dev/code/entity.md
@@ -4,6 +4,17 @@ title: Writing an Entity
 toc: /toc.json
 ---
 
+## Ways to write an entity
+
+There are several ways to write a new entity:
+
+* Write pure-java, extending existing base-classes and using utilities such as `HttpTool` and `BashCommands`.
+* Write scripts, and configure (e.g. using YAML) a **`VanillaSoftwareProcess`**.
+* Use Chef recipes, and wire these into the entity by using `ChefConfig` and `ChefLifecycleEffectorTasks`.
+* Use an equivalent of Chef (e.g. Salt or Puppet; support for these is currently less mature than for Chef)
+
+The rest of this section covers writing an entity in pure-java (or other JVM languages).
+
 
 ## Things To Know
 
@@ -17,11 +28,10 @@ instance, which is important in a distributed management plane.
 All entity implementations inherit from `AbstractEntity`, 
 often through one of the following:
 
-* **`SoftwareProcess`**:  if it's a software process
-* **`VanillaJavaApp`**:  if it's a plain-old-java app
-* **`JavaWebAppSoftwareProcess`**:  if it's a JVM-based web-app
-* **`WhirrEntity`**:  if it's a service launched using Whirr
-* **`DynamicGroup`**:  if it's a collection of other entities
+* **`SoftwareProcessImpl`**:  if it's a software process
+* **`VanillaJavaAppImpl`**:  if it's a plain-old-java app
+* **`JavaWebAppSoftwareProcessImpl`**:  if it's a JVM-based web-app
+* **`DynamicClusterImpl`**, **`DynamicGroupImpl`** or **`AbstractGroupImpl`**:  if it's a collection of other entities
 
 Software-based processes tend to use *drivers* to install and
 launch the remote processes onto *locations* which support that driver type.
@@ -44,10 +54,10 @@ So to get started:
 1. Create your entity interface, extending the appropriate selection from above,
    to define the effectors and sensors.
 2. Include an annotation like `@ImplementedBy(YourEntityImpl.class)` on your interface,
-   where YourEntityImpl will be the class name for your entity implementation.
+   where `YourEntityImpl` will be the class name for your entity implementation.
 3. Create your entity class, implementing your entity interface and extending the 
    classes for your chosen entity super-types. Naming convention is a suffix "Impl"
-   for the entity class.
+   for the entity class, but this is not essential.
 4. Create a driver interface, again extending as appropriate (e.g. `SoftwareProcessDriver`).
    The naming convention is to have a suffix "Driver". 
 5. Create the driver class, implementing your driver interface, and again extending as appropriate.
@@ -71,8 +81,8 @@ Check out some of the exemplar existing entities
 (note, some of the other entities use deprecated utilities and a deprecated class 
 hierarchy; it is suggested to avoid these, looking at the ones below instead):
 
-* JBoss7Server
-* MySqlNode
+* `JBoss7Server`
+* `MySqlNode`
 
 You might also find the following helpful:
 

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/dev/code/index.include.md
----------------------------------------------------------------------
diff --git a/docs/dev/code/index.include.md b/docs/dev/code/index.include.md
index 84b8a3d..b071930 100644
--- a/docs/dev/code/index.include.md
+++ b/docs/dev/code/index.include.md
@@ -31,31 +31,46 @@ This document is intended to help people become familiar with the codebase.
 
 ## Project Structure
 
-Brooklyn is split into the following projects and subprojects:
+Brooklyn is split into the following projects and sub-projects:
 
+* **``camp``**: the components for a server which speaks the CAMP REST API and which understands the CAMP YAML plan language
 * **``api``**: the pure-Java interfaces for interacting with the system
 * **``core``**: the base class implementations for entities and applications, entity traits, locations, policies, sensor and effector support, tasks, and more 
+* **``locations``**: specific location integrations
+    * **``jclouds``**: integration with many cloud APIs and providers, via Apache jclouds
 * **``policies``**: collection of useful policies for automating entity activity  
 * **``software``**: entities which are mainly launched by launched software processes on machines, and collections thereof
     * **``base``**: software process lifecycle abstract classes and drivers (e.g. SSH) 
     * **``webapp``**: web servers (JBoss, Tomcat), load-balancers (Nginx), and DNS (Geoscaling) 
     * **``database``**: relational databases (SQL) 
     * **``nosql``**: datastores other than RDBMS/SQL (often better in distributed environments) 
-    * **``messaging``**: messaging systems, including Qpid, Apache MQ 
-    * **...**
-* **``systems``**: entities which are mainly created or managed by other systems, where Brooklyn integrates with those (multi-machine) systems and is removed from the processes
-    * **``whirr``**:  ``base`` Whirr integration, and entities built on Whirr such as the configurable ``hadoop`` deployment
+    * **``messaging``**: messaging systems, including Qpid, Apache MQ, RabbitMQ 
+    * **``monitoring``**: monitoring tools, including Monit
+    * **``osgi``**: OSGi servers 
     * **...**
+* **``utils``**: projects which lower level utilities
+    * **common**: Utility classes and methods developed for Brooklyn but not dependendent on Brooklyn
+    * **groovy**: Groovy extensions and utility classes and methods developed for Brooklyn but not dependendent on Brooklyn
+    * **jmx/jmxmp-ssl-agent**: An agent implementation that can be attached to a Java process, to give expose secure JMXMP
+    * **jmx/jmxrmi-agent**: An agent implementation that can be attached to a Java process, to give expose JMX-RMI without requiring all high-number ports to be open
+    * **rest-swagger**: Swagger REST API utility classes and methods developed for Brooklyn but not dependendent on Brooklyn
+    * **test-support**: Test utility classes and methods developed for Brooklyn but not dependendent on Brooklyn
 * **``usage``**: projects which make Brooklyn easier to use, either for end-users or Brooklyn developers
-    * **all**: maven project to supply a shaded JAR (containing all dependencies) for convenience 
+    * **all**: maven project to supply a shaded JAR (containing all dependencies) for convenience
+    * **archetypes**: A maven archetype, for easily generating the structure of a new downstream projects 
+    * **camp**: Brooklyn bindings for the CAMP REST API
     * **cli**: backing implementation for Brooklyn's command line interface
     * **dist**: builds brooklyn as a downloadable .zip and .tar.gz
     * **jsgui**: Javascript web-app for the brooklyn management web console (builds a WAR)
     * **launcher**: for launching brooklyn, either using a main method or invoked from the cli project
-    * **qa**: longevity and stress tests
-    * **rest**: implementation of brooklyn's REST api 
+    * **logback-includes**: Various helpful logback XML files that can be included; does not contain logback.xml 
+    * **logback-xml**: Contains a logback.xml that references the include files in brooklyn-logback-includes
+    * **rest-api**: The API classes for the Brooklyn REST api
+    * **rest-client**: A client Java implementation for using the Brooklyn REST API 
+    * **rest-server**: The server-side implementation of the Brooklyn REST API
     * **scripts**: various scripts useful for building, updating, etc. (see comments in the scripts)
-    * **test-support**: provides support for tests, used by nearly all projects in scope ``test`` 
+    * **qa**: longevity and stress tests
+    * **test-support**: provides Brooklyn-specific support for tests, used by nearly all projects in scope ``test``
 * **``docs``**: the markdown source code for this documentation, as described [here]({{site.url}}/dev/tips/update-docs.html)
 * **``examples``**: some canonical examples, as listed [here]({{site.url}}/use/examples)
 * **``sandbox``**: various projects, entities, and policies which the Brooklyn Project is incubating
@@ -72,8 +87,8 @@ If you're interested in building and editing the code, check out:
 
 If you want to start writing your own policies and entities, have a look at:
 
-* [Writing a Brooklyn Policy](policy.html)
 * [Writing a Brooklyn Entity](entity.html)
+* [Writing a Brooklyn Policy](policy.html)
 * Or see the [User Guide]({{ site.url }}/use/guide/index.html) 
   on [policies]({{ site.url }}/use/guide/policies/index.html)
   and [entities]({{ site.url }}/use/guide/entities/index.html)

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/dev/toc.json
----------------------------------------------------------------------
diff --git a/docs/dev/toc.json b/docs/dev/toc.json
index cc10ebf..f22e840 100644
--- a/docs/dev/toc.json
+++ b/docs/dev/toc.json
@@ -11,8 +11,6 @@
   "file": "{{ site.url }}/dev/tips/index.html",
   "exclude": true,
   "children": {% readj ./tips/toc.json %} },
-{ "title": "Wishlist",
-  "file": "{{ site.url }}/dev/wishlist.html" },
 { "title": "Links",
   "file": "{{ site.url }}/dev/links.html",
   "children": [

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/dev/wishlist.md
----------------------------------------------------------------------
diff --git a/docs/dev/wishlist.md b/docs/dev/wishlist.md
deleted file mode 100644
index 0b67989..0000000
--- a/docs/dev/wishlist.md
+++ /dev/null
@@ -1,28 +0,0 @@
----
-layout: page
-title: Wishlist
-toc: /toc.json
----
-
-This page records some of the additions planned and requested
-(approximately a roadmap).
-If you're interested in helping, scan the [issues list](https://github.com/brooklyncentral/brooklyn/issues)
-on Github for anything related,
-email the list, and get started!
-
-## Entities
-
-* WebApp PaaS:  CloudFoundry, AWS Elastic Beanstalk, Google AppEngine (OpenShift a good starting point)
-* Non-Java webapps:  PHP, Rails, Node.js, perl
-* CDN:  AWS Cloudfront, Akamai, others
-* Data:  _lots!_, including MySQL, Mongo, Couch, etc (look at building on Whirr support, like Hadoop does!)
-* More monitoring and provisioning:  Nagios, Zenoss, Cacti etc; Juju for deployment; possibly direct Puppet or Chef integration (although Whirr integration is quite powerful) 
-
-## Features
-
-* REST API for deploying, viewing, and managing, including application definitions in JSON/XML (and support for dependent configuration)
-* Distributed management plane
-* At-Rest serialization of state (likely piggy-backing on JSON/XML and datagrid support)  
-* Bind to existing entities on restart
-* Extract data from entities that are being stopped, to restore on restart (could extend MySQL example to do this)
-* Windows:  support running from windows (untested); work on installation _to_ Windows servers

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/e5e0fd8c/docs/use/guide/extras/index.md
----------------------------------------------------------------------
diff --git a/docs/use/guide/extras/index.md b/docs/use/guide/extras/index.md
index 7988046..fc194c7 100644
--- a/docs/use/guide/extras/index.md
+++ b/docs/use/guide/extras/index.md
@@ -7,9 +7,7 @@ categories: [use, guide]
 
 brooklyn comes bundled with support for a large number of systems and entities.
 
-*In this pre-release version not all entities are fully functional and that the documentation is incomplete.*
-
-*Please contact the Brooklyn Project for assistance and clarification.*
+*Some entities are in an early-access state, and documentation is incomplete. Please contact the Brooklyn Project for assistance and clarification.*
 <!---
 .. TODO fix
 .. TODO name entities
@@ -23,8 +21,8 @@ Web
 ### Clusters and Interfaces
 
 The class ``ControlledDynamicWebAppCluster`` creates a load-balanced cluster of web servers.
-It defaults to Nginx and JBoss 7, but this is configurable with the ``controller`` and 
-either the ``factory`` or ``memberSpec`` configuration options.
+It defaults to Nginx and JBoss 7, but this is configurable with the ``controller`` or ``controllerSpec``, and 
+the ``memberSpec`` configuration options.
 
 Most web app server processes, and some clusters and PaaS implementations,
 support the interface ``WebAppService`` which defines many sensors including requests per second.
@@ -93,10 +91,13 @@ Redis is a distributed key-value store, supporting master/slave replication of a
 a series of read-only slaves and a single read-write master, which propagates to the slaves with eventual consistency.
 
 
-### Infinispan
+### MongoDB
+
+
+### Cassandra
 
-Infinispan is a distributed in-memory datagrid.
 
+### CouchBase
 
 
 <a name="messaging"></a>
@@ -115,15 +116,45 @@ See ``QpidSetup`` for instantiating a broker.
 ActiveMQ support provides a JMS broker. This exposes JMS queues and topics as entities as well. See ``ActiveMQSetup`` for
 instantiating a broker.
 
+### RabbitMQ
 
 
-<a name="provisioning"></a>
-Provisioning
----------
+<a name="downstream-projects"></a>
+Downstream Projects
+-------------------
+
+Downstream projects include those below.
 
 ### Apache Whirr
 
+https://github.com/brooklyncentral/brooklyn-whirr
 
 Whirr allows running a variety of services on cloud providers and on localhost. This is done by providing a ``recipe`` which describes what services to launch. You can find an example of how Brooklyn integrates with Whirr [here](/use/examples/whirrhadoop/index.html#custom-whirr-recipe).
 
+### OpenShift
+
+https://github.com/cloudsoft/brooklyn-openshift
+
+### CloudFoundry
+
+https://github.com/cloudsoft/brooklyn-cloudfoundry and https://github.com/cloudsoft/brooklyn-cloudfoundry
+
+### MPI
+
+https://github.com/cloudsoft/brooklyn-openmpi
+
+### Waratek
+
+https://github.com/cloudsoft/brooklyn-waratek
+
+### MapR
+
+https://github.com/cloudsoft/brooklyn-mapr
+
+### Cloudera CDH
+
+https://github.com/cloudsoft/brooklyn-cdh
+
+### Drupal and Wordpress
 
+https://github.com/cloudsoft/brooklyn-social-apps


[7/8] git commit: This closes #86

Posted by he...@apache.org.
This closes #86


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

Branch: refs/heads/master
Commit: 4da7a2b432083d6935494cc361f89852638fec97
Parents: 1107f2f 0388875
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Fri Jul 25 12:42:18 2014 -0400
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Fri Jul 25 12:42:18 2014 -0400

----------------------------------------------------------------------
 .../java/brooklyn/catalog/internal/catalog.md   |  59 ----
 docs/dev/build/developers-catalog.xml           |   3 -
 docs/dev/build/index.md                         | 105 ++++---
 docs/dev/code/entity.md                         |  28 +-
 docs/dev/code/index.include.md                  |  35 ++-
 docs/dev/toc.json                               |   2 -
 docs/dev/wishlist.md                            |  28 --
 docs/start/download.md                          |   2 +-
 docs/start/index.include.md                     |   2 +-
 docs/use/examples/whirrhadoop.md                |   9 -
 docs/use/examples/whirrhadoop/index.md          |   7 -
 .../examples/whirrhadoop/whirrhadoop-w750.png   | Bin 144108 -> 0 bytes
 .../examples/whirrhadoop/whirrhadoop.include.md | 124 ---------
 docs/use/examples/whirrhadoop/whirrhadoop.png   | Bin 133771 -> 0 bytes
 docs/use/guide/entities/index.md                |   2 +-
 docs/use/guide/extras/index.md                  |  51 +++-
 examples/hadoop-and-whirr/.gitignore            |   2 -
 examples/hadoop-and-whirr/README.txt            |  51 ----
 examples/hadoop-and-whirr/pom.xml               |  97 -------
 .../main/java/brooklyn/extras/whirr/ReadMe.java |  28 --
 .../whirr/WebClusterWithHadoopExample.java      | 208 --------------
 .../whirr/WebFabricWithHadoopExample.java       | 278 -------------------
 .../brooklyn/extras/whirr/WhirrExample.java     |  71 -----
 .../extras/whirr/WhirrHadoopExample.java        |  68 -----
 examples/pom.xml                                |   1 -
 examples/simple-open-loop-policy/pom.xml        |  11 -
 examples/simple-web-cluster/pom.xml             |  11 -
 examples/webapps/hello-world-hadoop-jar/pom.xml |  60 ----
 .../brooklyn/demo/webapp/hello/DemoUtils.java   |  48 ----
 .../demo/webapp/hello/HadoopWordCount.java      | 165 -----------
 examples/webapps/hello-world-hadoop/pom.xml     |  89 ------
 .../hello/SerializeHelloWorldHadoopJar.java     |  82 ------
 .../src/main/webapp/WEB-INF/web.xml             |  26 --
 .../src/main/webapp/available.jsp               |  73 -----
 .../src/main/webapp/configure.jsp               | 122 --------
 .../hello-world-hadoop/src/main/webapp/db.jsp   | 123 --------
 .../src/main/webapp/hadoop-chat.jsp             | 112 --------
 .../src/main/webapp/hadoop-wordcount.jsp        | 121 --------
 .../src/main/webapp/images/bridge-small.png     | Bin 42335 -> 0 bytes
 .../src/main/webapp/index.html                  |  45 ---
 examples/webapps/pom.xml                        |   2 -
 .../brooklyn/location/jclouds/JcloudsUtil.java  |  17 ++
 pom.xml                                         |   3 -
 systems/whirr/base/pom.xml                      | 177 ------------
 .../extras/whirr/core/WhirrCluster.java         |  70 -----
 .../extras/whirr/core/WhirrClusterImpl.java     | 249 -----------------
 .../extras/whirr/core/WhirrInstance.java        |  46 ---
 .../extras/whirr/core/WhirrInstanceImpl.java    |  65 -----
 .../brooklyn/extras/whirr/core/WhirrRole.java   |  34 ---
 .../extras/whirr/core/WhirrRoleImpl.java        |  29 --
 .../extras/whirr/core/WhirrClusterTest.java     |  52 ----
 systems/whirr/hadoop/pom.xml                    |  62 -----
 .../extras/whirr/hadoop/WhirrHadoopCluster.java |  63 -----
 .../whirr/hadoop/WhirrHadoopClusterImpl.java    | 135 ---------
 .../hadoop/WhirrHadoopClusterLiveTest.java      |  74 -----
 .../whirr/hadoop/WhirrHadoopClusterTest.java    |  66 -----
 usage/all/pom.xml                               |  10 -
 57 files changed, 176 insertions(+), 3327 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/4da7a2b4/pom.xml
----------------------------------------------------------------------


[8/8] git commit: This closes #87

Posted by he...@apache.org.
This closes #87


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

Branch: refs/heads/master
Commit: 2a4de4d728c91d1df6ff774f6a9eea07b585fdf1
Parents: 4da7a2b 0b8a639
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Fri Jul 25 12:42:21 2014 -0400
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Fri Jul 25 12:42:21 2014 -0400

----------------------------------------------------------------------
 .../brooklyn/internal/storage/impl/BrooklynStorageImplTest.java  | 4 ++--
 .../java/brooklyn/util/internal/ssh/ShellToolAbstractTest.java   | 2 +-
 .../brooklyn/policy/loadbalancing/MockContainerEntityImpl.java   | 2 +-
 .../test/java/brooklyn/entity/database/VogellaExampleAccess.java | 3 ++-
 4 files changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------



[4/8] Deleted whirr/hadoop

Posted by he...@apache.org.
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-wordcount.jsp
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-wordcount.jsp b/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-wordcount.jsp
deleted file mode 100644
index c5ac296..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/hadoop-wordcount.jsp
+++ /dev/null
@@ -1,121 +0,0 @@
-<%@ page language="java" import="java.sql.*"%>
-
-<html>
-<!--
-    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.
--->
-<head>
-<title>Sample Application Database JSP Page</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td align=center>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed WebApp (Hadoop JSP)</h1>
-This is the output of a JSP page that is part of the Hello, World application,
-deployed by brooklyn, to show <b>a hadoop map-reduce task run<b>.
-</td>
-</tr>
-</table>
-
-<%
-String hadoopConfigUrl=System.getProperty("brooklyn.example.hadoop.site.xml.url");
-String hadoopConfigContents=System.getProperty("brooklyn.example.hadoop.site.xml.contents");
-if (hadoopConfigUrl==null && hadoopConfigContents==null) {
-%>
-    <p>There is no hadoop included as part of this example. Set brooklyn.example.hadoop.site.xml.url 
-    or brooklyn.example.hadoop.site.xml.contents to proceed.</p>
-<% } else { /* begin hadoop-enabled block */ 
-
-try {
-    org.apache.hadoop.conf.Configuration conf = new org.apache.hadoop.conf.Configuration();
-    conf.setClassLoader(brooklyn.demo.webapp.hello.HadoopWordCount.class.getClassLoader());
-    if (hadoopConfigUrl!=null) conf.addResource(new java.net.URL(hadoopConfigUrl));
-    if (hadoopConfigContents!=null) conf.addResource(new java.io.ByteArrayInputStream(hadoopConfigContents.getBytes()));
-    org.apache.hadoop.fs.FileSystem fsClient = org.apache.hadoop.fs.FileSystem.get(conf);
-    if (fsClient==null) throw new NullPointerException("Can't access fsClient");
-
-    org.apache.hadoop.mapreduce.Job job = brooklyn.demo.webapp.hello.HadoopWordCount.makeJob(conf);
-    String jar = brooklyn.demo.webapp.hello.SerializeHelloWorldHadoopJar.getJarName();
-    if (jar!=null) { ((org.apache.hadoop.mapred.JobConf)job.getConfiguration()).setJar(jar); }
-    else { %><b>JAR not available. Map-Reduce submission will likely fail.</b><% }
-    org.apache.hadoop.fs.FileStatus[] files = fsClient.listStatus(new org.apache.hadoop.fs.Path("chats"));
-    if (files==null) files = new org.apache.hadoop.fs.FileStatus[0];
-    for (org.apache.hadoop.fs.FileStatus f: files) {
-        org.apache.hadoop.mapreduce.lib.input.FileInputFormat.addInputPath(job, f.getPath());
-    }
-    
-    org.apache.hadoop.fs.Path outp = new org.apache.hadoop.fs.Path("out-"+((int)(Math.random()*10000)));
-    org.apache.hadoop.mapreduce.lib.output.FileOutputFormat.setOutputPath(job, outp);
-
-    %> <p>Running Map-Reduce... <%
-    out.flush();
-    
-    boolean result = job.waitForCompletion(true);
-    
-    %> finished: <%
-    if (!result) {
-        %> <b>Job failed.</b> Consult the logs for more information.</p> <%
-    } else {
-        %> <b>Success.</b> </p> <%
-    }
-
-    %> <p>Output from map reduce is as follows:</p> <%
-    
-    files = fsClient.listStatus(outp);
-    if (files==null) files = new org.apache.hadoop.fs.FileStatus[0];
-    for (org.apache.hadoop.fs.FileStatus f: files) {
-        try {
-            if (!f.isDir() && f.getLen()>0) {
-                %>
-                <%= f.getPath() %>:<br/>
-                <pre><%= brooklyn.demo.webapp.hello.DemoUtils.stringFromInputStream(fsClient.open(f.getPath())) %></pre>
-                <%
-            }
-        } catch (Exception e) {
-            %> Error: <%= e %><%
-        }
-    }
-    if (files.length==0) {
-    %>
-      <i>No output.</i> </li>
-    <%
-    }
-    
-    fsClient.delete(outp, true);
-    
-} catch (Exception e) {
-%>
-    <b>Error connecting to Hadoop.</b><br/>
-    ERROR: <%= e %><br/>
-    <pre> <%= brooklyn.demo.webapp.hello.DemoUtils.getStackTrace(e) %></pre>
-<%
-} 
-}
-%>
-
-    <br/>
-    <p>Click <a href="hadoop-chat.jsp">here</a> to view the chat room.</p>
-    <p>Click <a href="index.html">here</a> to go back to the main page.</p>
-
-</body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/images/bridge-small.png
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/images/bridge-small.png b/examples/webapps/hello-world-hadoop/src/main/webapp/images/bridge-small.png
deleted file mode 100644
index 4149c3c..0000000
Binary files a/examples/webapps/hello-world-hadoop/src/main/webapp/images/bridge-small.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/hello-world-hadoop/src/main/webapp/index.html
----------------------------------------------------------------------
diff --git a/examples/webapps/hello-world-hadoop/src/main/webapp/index.html b/examples/webapps/hello-world-hadoop/src/main/webapp/index.html
deleted file mode 100644
index 354aea4..0000000
--- a/examples/webapps/hello-world-hadoop/src/main/webapp/index.html
+++ /dev/null
@@ -1,45 +0,0 @@
-
-<!--
-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.
--->
-
-<html>
-<head>
-<title>Sample "Hello, World" Application</title>
-</head>
-<body bgcolor=white>
-
-<table border="0">
-<tr>
-<td>
-<img src="images/bridge-small.png">
-</td>
-<td>
-<h1>Sample Brooklyn Deployed "Hello, World" Application</h1>
-<p>This is the home page for a sample application used to illustrate 
-how web applications can be deployed to multi-cloud environments using Brooklyn.
-</td>
-</tr>
-</table>
-
-<p>
-See the available illustrations <a href="available.jsp">here</a>.
-</p>
-
-</body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/examples/webapps/pom.xml
----------------------------------------------------------------------
diff --git a/examples/webapps/pom.xml b/examples/webapps/pom.xml
index c327394..d06ed98 100644
--- a/examples/webapps/pom.xml
+++ b/examples/webapps/pom.xml
@@ -41,7 +41,5 @@
     <modules>
         <module>hello-world-webapp</module>
         <module>hello-world-sql</module>
-        <module>hello-world-hadoop-jar</module>
-        <module>hello-world-hadoop</module>
     </modules>
 </project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 19b3259..bf33198 100644
--- a/pom.xml
+++ b/pom.xml
@@ -116,7 +116,6 @@
         <logback.version>1.0.7</logback.version>
         <testng.version>6.8</testng.version>
         <mockito.version>1.9.5</mockito.version>
-        <whirr.version>0.8.1</whirr.version>
         <slf4j.version>1.6.6</slf4j.version>  <!-- used for java.util.logging jul-to-slf4j interception -->
         <xstream.version>1.4.7</xstream.version>
         <jackson.version>1.9.13</jackson.version>  <!-- codehaus jackson, used by brooklyn rest server -->
@@ -807,8 +806,6 @@
                 <module>software/nosql</module>
                 <module>software/database</module>
                 <module>software/monitoring</module>
-                <module>systems/whirr/base</module>
-                <module>systems/whirr/hadoop</module>
             </modules>
         </profile>
         <profile>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/pom.xml
----------------------------------------------------------------------
diff --git a/systems/whirr/base/pom.xml b/systems/whirr/base/pom.xml
deleted file mode 100644
index 00c9693..0000000
--- a/systems/whirr/base/pom.xml
+++ /dev/null
@@ -1,177 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-    <artifactId>brooklyn-systems-whirr</artifactId>
-    <packaging>jar</packaging>
-    <name>Brooklyn Whirr Base Entities</name>
-    <description>
-		Brooklyn entities for Whirr integration, as base classes for systems deployed via Apache Whirr
-	</description>
-
-    <parent>
-        <groupId>io.brooklyn</groupId>
-        <artifactId>brooklyn-parent</artifactId>
-        <version>0.7.0-SNAPSHOT</version>  <!-- BROOKLYN_VERSION -->
-        <relativePath>../../../pom.xml</relativePath>
-    </parent>
-
-    <dependencies>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-core</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-locations-jclouds</artifactId>
-            <version>${brooklyn.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.whirr</groupId>
-            <artifactId>whirr-core</artifactId>
-            <version>${whirr.version}</version>
-            <exclusions>
-              <!-- exclude the versions whirr pulls in, in favour of our versions -->
-              <exclusion>
-                <groupId>org.slf4j</groupId>
-                <artifactId>slf4j-api</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.slf4j</groupId>
-                <artifactId>slf4j-log4j12</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds</groupId>
-                <artifactId>jclouds-allblobstore</artifactId>
-              </exclusion> 
-              <exclusion>
-                <groupId>org.jclouds</groupId>
-                <artifactId>jclouds-compute</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds</groupId>
-                <artifactId>jclouds-scriptbuilder</artifactId>
-              </exclusion> 
-              <exclusion>
-                <groupId>org.jclouds.api</groupId>
-                <artifactId>byon</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-joda</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-netty</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>com.google.guava</groupId>
-                <artifactId>guava</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-enterprise</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-sshj</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-jsch</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds.driver</groupId>
-                <artifactId>jclouds-slf4j</artifactId>
-              </exclusion>
-              <exclusion>
-                <groupId>org.jclouds</groupId>
-                <artifactId>jclouds-allcompute</artifactId>
-              </exclusion>
-            </exclusions>
-        </dependency>
-
-        <dependency>
-            <groupId>${jclouds.groupId}.driver</groupId>
-            <artifactId>jclouds-joda</artifactId>
-            <version>${jclouds.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>${jclouds.groupId}.driver</groupId>
-            <artifactId>jclouds-netty</artifactId>
-            <version>${jclouds.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>${jclouds.groupId}.driver</groupId>
-            <artifactId>jclouds-enterprise</artifactId>
-            <version>${jclouds.version}</version>
-        </dependency>
-
-        <dependency>
-            <groupId>org.apache.whirr</groupId>
-            <artifactId>whirr-cli</artifactId>
-            <version>${whirr.version}</version>
-            <scope>test</scope>
-            <!-- you need the whirr services you actually use! cli pulls in all of them, which we want for tests -->
-            <optional>true</optional>
-            <exclusions>
-              <exclusion>
-                <groupId>org.slf4j</groupId>
-                <artifactId>slf4j-log4j12</artifactId>
-              </exclusion>
-              <exclusion>
-                <!-- solr pulls v1.6 of this in. used to break things. might be okay now (now using logback). -->
-                <groupId>org.slf4j</groupId>
-                <artifactId>jcl-over-slf4j</artifactId>
-              </exclusion>
-              <!-- Issue 469: these conflict with the servlet-api jar from brooklyn-rest -->
-              <exclusion>
-              	<artifactId>servlet-api</artifactId>
-              	<groupId>org.mortbay.jetty</groupId>
-              </exclusion>
-              <exclusion>
-              	<artifactId>servlet-api</artifactId>
-              	<groupId>javax.servlet</groupId>
-              </exclusion>
-            </exclusions>
-        </dependency>
-        
-        <dependency>
-            <groupId>${project.groupId}</groupId>
-            <artifactId>brooklyn-test-support</artifactId>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-core</artifactId>
-            <version>${project.version}</version>
-            <classifier>tests</classifier>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.whirr</groupId>
-            <artifactId>whirr-elasticsearch</artifactId>
-            <version>${whirr.version}</version>
-            <scope>test</scope>
-        </dependency>
-    </dependencies>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrCluster.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrCluster.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrCluster.java
deleted file mode 100644
index fe42591..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrCluster.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import java.util.Collection;
-
-import org.apache.whirr.Cluster;
-import org.apache.whirr.ClusterController;
-import org.apache.whirr.ClusterSpec;
-
-import brooklyn.entity.Entity;
-import brooklyn.entity.proxying.ImplementedBy;
-import brooklyn.entity.trait.Startable;
-import brooklyn.event.basic.BasicAttributeSensor;
-import brooklyn.event.basic.BasicConfigKey;
-import brooklyn.location.Location;
-import brooklyn.util.flags.SetFromFlag;
-
-import com.google.common.annotations.Beta;
-import com.google.common.annotations.VisibleForTesting;
-
-/**
- * Generic entity that can be used to deploy clusters that are
- * managed by Apache Whirr.
- *
- */
-@ImplementedBy(WhirrClusterImpl.class)
-public interface WhirrCluster extends Entity, Startable {
-
-    @SetFromFlag("recipe")
-    public static final BasicConfigKey<String> RECIPE = new BasicConfigKey<String>(
-            String.class, "whirr.recipe", "Apache Whirr cluster recipe");
-
-    public static final BasicAttributeSensor<String> CLUSTER_NAME = new BasicAttributeSensor<String>(
-            String.class, "whirr.cluster.name", "Name of the Whirr cluster");
-
-    /**
-     * Apache Whirr can only start and manage a cluster in a single location
-     *
-     * @param locations
-     */
-    @Override
-    void start(Collection<? extends Location> locations);
-
-    @Beta
-    public ClusterSpec getClusterSpec();
-
-    @Beta
-    public Cluster getCluster();
-
-    @Beta
-    @VisibleForTesting
-    public ClusterController getController();
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrClusterImpl.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrClusterImpl.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrClusterImpl.java
deleted file mode 100644
index 56206fb..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrClusterImpl.java
+++ /dev/null
@@ -1,249 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import static brooklyn.util.JavaGroovyEquivalents.groovyTruth;
-import static com.google.common.collect.Iterables.getOnlyElement;
-
-import java.io.IOException;
-import java.io.StringReader;
-import java.util.Collection;
-import java.util.Map;
-
-import org.apache.commons.configuration.ConfigurationException;
-import org.apache.commons.configuration.PropertiesConfiguration;
-import org.apache.whirr.Cluster;
-import org.apache.whirr.ClusterController;
-import org.apache.whirr.ClusterControllerFactory;
-import org.apache.whirr.ClusterSpec;
-import org.jclouds.scriptbuilder.domain.OsFamily;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.entity.Entity;
-import brooklyn.entity.basic.AbstractEntity;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.location.Location;
-import brooklyn.location.MachineLocation;
-import brooklyn.location.basic.LocalhostMachineProvisioningLocation;
-import brooklyn.location.basic.LocationConfigUtils;
-import brooklyn.location.jclouds.JcloudsLocation;
-import brooklyn.location.jclouds.JcloudsLocationConfig;
-import brooklyn.util.exceptions.Exceptions;
-
-/**
- * Generic entity that can be used to deploy clusters that are
- * managed by Apache Whirr.
- *
- */
-public class WhirrClusterImpl extends AbstractEntity implements WhirrCluster {
-
-    public static final Logger log = LoggerFactory.getLogger(WhirrClusterImpl.class);
-
-    protected ClusterController _controller = null;
-    protected ClusterSpec clusterSpec = null;
-    protected Cluster cluster = null;
-
-    protected Location location = null;
-
-    /**
-     * General entity initialisation
-     */
-    public WhirrClusterImpl() {
-    }
-    public WhirrClusterImpl(Map flags) {
-        super(flags);
-    }
-    public WhirrClusterImpl(Entity parent) {
-        super(parent);
-    }
-    public WhirrClusterImpl(Map flags, Entity parent) {
-        super(flags, parent);
-    }
-
-    @Override
-    public ClusterSpec getClusterSpec() {
-        return clusterSpec;
-    }
-    
-    @Override
-    public Cluster getCluster() {
-        return cluster;
-    }
-    
-    /**
-     * Apache Whirr can only start and manage a cluster in a single location
-     *
-     * @param locations
-     */
-    @Override
-    public void start(Collection<? extends Location> locations) {
-        location = getOnlyElement(locations);
-        try {
-            startInLocation(location);
-        } catch (Exception e) {
-            throw Exceptions.propagate(e);
-        }
-    }
-
-    protected void startInLocation(Location location) throws Exception {
-        if (location instanceof LocalhostMachineProvisioningLocation) {
-            startInLocation((LocalhostMachineProvisioningLocation)location);
-        } else if (location instanceof JcloudsLocation) {
-            startInLocation((JcloudsLocation)location);
-        } else if (location instanceof MachineLocation) {
-            startInLocation((MachineLocation)location);
-        } else {
-            throw new IllegalArgumentException("Unsupported location "+location+", when starting "+this);
-        }
-    }
-
-    /**
-     * Start a cluster as specified in the recipe on localhost
-     *
-     * @param location corresponding to localhost
-     * @throws ConfigurationException 
-     */
-    protected void startInLocation(LocalhostMachineProvisioningLocation location) throws Exception {
-
-        PropertiesConfiguration config = new PropertiesConfiguration();
-        config.load(new StringReader(getConfig(RECIPE)));
-
-        StringBuilder nodes = new StringBuilder();
-        nodes.append("nodes:\n");
-        for (int i=0; i<10; i++) {
-            String mid = (i==0?"":(""+(i+1)));
-            nodes.append("    - id: localhost"+mid+"\n");
-            nodes.append("      name: local machine "+mid+"\n");
-            nodes.append("      hostname: 127.0.0.1\n");
-            nodes.append("      os_arch: "+System.getProperty("os.arch")+"\n");
-            nodes.append("      os_family: "+OsFamily.UNIX+"\n");
-            nodes.append("      os_description: "+System.getProperty("os.name")+"\n");
-            nodes.append("      os_version: "+System.getProperty("os.version")+"\n");
-            nodes.append("      group: whirr\n");
-            nodes.append("      tags:\n");
-            nodes.append("          - local\n");
-            nodes.append("      username: "+System.getProperty("user.name")+"\n"); //NOTE: needs passwordless sudo!!!
-            nodes.append("      credential_url: file://"+System.getProperty("user.home")+"/.ssh/id_rsa\n");
-        }
-
-        //provide the BYON nodes to whirr
-        config.setProperty("jclouds.byon.nodes", nodes.toString());
-        config.setProperty(ClusterSpec.Property.LOCATION_ID.getConfigName(), "byon");
-
-        clusterSpec = new ClusterSpec(config);
-
-        clusterSpec.setServiceName("byon");
-        clusterSpec.setProvider("byon");
-        clusterSpec.setIdentity("notused");
-        clusterSpec.setCredential("notused");
-
-        log.info("Starting cluster with roles " + config.getProperty("whirr.instance-templates")
-                + " in location " + location);
-
-        startWithClusterSpec(clusterSpec,config);
-    }
-
-    /**
-     * Start a cluster as specified in the recipe in a given location
-     *
-     * @param location jclouds location spec
-     * @throws ConfigurationException 
-     */
-    protected void startInLocation(JcloudsLocation location) throws Exception {
-        PropertiesConfiguration config = new PropertiesConfiguration();
-        config.load(new StringReader(getConfig(RECIPE)));
-
-        customizeClusterSpecConfiguration(location, config);        
-
-        clusterSpec = new ClusterSpec(config);
-        clusterSpec.setProvider(location.getProvider());
-        clusterSpec.setIdentity(location.getIdentity());
-        clusterSpec.setCredential(location.getCredential());
-        // TODO inherit key data?
-        clusterSpec.setPrivateKey(LocationConfigUtils.getPrivateKeyData(location.getAllConfigBag()));
-        clusterSpec.setPublicKey(LocationConfigUtils.getPublicKeyData(location.getAllConfigBag()));
-        // TODO: also add security groups when supported in the Whirr trunk
-
-        startWithClusterSpec(clusterSpec, config);
-    }
-
-    protected void customizeClusterSpecConfiguration(JcloudsLocation location, PropertiesConfiguration config) {
-        if (groovyTruth(location.getRegion()))
-            config.setProperty(ClusterSpec.Property.LOCATION_ID.getConfigName(), location.getRegion());
-        if (groovyTruth(location.getConfig(JcloudsLocationConfig.IMAGE_ID)))
-            config.setProperty(ClusterSpec.Property.IMAGE_ID.getConfigName(), location.getConfig(JcloudsLocationConfig.IMAGE_ID));
-    }
-    
-    @Override
-    public synchronized ClusterController getController() {
-        if (_controller==null) {
-            String serviceName = (clusterSpec != null) ? clusterSpec.getServiceName() : null;
-            _controller = new ClusterControllerFactory().create(serviceName);
-        }
-        return _controller;
-    }
-
-    void startWithClusterSpec(ClusterSpec clusterSpec, PropertiesConfiguration config) throws IOException, InterruptedException {
-        log.info("Starting cluster "+this+" with roles " + config.getProperty("whirr.instance-templates")
-                + " in location " + location);
-        if (log.isDebugEnabled()) log.debug("Cluster "+this+" using recipe:\n"+getConfig(RECIPE));
-        
-        cluster = getController().launchCluster(clusterSpec);
-
-        for (Cluster.Instance instance : cluster.getInstances()) {
-            log.info("Creating group for instance " + instance.getId());
-            WhirrInstance rolesGroup = 
-                addChild(EntitySpec.create(WhirrInstance.class).
-                    displayName("Instance:" + instance.getId()).
-                    configure("instance", instance));
-            Entities.manage(rolesGroup);
-
-            for (String role: instance.getRoles()) {
-                log.info("Creating entity for '" + role + "' on instance " + instance.getId());
-                Entities.manage(rolesGroup.addChild(EntitySpec.create(WhirrRole.class).
-                        displayName("Role:" + role).
-                        configure("role", role)));
-            }
-            addGroup(rolesGroup);
-        }
-
-        setAttribute(CLUSTER_NAME, clusterSpec.getClusterName());
-        setAttribute(SERVICE_UP, true);
-    }
-
-    public void stop() {
-        if (clusterSpec != null) {
-            try {
-                getController().destroyCluster(clusterSpec);
-            } catch (Exception e) {
-                throw Exceptions.propagate(e);
-            }
-        }
-        clusterSpec = null;
-        cluster = null;
-    }
-
-    public void restart() {
-        // TODO better would be to restart the software instances, not the machines ?
-        stop();
-        start(getLocations());
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstance.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstance.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstance.java
deleted file mode 100644
index 632ba29..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstance.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import org.apache.whirr.Cluster;
-
-import brooklyn.config.ConfigKey;
-import brooklyn.entity.basic.AbstractGroup;
-import brooklyn.entity.basic.Attributes;
-import brooklyn.entity.basic.ConfigKeys;
-import brooklyn.entity.proxying.ImplementedBy;
-import brooklyn.event.AttributeSensor;
-import brooklyn.event.basic.BasicConfigKey;
-import brooklyn.util.flags.SetFromFlag;
-
-@ImplementedBy(WhirrInstanceImpl.class)
-public interface WhirrInstance extends AbstractGroup {
-
-    @SetFromFlag("role")
-    public static final ConfigKey<String> ROLE = ConfigKeys.newStringConfigKey(
-            "whirr.instance.role", "Apache Whirr instance role", null);
-
-    @SetFromFlag("instance")
-    public static final ConfigKey<Cluster.Instance> INSTANCE = new BasicConfigKey<Cluster.Instance>(
-            Cluster.Instance.class, "whirr.instance.instance", "Apache Whirr instance Cluster.Instance");
-        
-    public static final AttributeSensor<String> HOSTNAME = Attributes.HOSTNAME;
-
-    public String getRole();
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstanceImpl.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstanceImpl.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstanceImpl.java
deleted file mode 100644
index 5203e4c..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrInstanceImpl.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import java.io.IOException;
-
-import org.apache.whirr.Cluster;
-
-import brooklyn.config.ConfigKey;
-import brooklyn.entity.basic.AbstractGroupImpl;
-import brooklyn.entity.basic.Attributes;
-import brooklyn.entity.basic.ConfigKeys;
-import brooklyn.entity.trait.Changeable;
-import brooklyn.event.AttributeSensor;
-import brooklyn.util.exceptions.Exceptions;
-import brooklyn.util.flags.SetFromFlag;
-
-public class WhirrInstanceImpl extends AbstractGroupImpl implements WhirrInstance {
-
-    @SetFromFlag("role")
-    public static final ConfigKey<String> ROLE = ConfigKeys.newStringConfigKey("whirr.instance.role", "Apache Whirr instance role");
-
-    @SetFromFlag("instance")
-    public static final ConfigKey<Cluster.Instance> INSTANCE = ConfigKeys.newConfigKey(Cluster.Instance.class, "whirr.instance.instance", "Apache Whirr instance Cluster.Instance");
-        
-    public static final AttributeSensor<String> HOSTNAME = Attributes.HOSTNAME;
-
-    public WhirrInstanceImpl() {
-        super();
-    }
-    
-    @Override
-    public void init() {
-        setAttribute(Changeable.GROUP_SIZE, 0);
-        Cluster.Instance instance = getConfig(INSTANCE);
-        if (instance != null) {
-            try {
-                setAttribute(HOSTNAME, instance.getPublicHostName());
-            } catch (IOException e) {
-                throw Exceptions.propagate(e);
-            }
-        }
-    }
-    
-    @Override
-    public String getRole() {
-        return getConfig(ROLE);
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRole.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRole.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRole.java
deleted file mode 100644
index 5bde0f3..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRole.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import brooklyn.entity.Entity;
-import brooklyn.entity.proxying.ImplementedBy;
-import brooklyn.event.basic.BasicConfigKey;
-import brooklyn.util.flags.SetFromFlag;
-
-@ImplementedBy(WhirrRoleImpl.class)
-public interface WhirrRole extends Entity {
-
-    @SetFromFlag("role")
-    public static final BasicConfigKey<String> ROLE = new BasicConfigKey<String>(
-            String.class, "whirr.instance.role", "Apache Whirr instance role");
-
-    public String getRole();
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRoleImpl.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRoleImpl.java b/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRoleImpl.java
deleted file mode 100644
index d915069..0000000
--- a/systems/whirr/base/src/main/java/brooklyn/extras/whirr/core/WhirrRoleImpl.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import brooklyn.entity.basic.AbstractEntity;
-
-public class WhirrRoleImpl extends AbstractEntity implements WhirrRole {
-
-    @Override
-    public String getRole() {
-        return getConfig(ROLE);
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/base/src/test/java/brooklyn/extras/whirr/core/WhirrClusterTest.java
----------------------------------------------------------------------
diff --git a/systems/whirr/base/src/test/java/brooklyn/extras/whirr/core/WhirrClusterTest.java b/systems/whirr/base/src/test/java/brooklyn/extras/whirr/core/WhirrClusterTest.java
deleted file mode 100644
index 96efcf7..0000000
--- a/systems/whirr/base/src/test/java/brooklyn/extras/whirr/core/WhirrClusterTest.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.core;
-
-import org.testng.Assert;
-import org.testng.annotations.AfterMethod;
-import org.testng.annotations.BeforeMethod;
-import org.testng.annotations.Test;
-
-import brooklyn.entity.basic.ApplicationBuilder;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.test.entity.TestApplication;
-
-public class WhirrClusterTest {
-
-    private TestApplication app;
-    private WhirrCluster entity;
-
-    @BeforeMethod(alwaysRun=true)
-    public void setUp() throws Exception {
-        app = ApplicationBuilder.newManagedApp(TestApplication.class);
-        entity = app.createAndManageChild(EntitySpec.create(WhirrCluster.class));
-    }
-    
-    @AfterMethod(alwaysRun=true)
-    public void tearDown() throws Exception {
-        if (app != null) Entities.destroyAll(app.getManagementContext());
-    }
-    
-    @Test
-    public void testControllerInitialized() {
-        Assert.assertNotNull(entity.getController());
-    }
-    
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/hadoop/pom.xml
----------------------------------------------------------------------
diff --git a/systems/whirr/hadoop/pom.xml b/systems/whirr/hadoop/pom.xml
deleted file mode 100644
index 414b2f7..0000000
--- a/systems/whirr/hadoop/pom.xml
+++ /dev/null
@@ -1,62 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-    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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-	<modelVersion>4.0.0</modelVersion>
-	<artifactId>brooklyn-systems-hadoop</artifactId>
-	<packaging>jar</packaging>
-	<name>Brooklyn Hadoop System Entities</name>
-	<description>
-		Brooklyn entities for Hadoop systems deployed using Whirr
-	</description>
-
-	<parent>
-		<groupId>io.brooklyn</groupId>
-		<artifactId>brooklyn-parent</artifactId>
-		<version>0.7.0-SNAPSHOT</version>  <!-- BROOKLYN_VERSION -->
-		<relativePath>../../../pom.xml</relativePath>
-	</parent>
-
-	<dependencies>
-		<dependency>
-			<groupId>io.brooklyn</groupId>
-			<artifactId>brooklyn-systems-whirr</artifactId>
-            <version>${project.version}</version>
-		</dependency>
-        <dependency>
-            <groupId>org.apache.whirr</groupId>
-            <artifactId>whirr-hadoop</artifactId>
-            <version>${whirr.version}</version>
-        </dependency>
-        
-        <dependency>
-            <groupId>${project.groupId}</groupId>
-            <artifactId>brooklyn-test-support</artifactId>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-core</artifactId>
-            <version>${project.version}</version>
-            <classifier>tests</classifier>
-            <scope>test</scope>
-        </dependency>
-	</dependencies>
-
-</project>

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopCluster.java
----------------------------------------------------------------------
diff --git a/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopCluster.java b/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopCluster.java
deleted file mode 100644
index 08fde01..0000000
--- a/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopCluster.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.hadoop;
-
-import java.util.List;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.entity.proxying.ImplementedBy;
-import brooklyn.event.basic.BasicAttributeSensor;
-import brooklyn.event.basic.BasicConfigKey;
-import brooklyn.extras.whirr.core.WhirrCluster;
-import brooklyn.util.flags.SetFromFlag;
-
-@ImplementedBy(WhirrHadoopClusterImpl.class)
-public interface WhirrHadoopCluster extends WhirrCluster {
-
-    public static final Logger log = LoggerFactory.getLogger(WhirrHadoopCluster.class);
-
-    @SetFromFlag("name")
-    public static final BasicConfigKey<String> NAME = new BasicConfigKey<String>(
-            String.class, "whirr.hadoop.name", "The name of the Hadoop cluster");
-
-    @SetFromFlag("size")
-    public static final BasicConfigKey<Integer> SIZE = new BasicConfigKey<Integer>(
-            Integer.class, "whirr.hadoop.size", "The size of the Hadoop cluster (including a dedicated machine for the namenode)", 2);
-
-    @SetFromFlag("memory")
-    public static final BasicConfigKey<Integer> MEMORY = new BasicConfigKey<Integer>(
-            Integer.class, "whirr.hadoop.memory", "The minimum amount of memory to use for each node (in megabytes)", 1024);
-
-    public static final BasicAttributeSensor<String> NAME_NODE_URL = new BasicAttributeSensor<String>(
-            String.class, "whirr.hadoop.namenodeUrl", "URL for the Hadoop name node in this cluster (hdfs://...)");
-
-    public static final BasicAttributeSensor<String> JOB_TRACKER_HOST_PORT = new BasicAttributeSensor<String>(
-            String.class, "whirr.hadoop.jobtrackerHostPort", "Hadoop Jobtracker host and port");
-
-    public static final BasicAttributeSensor<String> SOCKS_SERVER = new BasicAttributeSensor<String>(
-            String.class, "whirr.hadoop.socks.server", "Local SOCKS server connection details");
-
-    public void generateWhirrClusterRecipe();
-    
-    public List<String> getUserRecipeLines();
-    
-    public void addRecipeLine(String line);
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterImpl.java
----------------------------------------------------------------------
diff --git a/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterImpl.java b/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterImpl.java
deleted file mode 100644
index 2cff6b8..0000000
--- a/systems/whirr/hadoop/src/main/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterImpl.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.hadoop;
-
-import static brooklyn.util.JavaGroovyEquivalents.elvis;
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.io.IOException;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.whirr.RolePredicates;
-import org.apache.whirr.service.hadoop.HadoopProxy;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-import brooklyn.entity.Entity;
-import brooklyn.extras.whirr.core.WhirrClusterImpl;
-import brooklyn.location.Location;
-import brooklyn.util.collections.MutableMap;
-import brooklyn.util.exceptions.Exceptions;
-
-import com.google.common.base.Joiner;
-import com.google.common.base.Preconditions;
-import com.google.common.base.Strings;
-import com.google.common.collect.ImmutableList;
-import com.google.common.collect.Lists;
-
-public class WhirrHadoopClusterImpl extends WhirrClusterImpl implements WhirrHadoopCluster {
-
-    public static final Logger log = LoggerFactory.getLogger(WhirrHadoopClusterImpl.class);
-
-    protected HadoopProxy proxy = null;
-
-    protected final List<String> userRecipeLines = Collections.synchronizedList(Lists.<String>newArrayList());
-
-    public WhirrHadoopClusterImpl() {
-        super();
-    }
-
-    public WhirrHadoopClusterImpl(Map flags) {
-        this(flags, null);
-    }
-
-    public WhirrHadoopClusterImpl(Entity parent) {
-        super(MutableMap.of(), parent);
-    }
-
-    public WhirrHadoopClusterImpl(Map flags, Entity parent) {
-        super(flags, parent);
-    }
-    
-    @Override
-    public void init() {
-        generateWhirrClusterRecipe();
-    }
-
-    @Override
-    public void generateWhirrClusterRecipe() {
-        Preconditions.checkArgument(getConfig(SIZE) > 1, "Min cluster size is 2");
-        Preconditions.checkArgument(getConfig(MEMORY) >= 1000, "We need at least 1GB of memory per machine");
-
-        List<String> recipeLines = Lists.newArrayList(
-                "whirr.cluster-name=" + elvis((String)getConfig(NAME), "brooklyn-whirr-cluster").replaceAll("\\s+","-"),
-                "whirr.instance-templates=1 hadoop-namenode+hadoop-jobtracker, "
-                        + (getConfig(SIZE) - 1) + " hadoop-datanode+hadoop-tasktracker",
-                "whirr.hardware-min-ram=" + getConfig(MEMORY)
-                // TODO: set whirr.hadoop.tarball.url=... to a reliable location
-        );
-
-        if (userRecipeLines.size() > 0) recipeLines.addAll(userRecipeLines);
-        setConfig(RECIPE, Joiner.on("\n").join(recipeLines));
-    }
-    
-    @Override
-    public List<String> getUserRecipeLines() {
-        synchronized (userRecipeLines) {
-            return ImmutableList.copyOf(userRecipeLines);
-        }
-    }
-    
-    @Override
-    public void addRecipeLine(String line) {
-        userRecipeLines.add(checkNotNull(line, "line"));
-        String r = elvis(getConfig(RECIPE), "");
-        if (!Strings.isNullOrEmpty(r)) r += "\n";
-        r += line;
-        setConfig(RECIPE, r);
-    }
-
-    @Override
-    public void start(Collection<? extends Location> locations) {
-        super.start(locations);
-
-        log.info("Starting local SOCKS proxy on port 6666 ...");
-        proxy = new HadoopProxy(clusterSpec, cluster);
-        try {
-            proxy.start();
-    
-            setAttribute(SOCKS_SERVER, "localhost:6666");
-    
-            String namenodeHost = cluster.getInstanceMatching(RolePredicates.role("hadoop-namenode")).getPublicHostName();
-            setAttribute(NAME_NODE_URL, "hdfs://" + namenodeHost + ":8020/");
-    
-            String jobtrackerHost = cluster.getInstanceMatching(RolePredicates.role("hadoop-jobtracker")).getPublicHostName();
-            setAttribute(JOB_TRACKER_HOST_PORT, jobtrackerHost + ":8021");
-        } catch (IOException e) {
-            throw Exceptions.propagate(e);
-        }
-    }
-
-    @Override
-    public void stop() {
-        if (proxy != null) proxy.stop();
-        super.stop();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterLiveTest.java
----------------------------------------------------------------------
diff --git a/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterLiveTest.java b/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterLiveTest.java
deleted file mode 100644
index 9623d2f..0000000
--- a/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterLiveTest.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.hadoop;
-
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.testng.annotations.AfterMethod;
-import org.testng.annotations.BeforeMethod;
-import org.testng.annotations.Test;
-
-import brooklyn.config.BrooklynProperties;
-import brooklyn.entity.basic.ApplicationBuilder;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.location.Location;
-import brooklyn.management.internal.LocalManagementContext;
-import brooklyn.test.entity.TestApplication;
-
-import com.google.common.collect.ImmutableList;
-
-public class WhirrHadoopClusterLiveTest {
-
-    private static final Logger log = LoggerFactory.getLogger(WhirrHadoopClusterLiveTest.class);
-    
-    public static final String PROVIDER = "aws-ec2";
-    public static final String LOCATION_SPEC = "jclouds:"+PROVIDER;
-    
-    protected TestApplication app;
-    protected Location jcloudsLocation;
-    private BrooklynProperties brooklynProperties;
-    private LocalManagementContext ctx;
-    
-    @BeforeMethod(alwaysRun=true)
-    public void setUp() throws Exception {
-        brooklynProperties = BrooklynProperties.Factory.newDefault();
-        ctx = new LocalManagementContext(brooklynProperties);
-        app = ApplicationBuilder.newManagedApp(TestApplication.class, ctx);
-    }
-
-    @AfterMethod(alwaysRun=true)
-    public void tearDown() throws Exception {
-        if (app != null) Entities.destroyAllCatching(app.getManagementContext());
-    }
-
-    @Test(groups = { "Live" })
-    public void testAwsRollout() {
-        try {
-            //final WhirrHadoopCluster hadoop = 
-            app.createAndManageChild(EntitySpec.create(WhirrHadoopCluster.class));
-            Location loc = ctx.getLocationRegistry().resolve(LOCATION_SPEC);
-            app.start(ImmutableList.of(loc));
-        } finally {
-            log.info("completed AWS Hadoop test: "+app.getAllAttributes());
-            Entities.dumpInfo(app);
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterTest.java
----------------------------------------------------------------------
diff --git a/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterTest.java b/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterTest.java
deleted file mode 100644
index a893be7..0000000
--- a/systems/whirr/hadoop/src/test/java/brooklyn/extras/whirr/hadoop/WhirrHadoopClusterTest.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * 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.
- */
-package brooklyn.extras.whirr.hadoop;
-
-import org.testng.annotations.AfterMethod;
-import org.testng.annotations.BeforeMethod;
-import org.testng.annotations.Test;
-
-import brooklyn.entity.basic.ApplicationBuilder;
-import brooklyn.entity.basic.Entities;
-import brooklyn.entity.proxying.EntitySpec;
-import brooklyn.test.entity.TestApplication;
-import brooklyn.util.exceptions.Exceptions;
-
-public class WhirrHadoopClusterTest {
-
-    private TestApplication app;
-
-    @BeforeMethod(alwaysRun=true)
-    public void setUp() throws Exception {
-        app = ApplicationBuilder.newManagedApp(TestApplication.class);
-    }
-    
-    @AfterMethod(alwaysRun=true)
-    public void tearDown() throws Exception {
-        if (app != null) Entities.destroyAll(app.getManagementContext());
-    }
-    
-    @Test
-    public void testSizeTooSmall() throws Exception {
-        try {
-            WhirrHadoopCluster whc = app.createAndManageChild(EntitySpec.create(WhirrHadoopCluster.class)
-                    .configure("size", 1));
-        } catch (Exception e) {
-            IllegalArgumentException iae = Exceptions.getFirstThrowableOfType(e, IllegalArgumentException.class);
-            if (iae != null && iae.toString().contains("Min cluster size is 2")) {
-                // success
-            } else {
-                throw e;
-            }
-        }
-    }
-
-    @Test
-    public void testDefaultsDontFailInRecipeGeneration() throws Exception {
-        WhirrHadoopCluster whc = app.createAndManageChild(EntitySpec.create(WhirrHadoopCluster.class));
-        whc.generateWhirrClusterRecipe();
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/03888755/usage/all/pom.xml
----------------------------------------------------------------------
diff --git a/usage/all/pom.xml b/usage/all/pom.xml
index 12f66c1..d1efaf6 100644
--- a/usage/all/pom.xml
+++ b/usage/all/pom.xml
@@ -92,16 +92,6 @@
 
         <dependency>
             <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-systems-whirr</artifactId>
-            <version>${project.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
-            <artifactId>brooklyn-systems-hadoop</artifactId>
-            <version>${project.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>io.brooklyn</groupId>
             <artifactId>brooklyn-launcher</artifactId>
             <version>${project.version}</version>
         </dependency>


[2/8] git commit: Remove whirr docs

Posted by he...@apache.org.
Remove whirr docs


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

Branch: refs/heads/master
Commit: b5ea764d22f3faa5602a2c6e38711a255b7972c6
Parents: e5e0fd8
Author: Aled Sage <al...@gmail.com>
Authored: Mon Jul 21 17:47:31 2014 +0100
Committer: Aled Sage <al...@gmail.com>
Committed: Tue Jul 22 12:37:04 2014 +0100

----------------------------------------------------------------------
 docs/dev/build/developers-catalog.xml           |   3 -
 docs/start/download.md                          |   2 +-
 docs/start/index.include.md                     |   2 +-
 docs/use/examples/whirrhadoop.md                |   9 --
 docs/use/examples/whirrhadoop/index.md          |   7 --
 .../examples/whirrhadoop/whirrhadoop-w750.png   | Bin 144108 -> 0 bytes
 .../examples/whirrhadoop/whirrhadoop.include.md | 124 -------------------
 docs/use/examples/whirrhadoop/whirrhadoop.png   | Bin 133771 -> 0 bytes
 docs/use/guide/entities/index.md                |   2 +-
 9 files changed, 3 insertions(+), 146 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/dev/build/developers-catalog.xml
----------------------------------------------------------------------
diff --git a/docs/dev/build/developers-catalog.xml b/docs/dev/build/developers-catalog.xml
index 01993c3..03ea03c 100644
--- a/docs/dev/build/developers-catalog.xml
+++ b/docs/dev/build/developers-catalog.xml
@@ -91,14 +91,11 @@
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-simple-web-cluster/0.7.0-SNAPSHOT/brooklyn-example-simple-web-cluster-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->   
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-global-web-fabric/0.7.0-SNAPSHOT/brooklyn-example-global-web-fabric-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->        
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-global-web-fabric/0.7.0-SNAPSHOT/brooklyn-example-global-web-fabric-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
-      <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-hello-world-hadoop-webapp/0.7.0-SNAPSHOT/brooklyn-example-hello-world-hadoop-webapp-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-portable-cloudfoundry/0.7.0-SNAPSHOT/brooklyn-example-portable-cloudfoundry-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-simple-web-cluster/0.7.0-SNAPSHOT/brooklyn-example-simple-web-cluster-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
-      <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-hadoop-and-whirr/0.7.0-SNAPSHOT/brooklyn-example-hadoop-and-whirr-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-hello-world-sql-webapp/0.7.0-SNAPSHOT/brooklyn-example-hello-world-sql-webapp-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-simple-messaging-pubsub/0.7.0-SNAPSHOT/brooklyn-example-simple-messaging-pubsub-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-examples-parent/0.7.0-SNAPSHOT/brooklyn-examples-parent-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
-      <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-hello-world-hadoop-jar/0.7.0-SNAPSHOT/brooklyn-example-hello-world-hadoop-jar-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-hello-world-webapp/0.7.0-SNAPSHOT/brooklyn-example-hello-world-webapp-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-example-simple-nosql-cluster/0.7.0-SNAPSHOT/brooklyn-example-simple-nosql-cluster-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->
       <entry>file://~/.m2/repository/io/brooklyn/example/brooklyn-examples-webapps-parent/0.7.0-SNAPSHOT/brooklyn-examples-webapps-parent-0.7.0-SNAPSHOT.jar</entry> <!--  BROOKLYN_VERSION  -->

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/start/download.md
----------------------------------------------------------------------
diff --git a/docs/start/download.md b/docs/start/download.md
index 9056e68..23c740c 100644
--- a/docs/start/download.md
+++ b/docs/start/download.md
@@ -132,7 +132,7 @@ If you use Maven, you can add Brooklyn with the following in your pom:
     </dependencies>
 {% endhighlight %}
 
-`brooklyn-all` (used above) brings in all dependencies, including jclouds and Apache Whirr.
+`brooklyn-all` (used above) brings in all dependencies, including jclouds.
 If you prefer a smaller repo you might want just ``brooklyn-core``,  ``brooklyn-policies``, 
 and some of ``brooklyn-software-webapp``,  ``brooklyn-software-database``, ``brooklyn-software-messaging``, or others
 (browse the full list [here]({{ this_anything_url_search }})).

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/start/index.include.md
----------------------------------------------------------------------
diff --git a/docs/start/index.include.md b/docs/start/index.include.md
index d0dad1e..1406337 100644
--- a/docs/start/index.include.md
+++ b/docs/start/index.include.md
@@ -7,7 +7,7 @@ giving single-click deploy and adding the concepts of
 manageable clusters and fabrics:
 
 * many common software entities available out-of-the-box
-* integrates with [Apache Whirr](http://whirr.apache.org) -- and thereby Chef and Puppet --
+* integrates with [Apache Whirr](http://whirr.apache.org) 
   to deploy well-known services such as Hadoop and elasticsearch
   (or use POBS, plain-old-bash-scripts)
 * use PaaS's such as OpenShift, alongside self-built clusters, for maximum flexibility

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/examples/whirrhadoop.md
----------------------------------------------------------------------
diff --git a/docs/use/examples/whirrhadoop.md b/docs/use/examples/whirrhadoop.md
deleted file mode 100644
index d7d610f..0000000
--- a/docs/use/examples/whirrhadoop.md
+++ /dev/null
@@ -1,9 +0,0 @@
----
-layout: page
-title: Whirr Hadoop Cluster
-toc: /toc.json
----
-
-<!-- file kept to preserve old links; remove when link not used -->
-
-{% readj whirrhadoop/whirrhadoop.include.md %}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/examples/whirrhadoop/index.md
----------------------------------------------------------------------
diff --git a/docs/use/examples/whirrhadoop/index.md b/docs/use/examples/whirrhadoop/index.md
deleted file mode 100644
index 644acd3..0000000
--- a/docs/use/examples/whirrhadoop/index.md
+++ /dev/null
@@ -1,7 +0,0 @@
----
-layout: page
-title: Whirr Hadoop Cluster
-toc: /toc.json
----
-
-{% readj whirrhadoop.include.md %}

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/examples/whirrhadoop/whirrhadoop-w750.png
----------------------------------------------------------------------
diff --git a/docs/use/examples/whirrhadoop/whirrhadoop-w750.png b/docs/use/examples/whirrhadoop/whirrhadoop-w750.png
deleted file mode 100644
index 6c35d3e..0000000
Binary files a/docs/use/examples/whirrhadoop/whirrhadoop-w750.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/examples/whirrhadoop/whirrhadoop.include.md
----------------------------------------------------------------------
diff --git a/docs/use/examples/whirrhadoop/whirrhadoop.include.md b/docs/use/examples/whirrhadoop/whirrhadoop.include.md
deleted file mode 100644
index fa54bfb..0000000
--- a/docs/use/examples/whirrhadoop/whirrhadoop.include.md
+++ /dev/null
@@ -1,124 +0,0 @@
-{% readj ../before-begin.include.md %}
-
-Now, go to this particular example's directory:
-
-{% highlight bash %}
-% cd hadoop-and-whirr
-{% endhighlight %}
-
-The CLI needs to know where to find your compiled examples. You can set this up by exporting
-the ``BROOKLYN_CLASSPATH`` environment variable in the following way:
-
-{% highlight bash %}
-% export BROOKLYN_CLASSPATH=$(pwd)/target/classes
-{% endhighlight %}
-
-The project ``hadoop-and-whirr`` includes deployment descriptors
-showing how to provision Whirr-based clusters from Brooklyn,
-including setting up a Hadoop recipe.
-
-## Background
-
-[Apache Whirr](http://whirr.apache.org) is an open-source project providing
-a set of libraries for launching cloud services in an easy, repeatable, and reliable way.
-
-Brooklyn can use Whirr to launch a wide variety of services
-and integrate them as part of bespoke applications.
-
-
-## Whirr Hadoop
-
-The class ``WhirrHadoopExample`` shows how a Hadoop cluster can be started
-with an arbitrary size, using the ``WhirrHadoopCluster`` entity.
-
-{% highlight java %}
-public class WhirrHadoopExample extends AbstractApplication {
-    @Override
-    public void init() {
-        WhirrCluster cluster = addChild(EntitySpec.create(WhirrHadoopCluster.class)
-                .configure("size", 2)
-                .configure("memory", 2048));
-    }
-}
-{% endhighlight %}
-
-You can run this by running:
-
-{% highlight bash %}
-% ${BROOKLYN_HOME}/bin/brooklyn launch --app brooklyn.extras.whirr.WhirrHadoopExample --stopOnKeyPress --location aws-ec2:eu-west-1
-{% endhighlight %}
-
-This targets ``aws-ec2:eu-west-1`` (using jclouds),
-so you will need to set your AWS credentials as described [here]({{site.url}}/use/guide/management/index.html#startup-config). 
-
-[![Web Console Showing Whirr-launched Hadoop Cluster](whirrhadoop-w750.png "Web Console Showing Whirr-launched Hadoop Cluster")](whirrhadoop.png) 
-
-Once it is running, navigate to the Brooklyn web console to see the ``NAME_NODE_URL`` sensor.
-(And note that using [``attributeWhenReady``]({{ site.url }}/use/guide/defining-applications/advanced-concepts.html#dependent), 
-you can easily configure a larger application to use its own dedicated Hadoop cluster.)
-
-
-<a name="custom-whirr-recipe"></a>
-## Custom Whirr Recipe
-
-The class ``WhirrExample`` shows how an arbitrary [Whirr](http://whirr.apache.org) recipe
-can be run from within Brooklyn:
-
-{% highlight java %}
-public class WhirrExample extends AbstractApplication {
-    public static final String RECIPE =
-            "whirr.cluster-name=brooklyn-whirr"+"\n"+
-            "whirr.hardware-min-ram=1024"+"\n"+
-            "whirr.instance-templates=1 noop, 1 elasticsearch"+"\n";
-
-    @Override
-    public void init() {
-        WhirrCluster cluster = addChild(EntitySpec.create(WhirrCluster.class)
-                .configure("recipe", RECIPE));
-    }
-}
-{% endhighlight %}
-
-As this example uses elasticsearch, the elasticsearch jar will need to be added to the classpath. If you are using elasticsearch in your own project, you will also need to add it as a dependency in your pom.xml. For an example see the brooklyn-examples/hadoop-and-whirr/pom.xml
-
-{% highlight bash %}
-% export BROOKLYN_CLASSPATH=~/.m2/repository/org/apache/whirr/whirr-elasticsearch/0.8.1/whirr-elasticsearch-0.8.1.jar:$BROOKLYN_CLASSPATH
-{% endhighlight %} 
-
-This can be launched by running:
-
-{% highlight bash %}
-% ${BROOKLYN_HOME}/bin/brooklyn launch --app brooklyn.extras.whirr.WhirrExample --stopOnKeyPress --location aws-ec2:eu-west-1
-{% endhighlight %} 
-
-In the provided example this will deploy to AWS.
-
-If you would like to deploy to localhost, you can do this by running the same command and replacing ``aws-ec2:eu-west-1`` with ``localhost``. However, please note that currently there are some limitations when deploying to localhost:
-
-*	You can not deploy more than one server (noop doesn't count in the above case).
-*	This has only been tested on Ubuntu 10.04 and might cause problems on other operating systems.
-*	Your user will need to be configured for [passwordless ssh and passwordless sudo](http://docs.outerthought.org/lilyenterprise-docs-trunk/539-lily/541-lily.html) on localhost.
-
-
-Feel free to experiment with the instance template parameter,
-trying out other recipes from Whirr.
-
-With this mechanism, you can roll out Whirr-supported systems, 
-ranging from Cassandra to Voldemort, including integrating 
-Chef and Puppet scripts you may wish to use.
-The Whirr state is loaded into Brooklyn, as well as saved to disk in the usual Whirr way.
-This means it is available for programmatic extensions (as is used for Hadoop),
-including defining sensors and effectors and applying policy:
-stop is available, with [resize](https://issues.apache.org/jira/browse/WHIRR-214) expected soon
-(making it easy -- or at least much easier -- to write custom **elasticity policies**).
-
-
-## Integrating with Other Entities
-
-The real interest of Brooklyn working with Whirr, of course, is to combine systems such as Hadoop
-with your custom applications which use these systems.
-One example, combining the [Global Web Fabric example]({{ site.url }}/use/examples/global-web-fabric)
-with the Whirr Hadoop entity, is included in this example project.
-A Hadoop-based chatroom web app, performing map-reduce (and a few necessary contortions to work with private subnets)
-is in ``WebFabricWithHadoopExample``. 
- 

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/examples/whirrhadoop/whirrhadoop.png
----------------------------------------------------------------------
diff --git a/docs/use/examples/whirrhadoop/whirrhadoop.png b/docs/use/examples/whirrhadoop/whirrhadoop.png
deleted file mode 100644
index 9d6cd5e..0000000
Binary files a/docs/use/examples/whirrhadoop/whirrhadoop.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/b5ea764d/docs/use/guide/entities/index.md
----------------------------------------------------------------------
diff --git a/docs/use/guide/entities/index.md b/docs/use/guide/entities/index.md
index 40339bc..54ea317 100644
--- a/docs/use/guide/entities/index.md
+++ b/docs/use/guide/entities/index.md
@@ -123,7 +123,7 @@ In the implementations of ``JavaWebApp`` entities, the behaviour which the entit
 Routines which are convenient for specific drivers can then be inherited in the driver class hierarchy. For example, when passing JMX environment variables to Java over SSH, ``JavaSoftwareProcessSshDriver`` extends ``AbstractSoftwareProcessSshDriver`` and parents ``JBoss7SshDriver``.
 
 <!---
-TODO more drivers such as whirr, jmx, etc are planned
+TODO more drivers such as jmx, etc are planned
 -->
 
 <a name="testing"></a>