| Summary: | [releng] Wars created by maven build don't work | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [RT] RAP | Reporter: | Ralf Sternberg <rsternberg> | ||||
| Component: | Releng | Assignee: | Project Inbox <rap-inbox> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P3 | CC: | ivan, mknauer | ||||
| Version: | 2.2 | ||||||
| Target Milestone: | 2.2 RC1 | ||||||
| Hardware: | PC | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Ralf Sternberg
This issue has been discussed several months ago - http://www.eclipse.org/forums/index.php/m/1071044/?srch=Maven#msg_1071044. The generated config.ini is missing the extensionbundle bundle - osgi.framework.extensions property is empty. If I remember correctly Markus had similar fix outlined here: http://www.eclipse.org/forums/index.php/mv/msg/489963/1073241/#msg_1073241 Fixed in master with commit 6f8516035f52f57f86e14779916fc126bb1f4c79 The change removes the simpleconfigurator which uses bundles.info to specify the list of bundles that need to be started. With the simpleconfigurator bundle removed the build falls back to list all required bundles in the config.ini. In order to start the virtual org.eclipse.equinox.servletbridge.extensionbundle I added a small search&replace step to the Maven build that adds the required definition to the config.ini. The removal simplifies the build, leads to a smaller .war file, and best of all: It creates .war files that work. The org.eclipse.equinox.servletbridge.extensionbundle is a fragment and cannot be started. Thus, the definition currently added to the config.ini
org.eclipse.equinox.servletbridge.extensionbundle@4:start
leads to an exception at startup (see below). The "@4:start" should be removed. Moreover, the expression
reference\:file\:javax.servlet_3.0.0.v201112011016.jar@4
should not be there.
org.osgi.framework.BundleException: A fragment bundle cannot be started: org.eclipse.equinox.servletbridge.extensionbundle_1.3.0 [1]
at org.eclipse.osgi.framework.internal.core.BundleFragment.startWorker(BundleFragment.java:224)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:300)
...
Created attachment 238006 [details]
Fix list of osgi.bundles in config.ini
This patch introduces a new regular expression that removes the javax.servlet entry from the list of bundles in the config.ini.
Additionally it doesn't add start parameters to the config.ini for the org.eclipse.equinox.servletbridge.extensionbundle fragment.
Comment on attachment 238006 [details]
Fix list of osgi.bundles in config.ini
+1 for 2.2.
With this patch, the exported bundles work, no exceptions logged anymore
Push to master with commit 74f557876dd5e52d3668e5ceabc7a68471e33424 Closing bug as fixed. Comment on attachment 238006 [details]
Fix list of osgi.bundles in config.ini
+1 for including it in 2.2RC2
|