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 2016/03/04 17:15:51 UTC
[06/18] brooklyn-server git commit: remove deprecated methods
remove deprecated methods
Project: http://git-wip-us.apache.org/repos/asf/brooklyn-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-server/commit/4cf4fdde
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-server/tree/4cf4fdde
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-server/diff/4cf4fdde
Branch: refs/heads/master
Commit: 4cf4fdde61fc4ceaf80d045c712d6f087d6f9092
Parents: c565d00
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Wed Feb 24 11:12:21 2016 -0800
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Wed Feb 24 11:12:21 2016 -0800
----------------------------------------------------------------------
.../brooklyn/api/location/LocationRegistry.java | 18 --------------
.../core/location/BasicLocationRegistry.java | 25 --------------------
2 files changed, 43 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/4cf4fdde/api/src/main/java/org/apache/brooklyn/api/location/LocationRegistry.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/brooklyn/api/location/LocationRegistry.java b/api/src/main/java/org/apache/brooklyn/api/location/LocationRegistry.java
index 50fbc6a..73ab6f5 100644
--- a/api/src/main/java/org/apache/brooklyn/api/location/LocationRegistry.java
+++ b/api/src/main/java/org/apache/brooklyn/api/location/LocationRegistry.java
@@ -73,19 +73,6 @@ public interface LocationRegistry {
@Beta
public Maybe<Location> resolve(String spec, Boolean manage, Map locationFlags);
- /** efficiently returns for inspection only a fully populated (config etc) location from the given definition;
- * the value might be unmanaged so it is not meant for any use other than inspection,
- * but callers should prefer this when they don't wish to create a new location which will be managed in perpetuity!
- *
- * @deprecated since 0.7.0, use {@link #resolve(LocationDefinition, Boolean, Map)} */
- @Deprecated
- public Location resolveForPeeking(LocationDefinition l);
-
- /** returns fully populated (config etc) location from the given definition, with overrides;
- * @deprecated since 0.7.0, use {@link #resolve(LocationDefinition, Boolean, Map)} */
- @Deprecated
- public Location resolve(LocationDefinition l, Map<?,?> locationFlags);
-
/** See {@link #resolve(String, Boolean, Map)}; asks for the location to be managed, and supplies no additional flags,
* and unwraps the result (throwing if the spec cannot be resolve) */
public Location resolve(String spec);
@@ -102,11 +89,6 @@ public interface LocationRegistry {
* @throws NoSuchElementException if the spec cannot be resolved */
public Location resolve(String spec, @Nullable Map locationFlags);
- /** as {@link #resolve(String)} but returning null (never throwing)
- * @deprecated since 0.7.0 use {@link #resolve(String, Boolean, Map)} */
- @Deprecated
- public Location resolveIfPossible(String spec);
-
/**
* As {@link #resolve(String)} but takes collections (of strings or locations)
* <p>
http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/4cf4fdde/core/src/main/java/org/apache/brooklyn/core/location/BasicLocationRegistry.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/location/BasicLocationRegistry.java b/core/src/main/java/org/apache/brooklyn/core/location/BasicLocationRegistry.java
index 60fb061..ee9f8c3 100644
--- a/core/src/main/java/org/apache/brooklyn/core/location/BasicLocationRegistry.java
+++ b/core/src/main/java/org/apache/brooklyn/core/location/BasicLocationRegistry.java
@@ -319,17 +319,6 @@ public class BasicLocationRegistry implements LocationRegistry {
return resolve(spec, true, null).get();
}
- @Override @Deprecated
- public final Location resolveIfPossible(String spec) {
- if (!canMaybeResolve(spec)) return null;
- return resolve(spec, null, null).orNull();
- }
-
- @Deprecated /** since 0.7.0 not used */
- public final Maybe<Location> resolve(String spec, boolean manage) {
- return resolve(spec, manage, null);
- }
-
public Maybe<Location> resolve(String spec, Boolean manage, Map locationFlags) {
try {
locationFlags = MutableMap.copyOf(locationFlags);
@@ -458,20 +447,6 @@ public class BasicLocationRegistry implements LocationRegistry {
public Location resolve(LocationDefinition ld) {
return resolve(ld, null, null).get();
}
-
- @Override @Deprecated
- public Location resolveForPeeking(LocationDefinition ld) {
- // TODO should clean up how locations are stored, figuring out whether they are shared or not;
- // or maybe better, the API calls to this might just want to get the LocationSpec objects back
-
- // for now we use a 'CREATE_UNMANGED' flag to prevent management (leaks and logging)
- return resolve(ld, ConfigBag.newInstance().configure(LocalLocationManager.CREATE_UNMANAGED, true).getAllConfig());
- }
-
- @Override @Deprecated
- public Location resolve(LocationDefinition ld, Map<?,?> flags) {
- return resolveLocationDefinition(ld, flags, null);
- }
/** @deprecated since 0.7.0 not used (and optionalName was ignored anyway) */
@Deprecated