Rename ByonLocation's attribute osfamily to osFamily
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/c1f3985c Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/c1f3985c Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/c1f3985c Branch: refs/heads/master Commit: c1f3985cf1557b4c614af0cc7f2f48e7035f6aa6 Parents: c64f7f0 Author: Valentin Aitken <[email protected]> Authored: Fri Aug 21 19:18:20 2015 +0300 Committer: Valentin Aitken <[email protected]> Committed: Fri Aug 28 10:52:47 2015 +0300 ---------------------------------------------------------------------- .../apache/brooklyn/location/byon/ByonLocationResolver.java | 8 ++++---- .../brooklyn/location/byon/ByonLocationResolverTest.java | 4 ++-- docs/guide/ops/locations/index.md | 2 +- .../software/base/AbstractSoftwareProcessWinRmDriver.java | 2 +- .../apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java | 6 +++--- 5 files changed, 11 insertions(+), 11 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c1f3985c/core/src/main/java/org/apache/brooklyn/location/byon/ByonLocationResolver.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/brooklyn/location/byon/ByonLocationResolver.java b/core/src/main/java/org/apache/brooklyn/location/byon/ByonLocationResolver.java index bef0046..7245faf 100644 --- a/core/src/main/java/org/apache/brooklyn/location/byon/ByonLocationResolver.java +++ b/core/src/main/java/org/apache/brooklyn/location/byon/ByonLocationResolver.java @@ -70,7 +70,7 @@ public class ByonLocationResolver extends AbstractLocationResolver { public static final String BYON = "byon"; - public static final ConfigKey<String> OS_FAMILY = ConfigKeys.newStringConfigKey("osfamily", "OS Family of the machine, either windows or linux", "linux"); + public static final ConfigKey<String> OS_FAMILY = ConfigKeys.newStringConfigKey("osFamily", "OS Family of the machine, either windows or linux", "linux"); public static final Map<String, Class<? extends MachineLocation>> OS_TO_MACHINE_LOCATION_TYPE = ImmutableMap.<String, Class<? extends MachineLocation>>of( "windows", WinRmMachineLocation.class, @@ -147,7 +147,7 @@ public class ByonLocationResolver extends AbstractLocationResolver { Map<String, Object> valSanitized = Sanitizer.sanitize(vals); Map<String, Object> machineConfig = MutableMap.copyOf(vals); - String osfamily = (String) machineConfig.remove(OS_FAMILY.getName()); + String osFamily = (String) machineConfig.remove(OS_FAMILY.getName()); String ssh = (String) machineConfig.remove("ssh"); String winrm = (String) machineConfig.remove("winrm"); Map<Integer, String> tcpPortMappings = (Map<Integer, String>) machineConfig.get("tcpPortMappings"); @@ -199,8 +199,8 @@ public class ByonLocationResolver extends AbstractLocationResolver { } Class<? extends MachineLocation> locationClassHere = locationClass; - if (osfamily != null) { - locationClassHere = getLocationClass(osfamily); + if (osFamily != null) { + locationClassHere = getLocationClass(osFamily); } return LocationSpec.create(locationClassHere).configure(machineConfig); http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c1f3985c/core/src/test/java/org/apache/brooklyn/location/byon/ByonLocationResolverTest.java ---------------------------------------------------------------------- diff --git a/core/src/test/java/org/apache/brooklyn/location/byon/ByonLocationResolverTest.java b/core/src/test/java/org/apache/brooklyn/location/byon/ByonLocationResolverTest.java index 51120e0..05102a5 100644 --- a/core/src/test/java/org/apache/brooklyn/location/byon/ByonLocationResolverTest.java +++ b/core/src/test/java/org/apache/brooklyn/location/byon/ByonLocationResolverTest.java @@ -345,7 +345,7 @@ public class ByonLocationResolverTest { String spec = "byon"; Map<String, ?> flags = ImmutableMap.of( "hosts", ImmutableList.of("1.1.1.1", "2.2.2.2"), - "osfamily", osFamily + "osFamily", osFamily ); MachineProvisioningLocation<MachineLocation> provisioner = resolve(spec, flags); WinRmMachineLocation location = (WinRmMachineLocation) provisioner.obtain(ImmutableMap.of()); @@ -360,7 +360,7 @@ public class ByonLocationResolverTest { String spec = "byon"; Map<String, ?> flags = ImmutableMap.of( "hosts", ImmutableList.of("1.1.1.1", "2.2.2.2"), - "osfamily", "linux" + "osFamily", "linux" ); MachineProvisioningLocation<MachineLocation> provisioner = resolve(spec, flags); MachineLocation location = provisioner.obtain(ImmutableMap.of()); http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c1f3985c/docs/guide/ops/locations/index.md ---------------------------------------------------------------------- diff --git a/docs/guide/ops/locations/index.md b/docs/guide/ops/locations/index.md index 367b774..9fb5572 100644 --- a/docs/guide/ops/locations/index.md +++ b/docs/guide/ops/locations/index.md @@ -418,7 +418,7 @@ location: privateAddresses: [10.0.0.2] password: mypassword user: myuser - osfamily: windows + osFamily: windows {% endhighlight %} The BYON location also supports a machine chooser, using the config key `byon.machineChooser`. http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c1f3985c/software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java ---------------------------------------------------------------------- diff --git a/software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java b/software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java index f5d441d..2587833 100644 --- a/software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java +++ b/software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java @@ -46,7 +46,7 @@ import java.util.concurrent.Callable; import java.util.concurrent.TimeUnit; public abstract class AbstractSoftwareProcessWinRmDriver extends AbstractSoftwareProcessDriver { - private static final Logger LOG = LoggerFactory.getLogger(AbstractSoftwareProcessDriver.class); + private static final Logger LOG = LoggerFactory.getLogger(AbstractSoftwareProcessWinRmDriver.class); AttributeSensor<String> WINDOWS_USERNAME = Sensors.newStringSensor("windows.username", "Default Windows username to be used when connecting to the Entity's VM"); http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c1f3985c/usage/camp/src/test/java/org/apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java ---------------------------------------------------------------------- diff --git a/usage/camp/src/test/java/org/apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java b/usage/camp/src/test/java/org/apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java index 8a012d4..42db9ec 100644 --- a/usage/camp/src/test/java/org/apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java +++ b/usage/camp/src/test/java/org/apache/brooklyn/camp/brooklyn/ByonLocationsYamlTest.java @@ -109,7 +109,7 @@ public class ByonLocationsYamlTest extends AbstractYamlTest { " password: mypassword", " user: myuser", " mykey: myval", - " osfamily: windows", + " osFamily: windows", "services:", "- serviceType: org.apache.brooklyn.entity.stock.BasicApplication"); @@ -146,7 +146,7 @@ public class ByonLocationsYamlTest extends AbstractYamlTest { " password: mypassword", " user: myuser", " mykey: myval3", - " osfamily: windows", + " osFamily: windows", "services:", "- serviceType: org.apache.brooklyn.entity.stock.BasicApplication"); @@ -194,7 +194,7 @@ public class ByonLocationsYamlTest extends AbstractYamlTest { " password: mypassword", " user: myuser", " mykey: myval2", - " osfamily: windows", + " osFamily: windows", "services:", "- serviceType: org.apache.brooklyn.entity.stock.BasicApplication");
