Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Virgo » Disable recursive jar manifest 'Class-Path' verification
Disable recursive jar manifest 'Class-Path' verification [message #1758820] Mon, 03 April 2017 13:56 Go to next message
Emanuel Couto is currently offline Emanuel CoutoFriend
Messages: 4
Registered: April 2017
Junior Member
Hi

When I try to start VTS the engine tries to check if the elements of the 'Class-Path' entry exist. However one problem is that some jars have a wrong 'Class-Path' entry.

I have attached the following files:
- The 'error.txt' file shows the error I'm getting.
- The 'classpath_entry.txt' shows the 'MANIFEST.MF' of the jar that is causing the problem. In this case it's the 'msv-20050913'.
- The 'dependency_tree.txt' file is just to show that 'xfire-jaxb' depends on 'msv-20050913'.

I solved some of these issues by upgrading the dependencies but xfire is already in the latest version.

Is there a way to disable de 'Class-Path' verification?

Re: Disable recursive jar manifest 'Class-Path' verification [message #1758822 is a reply to message #1758820] Mon, 03 April 2017 14:18 Go to previous messageGo to next message
Violeta Georgieva is currently offline Violeta GeorgievaFriend
Messages: 11
Registered: October 2016
Junior Member
Hi,

In your META-INF folder add/edit context.xml to contain the following:

<Context>
...
  <JarScanner scanManifest="false" />
...
</Context>


More information can be found here
http://tomcat.apache.org/tomcat-8.5-doc/config/jar-scanner.html

Best Regards,
Violeta
Re: Disable recursive jar manifest 'Class-Path' verification [message #1758824 is a reply to message #1758820] Mon, 03 April 2017 14:24 Go to previous messageGo to next message
GianMaria Romanato is currently offline GianMaria RomanatoFriend
Messages: 57
Registered: November 2015
Member
Hi Emanuel,

It would be useful if you shared the version number of Virgo.
In any case, I don't think that it's possible to disable the verification. In my opinion that check is useful: what if you have an issue in your build scripts and a deployed bundle does not include a required JAR; would you be happy if Virgo did not report this?

I would suggest you to use BND or the Apache Felix Maven Bundle Plug-in [1] to repackage the offending bundle with correct OSGi metadata.
This is common in my company, we often find libraries that have wrong or missing OSGi metadata and we use the Apache Felix Maven Bundle Plug-in to repackage the libraries under a different group-id into our binary repository.

GianMaria.


[1] http://felix.apache.org/documentation/subprojects/apache-felix-maven-bundle-plugin-bnd.html
Re: Disable recursive jar manifest 'Class-Path' verification [message #1759059 is a reply to message #1758824] Wed, 05 April 2017 16:25 Go to previous messageGo to next message
Emanuel Couto is currently offline Emanuel CoutoFriend
Messages: 4
Registered: April 2017
Junior Member
The version I'm using is 3.7.0.RELEASE.

To me it seems the later solution by fixing the OSGI metadata is cleaner. It's still good to know how to disable such check.

Many thanks.
Re: Disable recursive jar manifest 'Class-Path' verification [message #1759171 is a reply to message #1758824] Fri, 07 April 2017 09:52 Go to previous messageGo to next message
Emanuel Couto is currently offline Emanuel CoutoFriend
Messages: 4
Registered: April 2017
Junior Member
Hello

I have confirmed the repackaging solution works. In fact there are pre-made bundles in the maven repository:

https://mvnrepository.com/artifact/org.apache.servicemix.bundles

I'll try disabling 'class-path' verification next.

Thanks again
Re: Disable recursive jar manifest 'Class-Path' verification [message #1759178 is a reply to message #1759171] Fri, 07 April 2017 11:13 Go to previous message
Emanuel Couto is currently offline Emanuel CoutoFriend
Messages: 4
Registered: April 2017
Junior Member
Disabling the manifest scan didn't work. Not sure why. The repackaging solution is good enough for me though.

To me the issue is closed.

Thanks
Previous Topic:Virgo 3.7.0.RELEASE has been shipped
Next Topic:Configuring security context for "/admin"
Goto Forum:
  


Current Time: Sat Dec 14 04:13:09 GMT 2024

Powered by FUDForum. Page generated in 0.03825 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top