| commit | 648957bb87b6741313a6a73ab34464b2ff15f495 | [log] [tgz] |
|---|---|---|
| author | angela <anchela@adobe.com> | Wed Jun 05 17:40:55 2024 +0200 |
| committer | angela <anchela@adobe.com> | Wed Jun 05 17:40:55 2024 +0200 |
| tree | a4b4127c9f6a9d8d32099cedd3f0d4e1e8663ab7 | |
| parent | 8652295de67bec23de25631d2454d65a36b73fc3 [diff] |
SLING-12346 : Create service-user-mapping analyser (removing unused dependency)
The Analyser can analyse features for completeness and correctness. The analyser is pluggable and can perform custom checks.
The Analyser can also be run as part of a Maven build via the slingfeature-maven-plugin
Below is a list of built-in analysers. Additional analysers in relation to Feature Model API Regions can be found in org-apache-sling-feature-extension-apiregions, analysers performing checks on class level can be found in org-apache-sling-feature-analyser-classes.
For further documentation see: Feature Model
apis-jarThis analyser task validates the metadata in the feature model for the apis-jar goal of the slingfeature-maven-plugin.
bundle-connectChecks whether the feature is ready for OSGi connect. Bundle with embedded jars are not allowed and packages between bundles must not overlap.
bundle-contentGives a warning if a bundle contains initial content specified with Sling-Initial-Content.
bundle-nativecodeChecks for native code instructions in bundles and errors if found.
bundle-packagesChecks bundle import/export package statements for completeness. Does not take API Regions into account. An expanded variant of this analyser is available in org-apache-sling-feature-extension-apiregions under the name api-regions-exportsimports.
bundle-resourcesGives a warning if a bundle contains resources specified with Sling-Bundle-Resources.
bundle-unversioned-packagesChecks bundle import/export package statements for missing version information.
check-unused-bundlesChecks for unused bundles, bundles with exports which are not imported.
compare-featuresCompares the artifacts in the bundles sections or in an extension between two feature models.
This analyser requires additional configuration:
| Configuration key | Allowed values | Description |
|---|---|---|
compare-type | ARTIFACTS | The types of entities being compared. Currently only artifacts can be compared. |
compare-with | Maven ID, e.g. mygroup:myart:1.2.3 | The golden feature to compare the features selected for the analyser with. |
compare-extension | extension name | If this configuration is absent, the feature's bundles are compared. Otherwise the extensions with the specified name are compared. These extensions must be of type ARTIFACTS. |
compare-mode | SAME or DIFFERENT | Whether the sections must be the same or must be different. Defaults to SAME. |
compare-metadata | true or false | Whether to include the artifact metadata in the comparison. Defaults to false. |
content-packages-dependenciesChecks the dependencies between content packages.
content-packages-installablesChecks that content packages do not contain installables for the OSGi installer like bundles or configurations.
content-packages-pathsThis analyser checks for allowed and denied paths inside content packages. This analyser requires additional configuration:
| Configuration key | Allowed values | Description |
|---|---|---|
includes | Content paths | A comma separated list of content paths. If this is specified all content in the content package must match at least one of these. |
excludes | Content paths | A comma separated list of content paths. If this is specified all content in the content package must not match any of these - except it matches an include. |
content-packages-validationRuns the default filevault validators on the content packages.
| Configuration key | Allowed values | Description |
|---|---|---|
enabled-validators | validator ids | A comma separated list of validator-ids to enable |
max-report-level | severity level | Maximum severity level to report. (INFO, WARN, ERROR) defaults to WARN. Higher level messages will be downgraded to the sepcified level. The default will never break a build. |
duplicate-symbolic-namesChecks if there are duplicates of symbolic names for bundles.
feature-idThis analyser checks that the feature id matches one of the given accepted feature ids. If it doesn't it will emit an error.
This analyser requires additional configuration:
| Configuration key | Allowed values | Description |
|---|---|---|
accepted-feature-ids | comma-separated list of Maven IDs | The Maven ID/coordinates have the format groupId:artifactId[:packaging[:classifier]]:version. Each item is either a string which must be equal to the according item of the feature id, or a * which acts as wildcard (i.e. everything matches). |
repoinitChecks the syntax of all repoinit sections.
requirements-capabilitiesChecks bundle requirements/capabilities for consistency and completeness.