ServerPoolLocation.OWNER: fix naming It overrides the DynamicLocation.OWNER, but previously had a different name, with the same SetFromFlag.
Changed it to use the same name as the super-type (i.e. âownerâ), with a deprecatedName of âpool.location.ownerâ. Project: http://git-wip-us.apache.org/repos/asf/brooklyn-server/repo Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-server/commit/80c9a9a2 Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-server/tree/80c9a9a2 Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-server/diff/80c9a9a2 Branch: refs/heads/master Commit: 80c9a9a2a0d851d5d406d23c030c32fe71e152ae Parents: afa787c Author: Aled Sage <[email protected]> Authored: Wed Jun 28 22:02:12 2017 +0100 Committer: Aled Sage <[email protected]> Committed: Wed Jun 28 22:08:52 2017 +0100 ---------------------------------------------------------------------- .../brooklyn/entity/machine/pool/ServerPoolLocation.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/80c9a9a2/software/base/src/main/java/org/apache/brooklyn/entity/machine/pool/ServerPoolLocation.java ---------------------------------------------------------------------- diff --git a/software/base/src/main/java/org/apache/brooklyn/entity/machine/pool/ServerPoolLocation.java b/software/base/src/main/java/org/apache/brooklyn/entity/machine/pool/ServerPoolLocation.java index 3bb985a..4e4538c 100644 --- a/software/base/src/main/java/org/apache/brooklyn/entity/machine/pool/ServerPoolLocation.java +++ b/software/base/src/main/java/org/apache/brooklyn/entity/machine/pool/ServerPoolLocation.java @@ -44,9 +44,9 @@ public class ServerPoolLocation extends AbstractLocation implements MachineProvi private static final Logger LOG = LoggerFactory.getLogger(ServerPoolLocation.class); - @SetFromFlag("owner") - public static final ConfigKey<ServerPool> OWNER = ConfigKeys.newConfigKey( - ServerPool.class, "pool.location.owner"); + public static final ConfigKey<ServerPool> OWNER = ConfigKeys.builder(ServerPool.class, "owner") + .deprecatedNames("pool.location.owner") + .build(); @SetFromFlag("locationName") public static final ConfigKey<String> LOCATION_NAME = ConfigKeys.newStringConfigKey("pool.location.name"); @@ -56,8 +56,8 @@ public class ServerPoolLocation extends AbstractLocation implements MachineProvi @Override public void init() { - LOG.debug("Initialising. Owner is: {}", checkNotNull(getConfig(OWNER), OWNER.getName())); super.init(); + LOG.debug("Initialising. Owner is: {}", checkNotNull(getConfig(OWNER), OWNER.getName())); } @Override
