brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tbou...@apache.org
Subject [5/6] brooklyn-server git commit: PR #852: incorporate review comments
Date Tue, 17 Oct 2017 09:19:35 GMT
PR #852: incorporate review comments

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

Branch: refs/heads/master
Commit: 48d99991654f8add08c4025a66be8e7c97678620
Parents: 8599161
Author: Aled Sage <aled.sage@gmail.com>
Authored: Tue Oct 17 09:38:46 2017 +0100
Committer: Aled Sage <aled.sage@gmail.com>
Committed: Tue Oct 17 09:38:46 2017 +0100

----------------------------------------------------------------------
 .../org/apache/brooklyn/api/catalog/BrooklynCatalog.java    | 4 ++--
 .../core/catalog/internal/CatalogInitialization.java        | 2 +-
 .../core/mgmt/rebind/PeriodicDeltaChangeListener.java       | 2 --
 .../launcher/AbstractBrooklynLauncherRebindTest.java        | 6 ------
 .../launcher/BrooklynLauncherRebindCatalogTest.java         | 9 ---------
 launcher/src/test/resources/rebind-test-empty-catalog.bom   | 3 ---
 server-cli/src/main/java/org/apache/brooklyn/cli/Main.java  | 2 +-
 7 files changed, 4 insertions(+), 24 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/api/src/main/java/org/apache/brooklyn/api/catalog/BrooklynCatalog.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/brooklyn/api/catalog/BrooklynCatalog.java b/api/src/main/java/org/apache/brooklyn/api/catalog/BrooklynCatalog.java
index cb305ef..5f98c03 100644
--- a/api/src/main/java/org/apache/brooklyn/api/catalog/BrooklynCatalog.java
+++ b/api/src/main/java/org/apache/brooklyn/api/catalog/BrooklynCatalog.java
@@ -217,8 +217,8 @@ public interface BrooklynCatalog {
      * just adds without removing the existing content. Note this is very different from

      * {@link #addItem(CatalogItem)}, which adds to the 'manual' catalog.
      *
-     * @since 0.13.0 (only for legacy backwards compatibility)
-     * @deprecated since 0.13.0; instead use bundles in persisted state!
+     * @since 1.0.0 (only for legacy backwards compatibility)
+     * @deprecated since 1.0.0; instead use bundles in persisted state!
      */
     @Deprecated
     void addCatalogLegacyItemsOnRebind(Iterable<? extends CatalogItem<?,?>> items);

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/core/src/main/java/org/apache/brooklyn/core/catalog/internal/CatalogInitialization.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/catalog/internal/CatalogInitialization.java
b/core/src/main/java/org/apache/brooklyn/core/catalog/internal/CatalogInitialization.java
index e11b64d..58999a2 100644
--- a/core/src/main/java/org/apache/brooklyn/core/catalog/internal/CatalogInitialization.java
+++ b/core/src/main/java/org/apache/brooklyn/core/catalog/internal/CatalogInitialization.java
@@ -159,7 +159,7 @@ public class CatalogInitialization implements ManagementContextInjectable
{
     }
     
     private boolean hasRunInitialCatalogInitialization() {
-        return hasRunInitialCatalogInitialization;
+        return hasRunFinalInitialization || hasRunInitialCatalogInitialization;
     }
     
     /**

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/core/src/main/java/org/apache/brooklyn/core/mgmt/rebind/PeriodicDeltaChangeListener.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/mgmt/rebind/PeriodicDeltaChangeListener.java
b/core/src/main/java/org/apache/brooklyn/core/mgmt/rebind/PeriodicDeltaChangeListener.java
index 5f5e50a..a5af458 100644
--- a/core/src/main/java/org/apache/brooklyn/core/mgmt/rebind/PeriodicDeltaChangeListener.java
+++ b/core/src/main/java/org/apache/brooklyn/core/mgmt/rebind/PeriodicDeltaChangeListener.java
@@ -44,11 +44,9 @@ import org.apache.brooklyn.api.sensor.Feed;
 import org.apache.brooklyn.api.typereg.ManagedBundle;
 import org.apache.brooklyn.core.BrooklynFeatureEnablement;
 import org.apache.brooklyn.core.entity.EntityInternal;
-import org.apache.brooklyn.core.mgmt.BrooklynTaskTags;
 import org.apache.brooklyn.core.mgmt.persist.BrooklynPersistenceUtils;
 import org.apache.brooklyn.core.mgmt.persist.PersistenceActivityMetrics;
 import org.apache.brooklyn.core.objs.BrooklynObjectInternal;
-import org.apache.brooklyn.util.collections.MutableMap;
 import org.apache.brooklyn.util.collections.MutableSet;
 import org.apache.brooklyn.util.core.task.ScheduledTask;
 import org.apache.brooklyn.util.core.task.Tasks;

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/launcher/src/test/java/org/apache/brooklyn/launcher/AbstractBrooklynLauncherRebindTest.java
----------------------------------------------------------------------
diff --git a/launcher/src/test/java/org/apache/brooklyn/launcher/AbstractBrooklynLauncherRebindTest.java
b/launcher/src/test/java/org/apache/brooklyn/launcher/AbstractBrooklynLauncherRebindTest.java
index 1406a7f..6b13313 100644
--- a/launcher/src/test/java/org/apache/brooklyn/launcher/AbstractBrooklynLauncherRebindTest.java
+++ b/launcher/src/test/java/org/apache/brooklyn/launcher/AbstractBrooklynLauncherRebindTest.java
@@ -137,12 +137,6 @@ public abstract class AbstractBrooklynLauncherRebindTest {
             tmpFiles.add(bf);
         }
         return bf;
-        
-//        ReferenceWithError<OsgiBundleInstallationResult> b = ((ManagementContextInternal)mgmt).getOsgiManager().get().install(
-//                new FileInputStream(bf) );
-//
-//            b.checkNoError();
-
     }
     
     protected void assertCatalogConsistsOfIds(BrooklynLauncher launcher, Iterable<VersionedName>
ids) {

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/launcher/src/test/java/org/apache/brooklyn/launcher/BrooklynLauncherRebindCatalogTest.java
----------------------------------------------------------------------
diff --git a/launcher/src/test/java/org/apache/brooklyn/launcher/BrooklynLauncherRebindCatalogTest.java
b/launcher/src/test/java/org/apache/brooklyn/launcher/BrooklynLauncherRebindCatalogTest.java
index 611096a..1b80887 100644
--- a/launcher/src/test/java/org/apache/brooklyn/launcher/BrooklynLauncherRebindCatalogTest.java
+++ b/launcher/src/test/java/org/apache/brooklyn/launcher/BrooklynLauncherRebindCatalogTest.java
@@ -18,24 +18,15 @@
  */
 package org.apache.brooklyn.launcher;
 
-import java.util.List;
 import java.util.Set;
 
-import javax.annotation.Nullable;
-
 import org.apache.brooklyn.api.catalog.BrooklynCatalog;
-import org.apache.brooklyn.api.catalog.CatalogItem;
-import org.apache.brooklyn.api.typereg.BrooklynTypeRegistry;
-import org.apache.brooklyn.api.typereg.RegisteredType;
 import org.apache.brooklyn.core.catalog.internal.CatalogInitialization;
 import org.apache.brooklyn.util.collections.MutableSet;
 import org.apache.brooklyn.util.core.ResourceUtils;
 import org.apache.brooklyn.util.osgi.VersionedName;
-import org.apache.commons.collections.IteratorUtils;
-import org.testng.Assert;
 import org.testng.annotations.Test;
 
-import com.google.common.base.Function;
 import com.google.common.collect.ImmutableSet;
 import com.google.common.collect.Iterables;
 

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/launcher/src/test/resources/rebind-test-empty-catalog.bom
----------------------------------------------------------------------
diff --git a/launcher/src/test/resources/rebind-test-empty-catalog.bom b/launcher/src/test/resources/rebind-test-empty-catalog.bom
index 53b914f..d13bd31 100644
--- a/launcher/src/test/resources/rebind-test-empty-catalog.bom
+++ b/launcher/src/test/resources/rebind-test-empty-catalog.bom
@@ -20,6 +20,3 @@ brooklyn.catalog:
   version: "test-version"
   itemType: entity
   items:
-
-  # Do not scan classpath with for classes with a @Catalog annotation
-  - scanJavaAnnotations: false

http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/48d99991/server-cli/src/main/java/org/apache/brooklyn/cli/Main.java
----------------------------------------------------------------------
diff --git a/server-cli/src/main/java/org/apache/brooklyn/cli/Main.java b/server-cli/src/main/java/org/apache/brooklyn/cli/Main.java
index 9d037f6..8d20d59 100644
--- a/server-cli/src/main/java/org/apache/brooklyn/cli/Main.java
+++ b/server-cli/src/main/java/org/apache/brooklyn/cli/Main.java
@@ -592,7 +592,7 @@ public class Main extends AbstractMain {
         /**
          * method intended for subclassing, to add custom items to the catalog.
          * 
-         * @deprecated since 0.13.0; no longer supported; does nothing - subclasses should
not try to extend it!
+         * @deprecated since 1.0.0; no longer supported; does nothing - subclasses should
not try to extend it!
          */
         protected final void populateCatalog(BrooklynCatalog catalog) {
             // nothing else added here


Mime
View raw message