0

I am getting uses constraint violation as below while installing a feature in Apache Karaf (karaf framework is felix and version is 4.2.1)

could not be resolved. Reason: Package uses conflict: Import-Package: org.apache.http.entity; version="0.0.0"

After googling , came to know that "Dependency Chain" can help in root causing the issue. but I do not know the steps to follow to get this dependency chain printed in the logs or osgi console

Example Dependency chain is given in the below URL: Dependency chain conflicts for Hibernate and Apache Felix

Thanks in advance

Community
  • 1
  • 1
Vikram Darsi
  • 79
  • 2
  • 8

1 Answers1

2

If you use the felix framework this should be printed either on the console and/or in the logfile while starting the bundle. With Karaf you also can take a look at bundle:tree-show [bundle-id]. This will show you all bundles your bundle depends on.

Achim Nierbeck
  • 5,265
  • 2
  • 14
  • 22
  • Hi Achim, thanks for the reply... Karaf version used is 3.0.1, which is bundled with felix frame work 4.2.1 and is enabled using etc/config.properties. Still I could not see the chain printed either on the console/log file. Not sure this version of felix framework supports dependency chain feature or not. Is there any way to upgrade this felix to latest 4.6.0 ? bundle:tree-show and dependency chain gives the same information? – Vikram Darsi Feb 28 '15 at 18:38
  • Actually there shouldn't be any need to upgrade to a newer version, as the one used in Karaf 3.x is already up to date. Another thing, what kind of bundle are you installing here? Looks like you're trying to use the felix http-service. If you just install the http or war feature you'll install the karaf supported Pax Web project. – Achim Nierbeck Mar 01 '15 at 08:15