so you have 2 jars with the same name (what jars are that)?
that also don’t have the correct manifest entries? (like “Bundle-SymbolicName” or “Automatic-Module-Name”) which are used by default (and jar name is just a fallback)
but those 2 jars are really completely different things?
I tried doing the renaming of the JAR but I obviously got something wrong because the warnings went away but the JAR files were not included in the WAR. I think it may be something to do with the jnlp file but I am not a Java expert so not sure.
Having played around with it this morning I do have a (very dodgy) workaround for the moment. I export the WAR file which is then missing the JAR files, open it using WinZip, add in the missing JAR files, update the plugins.properties file to include the addtional JAR file details and then upload the amended WAR file. This works for now but is a VERY tedious process.
I have the same issue. Dependency problems because of duplicate libraries. For me, the following jar files are duplicate (after updating all plugins to the newest versions):
Dependency ‘/plugins/velocityreport/commons-collections-3.2.1.jar’ is not exported because another commons-collections-3.2.1.jar with a higher version (3.2.2) is already present in ‘/plugins/servoy_jasperreports/commons-collections-3.2.2.jar’.
Dependency ‘/plugins/velocityreport/fs-parser.jar’ is not exported because ‘fs-parser.jar’ is already present in the lib folder.
Dependency ‘/plugins/drmaison-lib/commons-logging.jar’ is not exported because another commons-logging.jar with the same version (1.1.1) is already present in ‘/plugins/servoy_jasperreports/commons-logging-1.1.1.jar’.
Dependency ‘/plugins/velocityreport/fs-commons.jar’ is not exported because ‘fs-commons.jar’ is already present in the lib folder.
Dependency ‘/plugins/drmaison-lib/mail.jar’ is not exported because ‘mail.jar’ is already present in the lib folder.
I changed to path in the jnlp files and deleted the unnecessary libraries. Will soon find out, if it works.
Is there a better solution?
ah wait you point the jnlp reference in the jasper to the one of velocity?
I guess the velocity plugin is not really a smart client plugin? but purely a server side plugin?
If you are using smart client you should sign all your stuff with your own certificate if possible
What you also can do is delete the duplicate jar of the velocity plugin and just use the jasper one…
I did try a new install of Servoy (2022.3.0 -releaseNumber 3742, ARM version) and installed the newest versions of jasper reports plugin (Barcode_Servoy_JasperReports_Plugin_v.2022.3_6.19.1) and velocity. I still see the above mentioned dependency problems. I fixed them by using the libraries in the jasper reports plugin (as you suggested) and Servoys lib folder by changing the entries in the jnlp files and deleting the duplicate jar files.
Export and deployment of war file works now, but launching the smart client still raises the following error. I can solve it by using the older version of the jasper reports plugin (Barcode_Servoy_JasperReports_Plugin_v.6.12.2_2020.03), which is not really what I want. Any idea?
Thanks and regards
Birgit
[attachment=0]Screenshot 2022-05-31 at 14.30.58.png[/attachment]
servoy 2022.3 and jasper 2022.3_6.19.1 are all signed with the same stuff
if you deploy it without velocity does it work?
because velocity is not signed by us
And you are saying you don’t get a warning when exporting?
because Velocity is not signed by us, but does ship by itself with jars which are duplicates i see a IText (but a much newer version i think this is not a problem) and so on.
but the way to fix this is really having your own certificat and sign everything with your own one.
Don’t depend on others to provide this
Hi Johan
We do sign all jar files (lib, plugins and beans folder) with our own certificate.
As long as there are duplicate libraries (list is above), I cannot create the war file. Export fails.
As soon as all dependency problems are solved, I can create the war file and deploy it. But then the signing error raises when launching the smart client.
I solved it just now by removing the first entry in the servoy_jasperreports_commons.jar.jnlp file which points to commons-lang library (lib/org.apache…).
(In an earlier version of the jasperreports plugin, the number of libraries listed in this file is much smaller, that’s why I started deleting).
Is it possible, that this library conflicts with an other library on the server (production)? Any other idea?
Thanks and regards
Birgit
if you do sign everything with the same certificate you can’t have those above problems
because there is only 1 signing then…
make sure you remove the existing signing and that everything in application_server/lib and all the plugins and beans are signed with your certificate…
sorry but then you don’t sign correctly, or not sign everything. because if everything is signed with 1 certificate you can’t get “JAR resources are signed by a different certificate” because there shouldn’t be a different certificate. there is only 1, yours…
i guess you adjusted your self that jasperreports_common.jnlp and placed that one in there right?
That is a problem that jar is copied from the developer/plugins/x to the application_server/lib at the moment the WAR is generated
That one is signed by us.
i guess you included this in the jasper jnlp because we removed it from the velocity plugin? (because velocity ships an old one, 2.4)
what you can do is is add another jnlp file to this like “servoy_common.jnlp” and have something like:
and have there the lang3 jar reference by itself…
Or after the WAR is created, then extract the WAR once and then do the full signing (plugins dir and WEB-INF/lib)
so you are sure that the actual stuff you ship is signed.
Sorry, I do not understand. Which library is generated? org.apache.commons.lang? I can’t find it anywhere on my system (development environment).
I did not include it in the jnlp. Please have a look at the jnlp files in the jasper_reports plugin (Barcode_Servoy_JasperReports_Plugin_v.2022.3_6.19.1). I did not add anything to the servoy_jasperreports_commons.jnlp file. Just deleted the first dependency (org.apache.commons.lang) now.
Because of your former post I solved the dependency errors by pointing from velocityreport and drmaison to jasperreports or the lib folder. And deleting duplicate libraries in velocityreport and drmaison.
By the way: You could copy my experience: Install Servoy 2022.3 (ARM , Velocity V3, Barcode_Servoy_JasperReports_Plugin_v.2022.3_6.19.1, UserManager with drmaison-lib, poi (for svy_utils_excel). Create a WAR. You’ll see the same dependency errors. Fix them, install the WAR and see, it you can launch a SC. I did this 4 times now with different plugin versions.
yes that is true, the common.jnlp of jasper now points to the commons.lang3 jar that we copy from the developer plugins at the moment we generate the WAR
[install\developer\plugins\org.apache.commons.lang3_3.12.0.jar is copied into the WAR (WEB-INF/lib)
that file is signed by our cerficate, so if you just sign everything in application_server\lib and application_server\plugins then that jar will not be signed because it is not in there…
you can try to just sign that jar inside the developer\plugins\ dir
or you need to sign the full WAR after it is created, so extract the WAR (its a zip), sign everything in root/plugins and root/beans but also in root/WEB-INF/lib
Thank you for the response. That solved it!
I did sign the library (developer plugin), did not do any changes in the commons jnlp of the jasper plugin and had no problem to launch smart client.