On 9/16/11 1:08 PM, Richard S. Hall wrote:
On 9/16/11 12:58 PM, Martijn van Iersel wrote:Thanks, your suggestion of manually updating OBR works.Starting it still doesn't work though: g! start 12org.osgi.framework.BundleException: Unresolved constraint in bundle org.pathvisio.desktop [12]: Unable to resolve 12.0: missing requirement [12.0] module; (&(bundle-symbolic-name=org.pathvisio.core)(bundle-version>=2.0.11)) [caused by: Unable to resolve 9.0: missing requirement [9.0] module; (&(bundle-symbolic-name=javax.xml)(bundle-version>=1.3.4)) [caused by: Execution environment not supported: J2SE-1.2]]Even though I've removed the Execution enviroment requirements from repository.xml as you suggested, it's still coming back to me at this point.Indeed the bundle java.xml carries this header: Bundle-RequiredExecutionEnvironment: J2SE-1.2Do you think this problem should be fixed in felix framework, or is it better to go and remove all the Bundle-RequiredExecutionEnvironment headers from all my bundles? Most of these are third-party bundles, and I would prefer not to have to modify them.There are two different resolve operations going on here, one in OBR and one in the framework. I'm not sure how well OBR handles BREE, but the framework handles it fine. The issue you have here is that the framework doesn't say that it provides J2SE-1.2 (this has already been fixed in trunk for the next release).
Just following up on this, it does look like OBR attempts to handle BREE too, so maybe your original problem with OBR not resolving BREE was that the framework was not properly configured to provide the one you needed.
OBR models the system bundle by probing the framework's configuration when resolving bundles, so it makes sense that OBR would fail to find a provider of J2SE-1.2 since the framework wasn't providing it.
So, perhaps if you fix the config.properties file as suggested below, then you can go back and add the BREEs into your repository.xml file and it will work.
-> richard
You can fix this just by adding the following to your conf/config.properties file:org.osgi.framework.executionenvironment=\ ee-1.6=JavaSE-1.6,J2SE-1.5,J2SE-1.4,J2SE-1.3,J2SE-1.2, \ JRE-1.1,JRE-1.0,OSGi/Minimum-1.2,OSGi/Minimum-1.1,OSGi/Minimum-1.0You really are having all the bad luck. Definitely grab the new framework release as soon as it is out.P.S. You replied to me off-list, I'd be happy to go back on list if you don't have time to help me out personally.Sorry, that was a mistake, we are back on the list. :-) -> richardOn 16/09/11 17:16, Richard S. Hall wrote:OBR installed a newer version over itself, which kills the bundle in itstracks: g! deploy 'org.pathvisio.desktop' Target resource(s): ------------------- org.pathvisio.desktop (2.0.11) Required resource(s): --------------------- Apache Batik CSS (1.7.0.v201011041433) Apache Batik Parser (1.7.0.v201011041433) org.pathvisio.core (2.0.11) W3C CSS SAC (1.3.1.v200903091627) Apache Felix Bundle Repository (1.6.6) ...Clearly this is some special case (i.e., updating itself) that OBR needsto handle and isn't. I would imagine if you update the OBR bundle manually first, then it will work after that. Just download the new OBR bundle and put it in your bundle/ directory rather than the existing one, then delete your cache and start again. Lucky you, you're having all sorts of fun! ;-) -> richard On 9/16/11 11:26 AM, Martijn van Iersel wrote:Allright, I'm using fresh bundles that don't have the problem with version vs. bundle-version. After trying again with the new bundles, I'm getting another error message: First I start the framework: ~/felix-framework-3.2.2$ java -jar bin/felix.jar Then I run the following commands on the OSGi shell: repos add http://www.bigcat.unimaas.nl/~martijn/obr/repository.xml deploy 'org.pathvisio.desktop' Now I get this error: Deploying...java.lang.IllegalStateException: Invalid BundleContext. Not much to go on here... Any suggestions on how I can start debugging this? regards, Martijn On 15/09/11 17:16, Richard Hall wrote:First, let me say that this works on the trunk build of the Felix framework (3.3.0-SNAPSHOT), which you can grab from the Apache Mavensnapshot repository. However, it is still not going to be 100% correct.The reason why it works on the trunk framework is I fixed a bug infilter creation that was incorrectly throwing IllegalArgumentExceptions when some strings contained non-escaped parentheses characters, when it reality the non-escaped parentheses characters were acceptable. This waswrong in 3.2.2 and I fixed it in trunk. So that's why it works now.The reason it is not 100% correct still, though, is that it didn't dawn on me when looking at the metadata below that the Require-Bundle headerhas been specified incorrectly. It should not be using "version", itshould be using "bundle-version" as the matching attribute. That's whatuncovered this bug in the framework.If "bundle-version" is used then the attribute correctly gets converted to a version range and you won't run into the parentheses bug, thus itshould start working on 3.2.2 too...and actually working correctly,since right now it is treating "version" as just a string with a value,not a version range. -> richard On Wed, Sep 14, 2011 at 10:47 AM, Richard Hall <[email protected] <mailto:[email protected]>> wrote: If you just try to install the bundle manually, does it still fail? If so, privately email me the bundle and I'll look at it. If not, maybe you can tell me how to recreate the issue. -> richard On Wed, Sep 14, 2011 at 10:30 AM, Martijn van Iersel <[email protected] <mailto:[email protected]>> wrote: Here is the MANIFEST.MF from the bundle org.apache.batik.transcoder.__jar. I see nothing wrong with it... Or is it possible that the error is in a different bundle? The error report mentioned org.apache.batik.transcoder.__jar... Manifest-Version: 1.0 Implementation-Vendor: The Apache Software Foundation (http://xmlgraph ics.apache.org/batik/ <http://ics.apache.org/batik/>) Bundle-Localization: plugin Bundle-__RequiredExecutionEnvironment: J2SE-1.3 Bundle-SymbolicName: org.apache.batik.transcoder Require-Bundle: org.apache.batik.bridge;__version="[1.7.0,1.8.0)",org.apache.batik.dom;version="[1.7.__0,1.8.0)",org.apache.batik.__dom.svg;version="[1.7.0,1.8.0)",org.apache.__batik.ext.awt;version="[1.7.0,__1.8.0)",org.apache.batik.svggen;__version="[1.7.0,1.8.0)",org.__apache.batik.util;version="[1.7.0,1.8.0)",org.__apache.batik.xml;version="[1.__7.0,1.8.0)"Export-Package: org.apache.batik.transcoder;__version="1.7.0",org.apache.batik.transcoder.image;__version="1.7.0",org.apache.__batik.transcoder.image.resources;version="1.7.0"__,org.apache.batik.transcoder.__keys;version="1.7.0",org.apache.batik.__transcoder.print;version="1.7.__0",org.apache.batik.transcoder.svg2svg;__version="1.7.0",org.apache.__batik.transcoder.wmf;version="1.7.0",org.__apache.batik.transcoder.wmf.__tosvg;version="1.7.0" Bundle-Version: 1.7.0.v200903091627 Bundle-Vendor: %providerName Bundle-Name: %pluginName Build-Id: 20080106-110642-EST (cam [Linux 2.6.22.8 i386, Java 1.3.1_19 -b03]) Implementation-Title: Batik transcoder Implementation-Version: 1.7+r608262 Import-Package: org.w3c.dom.svg;version="[1.1.__0,1.3.0)" Bundle-ManifestVersion: 2 -- Martijn On 14/09/11 17:19, Richard Hall wrote: Just a guess, but you forgetting to put quotes around the version range in your manifest file? You must specify version ranges with quotes, like: Import-Package: foo; version="[1.0.0,2.0.0)" -> richard------------------------------__------------------------------__---------To unsubscribe, e-mail: users-unsubscribe@felix.__apache.org <mailto:[email protected]> For additional commands, e-mail: [email protected] <mailto:[email protected]>
--------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]

