This is an automated email from the ASF dual-hosted git repository.
heneveld pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brooklyn-server.git
The following commit(s) were added to refs/heads/master by this push:
new a7696c1 suppress warning about installation of deprecated types; only
warn on usage
new 479c9d2 Merge branch 'master' of
https://gitbox.apache.org/repos/asf/brooklyn-server
a7696c1 is described below
commit a7696c17e84acc7ffd57c7c54983e87e4419393c
Author: Alex Heneveld <[email protected]>
AuthorDate: Wed Sep 1 13:21:18 2021 +0100
suppress warning about installation of deprecated types; only warn on usage
---
.../brooklyn/core/resolve/entity/CatalogEntitySpecResolver.java | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git
a/core/src/main/java/org/apache/brooklyn/core/resolve/entity/CatalogEntitySpecResolver.java
b/core/src/main/java/org/apache/brooklyn/core/resolve/entity/CatalogEntitySpecResolver.java
index 60f663e..bc421a1 100644
---
a/core/src/main/java/org/apache/brooklyn/core/resolve/entity/CatalogEntitySpecResolver.java
+++
b/core/src/main/java/org/apache/brooklyn/core/resolve/entity/CatalogEntitySpecResolver.java
@@ -107,7 +107,11 @@ public class CatalogEntitySpecResolver extends
AbstractEntitySpecResolver {
if (item.isDisabled()) {
throw new IllegalStateException("Illegal use of disabled catalog
item "+item.getSymbolicName()+":"+item.getVersion());
} else if (item.isDeprecated()) {
- log.warn("Use of deprecated catalog item
"+item.getSymbolicName()+":"+item.getVersion());
+ if
(org.apache.brooklyn.util.javalang.StackTraceSimplifier.toString(new
Throwable()).contains("BasicBrooklynCatalog.validate")) {
+ // don't warn when adding to the catalog
+ } else {
+ log.warn("Use of deprecated catalog item
"+item.getSymbolicName()+":"+item.getVersion(), new Throwable("source"));
+ }
}
}