Content Package Maven Plugin: Allow whitelisting(/blacklisting?) of bundles for bundleStatusURL

Description

We are actually using version 1.6.18, but I couldn't select it from the versions list.

I noticed that in InstallMojo, a PackageInstaller is created, that in the end uses PackageManagerHelper to wait for the bundle status to be OK. A good thing, we really appreciate this feature, so we would like to use it.

However, it goes wrong on our local instances, since CRXDE is disabled per the security checklist.

Is there a way to blacklist/whitelist (depends on how you look at it) bundles? Currently we have 2 options:

  • Enable CRXDE;

  • Turn off the bundleStatusURL by specifying `-` as its value.

We would like to have option #3 : Disable CRXDE, leave bundleStatusURL turned on and specify that its the intention that the CRXDE bundle is disabled.

AEM (Sling) already exposes a JMX Bean that could be checked for example, which already takes the whitelisted bundles into account: http://localhost:4502/system/console/jmx/org.apache.sling.healthcheck%3Aname%3DmissingPackages%2Ctype%3DHealthCheck

Activity

Show:
Stefan Seifert
August 15, 2019, 1:58 PM

yes, this makes definitely sense.
not sure if we easily/in a clean way can get the configuration the JMX bean is based upon, otherwise we will make it configurable in the plugin properties.

patches welcome ... otherwise i will look into it in the next time.

Stefan Seifert
August 20, 2019, 7:27 AM

i think the better match for an existing configuration for bundles to ignore is the osgi config of this health check:
http://localhost:4502/system/console/configMgr/com.adobe.granite.bundles.hc.impl.InactiveBundlesHealthCheck

it's about "inactive" bundles and not about "missing" bundles (the latter seems to be used in context of system upgrades).

Stefan Seifert
August 20, 2019, 10:31 AM

implemented in version 1.7.0

a new configuration parameter bundleStatusWhitelistBundleNames allows to define a list of regex patterns for bundles to be ignored on the status check. it's preconfigured with the same bundle list as by default configured in http://localhost:4502/system/console/configMgr/com.adobe.granite.bundles.hc.impl.InactiveBundlesHealthCheck

but the configuration is not dynamically read from this osgi config - it turned out that's not easy possible using the Felix Config Manager HTTP API, as this does not return anything if the configuration does not exist but has only it's default values. but having it configurable with a sensible default should be enough to solve this ticket.

https://github.com/wcm-io/wcm-io-tooling/commit/1dfca7c4cefc17009aaba75fb34be7b710a9b732

Fixed

Assignee

Stefan Seifert

Reporter

Henry Kuijpers

Labels

None

Fix versions

Affects versions

Priority

Major