-
1. Re: "Unresolved constraint in bundle" deploy exception
ffang Aug 2, 2010 8:46 PM (in response to rkozura)Hi,
This error means you are missing a bundle which export com.technicacorp.util.distributor package.
Freeman
-
2. Re: "Unresolved constraint in bundle" deploy exception
rkozura Aug 3, 2010 1:25 AM (in response to ffang)Thank you for your suggestion. So I should add an export package header to the external jar's manifest file?
I tried to "osgi" an external jar using a tool called bnd. It worked and added export package headers, but when I rebuilt and deployed, I still got the same run time error
I cleaned up the MANIFEST file a little bit for readability:
Manifest-Version: 1.0
Created-By: 1.5.0_22 (Sun Microsystems Inc.)
Bnd-LastModified: 1280811698546
Export-Package: com.technicacorp.util.distributor
Bundle-Version: 0
Bundle-Name: technica-util
Originally-Created-By: 1.5.0_17-b04 (Sun Microsystems Inc.)
Bundle-ManifestVersion: 2
Bundle-SymbolicName: com.technicacorp.util
Tool: Bnd-0.0.384
I feel like I am missing something important. Any help is greatly appreciated.
Thank you.
-
3. Re: "Unresolved constraint in bundle" deploy exception
ffang Aug 3, 2010 1:55 AM (in response to rkozura)Hi,
You need install technica -util.jar as a bundle which export com.technicacorp.util.distributor package.
Freeman
-
4. Re: "Unresolved constraint in bundle" deploy exception
davsclaus Aug 3, 2010 1:55 AM (in response to rkozura)You can read about deploying and using OSGi here
http://fusesource.com/products/enterprise-servicemix4/#documentation
There is a OSGi guide from that link.
-
5. Re: "Unresolved constraint in bundle" deploy exception
rkozura Aug 3, 2010 11:41 AM (in response to davsclaus)I resolved my issue by issuing the command "osgi:install technica-util.jar" within felix. I then started the bundle with the command "osgi:start 'number of the bundle to start'" and I no longer get my run-time error.
Thank you for your help.
Edited by: rkozura on Aug 3, 2010 3:40 PM
-
6. Re: "Unresolved constraint in bundle" deploy exception
rkozura Aug 17, 2010 11:23 AM (in response to rkozura)I am sorry to bump this thread, but is there any other way I could have solved this? After trying to develop other web services, I keep getting back to the unresolved constraint issue and it seems sloppy to keep manually adding jar files.
I exported the correct class "com.technicacorp.util.distributor" in the manifest of the jar (that is in the Maven repository), and I imported the package and have the jar as a dependency in the pom.
Anyone have any hints? I would greatly appreciate it.
-
7. Re: "Unresolved constraint in bundle" deploy exception
divakar Aug 17, 2010 1:34 PM (in response to rkozura)You need to install the third party jar in the karaf,
Use this command if it works for you,
osgi:install -s wrap:file:///C:/Bridge/wlfullclient.jar
Then include the package name in the Import-Package
-
8. Re: "Unresolved constraint in bundle" deploy exception
rkozura Aug 17, 2010 2:56 PM (in response to divakar)Thank you divakar, but this is the way I am doing it now. Is there any possible way to not manually install the jar into osgi?
For instance, can't I just put the jar inside of the local repository and configure the pom to install the jar automatically?
I know I am knit picking, but I am trying to be consistent.
-
9. Re: "Unresolved constraint in bundle" deploy exception
divakar Aug 17, 2010 3:00 PM (in response to rkozura)I came across a help saying that, you can install the jar in the local maven repository and include the dependencies in the pom.xml.
BTW I am not an expert in here, I am also try to get some help!
Cheers,
-
10. Re: "Unresolved constraint in bundle" deploy exception
ffang Aug 17, 2010 9:59 PM (in response to rkozura)Hi,
You can put all necessary bundles in features file to do provisioning.
Basically a feature is a set of bundles which can do certain functionality.
Take a look at to get more details.
http://karaf.apache.org/46-provisioning.html
Freeman