Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
What do i need to do if i want to add a custom maven dependency?
Hi,
i would like to add a custom maven dependency in a portlet used in Liferay 7.4.
Im migrating from Liferay 6.2 to Liferay 7.4 and I cannot use this Library on this newest Liferay.
What do i need to do on the pom.xml file in order for Liferay 7.4 to load this jar Library?
Thanks in advance
If that dependency is an OSGi bundle, you should deploy it to the runtime just like your own plugin.
If it's not, and it's Open Source: Check if you can find it somewhere converted into an OSGi bundle or consider doing the work yourself and try to push it upstream.
If you can't make it a bundle, you might need to bundle its code within your own plugin. In Liferay Workspace (gradle-based), this is called "compileInclude" - I can't give you the exact recipe for Maven.
thank you very much, i could make my maven project an OSGi Bundle and deploy it. Unfortunately this bundle consists of more dependencies. And some of those dependencies arenot OSGi Bundles. Ill try with gradle
Powered by Liferay™