Github user ahgittin commented on a diff in the pull request:
https://github.com/apache/brooklyn-server/pull/899#discussion_r152285616
--- Diff:
core/src/main/java/org/apache/brooklyn/core/mgmt/ha/OsgiBundleInstallationResult.java
---
@@ -98,6 +102,12 @@ void setIgnoringAlreadyInstalled() {
message = "Bundle "+getMetadata().getVersionedName()+" already
installed as "+getMetadata().getId();
}
+ void setIgnoringForciblyRemoved(VersionedName requestedBundle,
Optional<VersionedName> replacementBundle) {
+ code =
OsgiBundleInstallationResult.ResultCode.IGNORING_BUNDLE_FORCIBLY_REMOVED;
+ message = "Bundle "+requestedBundle+" forcibly removed, "
+ +(replacementBundle.isPresent() ? "upgraded to
"+replacementBundle.get().getOsgiVersionString() : "no upgrade defined");
--- End diff --
use `Maybe` with `isPresentAndNotNull()` ?
---