You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by al...@apache.org on 2014/12/24 12:18:28 UTC
[1/3] incubator-brooklyn git commit: BROOKLYN-108: use right
installDir on rebind
Repository: incubator-brooklyn
Updated Branches:
refs/heads/master 4a5072e52 -> 16d0b8877
BROOKLYN-108: use right installDir on rebind
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/c0e49b24
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/c0e49b24
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/c0e49b24
Branch: refs/heads/master
Commit: c0e49b24080569e579b74adc6ce3cdb09765d2b8
Parents: 4a5072e
Author: Aled Sage <al...@gmail.com>
Authored: Wed Dec 24 10:33:52 2014 +0000
Committer: Aled Sage <al...@gmail.com>
Committed: Wed Dec 24 10:33:52 2014 +0000
----------------------------------------------------------------------
.../entity/basic/AbstractSoftwareProcessSshDriver.java | 12 ++++++++++++
1 file changed, 12 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/c0e49b24/software/base/src/main/java/brooklyn/entity/basic/AbstractSoftwareProcessSshDriver.java
----------------------------------------------------------------------
diff --git a/software/base/src/main/java/brooklyn/entity/basic/AbstractSoftwareProcessSshDriver.java b/software/base/src/main/java/brooklyn/entity/basic/AbstractSoftwareProcessSshDriver.java
index 1f21fb7..5139a62 100644
--- a/software/base/src/main/java/brooklyn/entity/basic/AbstractSoftwareProcessSshDriver.java
+++ b/software/base/src/main/java/brooklyn/entity/basic/AbstractSoftwareProcessSshDriver.java
@@ -159,6 +159,12 @@ public abstract class AbstractSoftwareProcessSshDriver extends AbstractSoftwareP
public String getInstallDir() {
if (installDir != null) return installDir;
+ String existingVal = getEntity().getAttribute(SoftwareProcess.INSTALL_DIR);
+ if (Strings.isNonBlank(existingVal)) { // e.g. on rebind
+ installDir = existingVal;
+ return installDir;
+ }
+
synchronized (installDirSetupMutex) {
// previously we looked at sensor value, but we shouldn't as it might have been converted from the config key value
// *before* we computed the install label, or that label may have changed since previous install; now force a recompute
@@ -245,6 +251,12 @@ public abstract class AbstractSoftwareProcessSshDriver extends AbstractSoftwareP
public String getExpandedInstallDir() {
if (expandedInstallDir != null) return expandedInstallDir;
+ String existingVal = getEntity().getAttribute(SoftwareProcess.EXPANDED_INSTALL_DIR);
+ if (Strings.isNonBlank(existingVal)) { // e.g. on rebind
+ expandedInstallDir = existingVal;
+ return expandedInstallDir;
+ }
+
String untidiedVal = ConfigToAttributes.apply(getEntity(), SoftwareProcess.EXPANDED_INSTALL_DIR);
if (Strings.isNonBlank(untidiedVal)) {
setExpandedInstallDir(Os.tidyPath(untidiedVal));
[2/3] incubator-brooklyn git commit: SshMachineLocation: include port
in toString
Posted by al...@apache.org.
SshMachineLocation: include port in toString
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/8095ecbc
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/8095ecbc
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/8095ecbc
Branch: refs/heads/master
Commit: 8095ecbccfd5fa48e9ebd3a843331d694dd1a732
Parents: c0e49b2
Author: Aled Sage <al...@gmail.com>
Authored: Wed Dec 24 10:34:14 2014 +0000
Committer: Aled Sage <al...@gmail.com>
Committed: Wed Dec 24 10:34:14 2014 +0000
----------------------------------------------------------------------
.../main/java/brooklyn/location/basic/SshMachineLocation.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/8095ecbc/core/src/main/java/brooklyn/location/basic/SshMachineLocation.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/brooklyn/location/basic/SshMachineLocation.java b/core/src/main/java/brooklyn/location/basic/SshMachineLocation.java
index 03e53c6..59a273e 100644
--- a/core/src/main/java/brooklyn/location/basic/SshMachineLocation.java
+++ b/core/src/main/java/brooklyn/location/basic/SshMachineLocation.java
@@ -798,14 +798,14 @@ public class SshMachineLocation extends AbstractLocation implements MachineLocat
@Override
public String toString() {
- return "SshMachineLocation["+getDisplayName()+":"+address+"@"+getId()+"]";
+ return "SshMachineLocation["+getDisplayName()+":"+address+":"+getPort()+"@"+getId()+"]";
}
@Override
public String toVerboseString() {
return Objects.toStringHelper(this).omitNullValues()
.add("id", getId()).add("name", getDisplayName())
- .add("user", getUser()).add("address", getAddress()).add("port", getConfig(SSH_PORT))
+ .add("user", getUser()).add("address", getAddress()).add("port", getPort())
.add("parentLocation", getParent())
.toString();
}
[3/3] incubator-brooklyn git commit: This closes #426
Posted by al...@apache.org.
This closes #426
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/16d0b887
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/16d0b887
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/16d0b887
Branch: refs/heads/master
Commit: 16d0b88770f1335541c878eae8609a1dc9de1922
Parents: 4a5072e 8095ecb
Author: Aled Sage <al...@gmail.com>
Authored: Wed Dec 24 11:18:10 2014 +0000
Committer: Aled Sage <al...@gmail.com>
Committed: Wed Dec 24 11:18:10 2014 +0000
----------------------------------------------------------------------
.../brooklyn/location/basic/SshMachineLocation.java | 4 ++--
.../entity/basic/AbstractSoftwareProcessSshDriver.java | 12 ++++++++++++
2 files changed, 14 insertions(+), 2 deletions(-)
----------------------------------------------------------------------