[BUILD-445] japicmp works with standard SemVer, but Magnolia uses Magnolia SemVer Created: 29/Mar/21  Updated: 08/Apr/21  Resolved: 31/Mar/21

Status: Closed
Project: Build
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Neutral
Reporter: Maxime Michel Assignee: Maxime Michel
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
relation
is related to BUILD-418 japicmp won't parse Magnolia major re... Closed
Template:
Acceptance criteria:
Empty
Task DoR:
Empty

 Description   

The SSO 1.1 release lead to the following problem:

  • API compatibility got broken when going from 1.0.x to 1.1.x
    • which is acceptable in Magnolia SemVer
  • however, the check is now running, saying the module should have been bumped to a new major (2.0.x) with such changes
    • which is indeed standard SemVer

This ticket is about looking into the following option of the japicmp plugin:

postAnalysisScript true n.a. A Groovy script that gets invoked after analysis is completed and before the output is written. This way it can be used to filter the output or break the build on specific conditions. It can be an absolute path or a relative path of a file within the classpath.

Write a script in order to override the default SemVer validation with Magnolia-specific unwritten rules.



 Comments   
Comment by Maxime Michel [ 29/Mar/21 ]

I tried to use said option but the problem is that PPOM have a pom packaging, and therefore can't ship a Groovy file with them. We could store that file somewhere on Jenkins and leave the PPOM intact, simply using -Djapicmp.postAnalysisScript=post-analysis-script.groovy in pipelines. But that would then introduce differences in local vs. online builds for developers.

Another solution would be to download either the file or the file wrapped in a Maven project from the PPOMs, but that also doesn't feel satisfying at all.

Comment by Maxime Michel [ 31/Mar/21 ]

No clear solution yet.

Comment by Maxime Michel [ 31/Mar/21 ]

Actually, a new release of japicmp allows us to do this. The release is from March and so the site isn't extremely clear about it yet, but it works.

Comment by Maxime Michel [ 31/Mar/21 ]

From the script there is no API that allows to assess which versions of the module are being compared. So that can't be used for the use case here.

Comment by Maxime Michel [ 31/Mar/21 ]

Closing in favor of BUILD-418 which is the real issue.

Generated at Sun Feb 11 23:41:59 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.