Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build goal moved to package and major version update #253

Merged
merged 1 commit into from
Dec 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -357,6 +357,21 @@ When you are using a bundle-war, bundle-ear, or bundle-osgi goal, the deploy goa
**How to resolve it?**
Use the <classifier>cics-bundle</classifier> configuration option to select the bundle, in the case where you're deploying a bundle-war-built bundle.


### Error reading Bundle-SymbolicName from OSGi manifest file
**Why does it happen?**
You may run into this error when building an OSGi bundle.

The build goal of the Maven Bundle Plugin is bound to the compile phase, but the manifest generation occurs in the process-classes phase, which runs after compile. As a result, if other processes or plugins expect the manifest data during the compile phase, it won't be available yet, leading to errors like "Error reading Bundle-SymbolicName from OSGi manifest file."

**How to resolve it?**

In Maven Bundle Plugin version 2.0.0 we moved the binding of the build goal from the compile phase to the package phase. This change ensures that the bundle is built as late as possible in the reactor build process, allowing all necessary class files and resources to be fully processed before the manifest is generated.

**Action you must take when upgrading**

If your project uses the cics-bundle packaging type to build any bundle part and you previously used the mvn compile command, you must now use mvn package instead.This change ensures that your bundle parts are packaged correctly with version 2.0.0.

## Contributing

We welcome contributions! Find out how in our [contribution guide](CONTRIBUTING.md).
Expand Down
2 changes: 1 addition & 1 deletion cics-bundle-deploy-reactor-archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</parent>

<artifactId>cics-bundle-deploy-reactor-archetype</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion cics-bundle-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</parent>

<artifactId>cics-bundle-maven-plugin</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,8 @@
<lifecycle>
<id>default</id>
<phases>
<compile>
com.ibm.cics:cics-bundle-maven-plugin:build
</compile>
<package>
com.ibm.cics:cics-bundle-maven-plugin:build,
com.ibm.cics:cics-bundle-maven-plugin:package
</package>
<install>
Expand Down
2 changes: 1 addition & 1 deletion cics-bundle-maven-site/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</parent>
<artifactId>cics-bundle-maven-site</artifactId>
<packaging>pom</packaging>
Expand Down
2 changes: 1 addition & 1 deletion cics-bundle-reactor-archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</parent>

<artifactId>cics-bundle-reactor-archetype</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>CICS Bundle Maven Parent</name>
Expand Down
6 changes: 3 additions & 3 deletions samples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>samples</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
<packaging>pom</packaging>
<parent>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</parent>

<dependencies>
<!-- This will be installed from this build into the invoker's repo by invoker:install -->
<dependency>
<groupId>com.ibm.cics</groupId>
<artifactId>cics-bundle-maven-plugin</artifactId>
<version>1.0.8-SNAPSHOT</version>
<version>2.0.0-SNAPSHOT</version>
</dependency>
</dependencies>

Expand Down
Loading