I’m making an OSGi application, which uses servlets. I created the OSGi project from the Maven archetype for Liberty OSGi-enabled Web 3.1 projects, so it’s using `maven-bundle-plugin` to build the manifest.
My Target Platform in Eclipse (+WDT) is set up to point to my Liberty 188.8.131.52 installation. Equally, my `pom.xml` has a dependency on `net.wasdev.maven.tools.targets:liberty-target:184.108.40.206`.
The IDE does the Maven build of the `pom.xml` into the generated `MANIFEST.MF`. However, there’s a problem. The `MANIFEST.MF` is generated with the following statement:
Note that the imports are at version 3.1 and higher, because that’s the version found in Maven. However, the Target Platform bundle `com.ibm.websphere.javaee.servlet.3.1` exports those packages at version 2.7.
This results in the tooling breaking – I get errors in the `MANIFEST.MF` in the IDE – but worse, of course, the `Import-Package` statements are not available in the runtime, and the application will not start.