|
| Version: |
17.10.10 |
| Description: |
h2. Problem Backward \ -compatibility in the {{ \ * \ -legacy \ - \ *}} modules relies on AspectJ aspects being weaved into the modules they wrap. When an advice stops matching \ (because the API it protects was moved, renamed or removed \ ), AspectJ only emits a *warning*:
{code} advice ... has not been applied [Xlint:adviceDidNotMatch] {code}
Warnings are easy to miss in a full build, so a broken backward \ -compatibility layer can ship unnoticed. XRENDERING \ -809 is a concrete case where a legacy advice silently did nothing for several releases.
h2. Proposal In the shared {{aspectj \ -maven \ -plugin}} {{pluginManagement}} configuration of the {{xwiki \ -commons}} parent pom, promote AspectJ lint messages to errors \ ({{<Xlint>error</Xlint>}} \ ) so that any weaving problem fails the build instead of printing an easy \ -to \ -miss warning.
This only affects modules that actually run {{aspectj:compile}} \ (i.e. the {{ \ * \ -legacy \ - \ *}} aspect modules across Commons, Rendering and Platform \ ). For those modules an unmatched advice — and related lints such as {{typeNotExposedToWeaver}}, {{cantFindType}} and {{invalidAbsoluteTypeName}} — always signals a real backward \ -compatibility regression, so failing the build is the desired behaviour.
A module that ever needs to downgrade a specific lint can still do so locally via the plugin's {{Xlintfile}} parameter, which overrides {{Xlint}}.
|
| Assignee: |
Vincent Massol |
| Component: |
Stability |
| Component: |
Development Issues only |
|