I need to use a third-party jar in my plugin (Aspose.Words to be specific).
I know about using Maven local repository dependency with compile scope. Unfortunately, we need another method as long as this one doesn't work for our plugin - it is not Maven compatible maybe.
Maybe, some kind of placing words.jar to JIRA class path or something else?
Please, help.
Community moderators have prevented the ability to post new answers.
Hi,
You should 'import' this jar into your maven repository (or your company Nexus) https://maven.apache.org/guides/mini/guide-3rd-party-jars-local.html
Then update your pom.xml and keep compile scope.
It should work (hopefully ;-) - good luck
As I mentioned,
I know about using Maven local repository dependency with compile scope. Unfortunately, we need another method as long as this one doesn't work for our plugin - it is not Maven compatible maybe.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There is no such thing as a jar not compatible with maven. And as Atlassian relies heavily on maven to build plugins - you better 'import' this jar into your maven repos...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Issa is right on this, please read the documentation on how to install jars into a maven repo.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Issa, there is a signed library (Aspose.Words) to be specific that works wrong when extracted to another JAR root.
So I need a way to use it without extracting JAR content to the plugin.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Where should I run this command?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Muhammad Tayyab Bashir, for my specific case it was a problem with my environment (I am sure, it isn't your case). Just google how to use compile dependencies.
<dependency>
<groupId>com.aspose</groupId>
<artifactId>aspose-words-jdk16</artifactId>
<version>13.10.0</version>
<scope>compile</scope>
</dependency>
In order to package the plugin you need to add Aspose.Words library to the local Maven repository. Use the following command: mvn install:install-file -Dfile=Aspose.Words.jdk16.jar -DgroupId=com.aspose -DartifactId=aspose-words-jdk16 -Dversion=13.10.0 -Dpackaging=jar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Andrey Molchanov, I'm also making use of 3rd party dependency in my plugin (Suite utilities for Jira).
Whenever I try to compile it gives error that it couldnt resolve the dependency because it couldn't find it maven public repo.
Can you please help me out with this?
Take a look at the following questions posted by me for more details if you need it.
https://answers.atlassian.com/questions/39154669And How to resolve third party dependencies in plugin?
I would appreciate it greatly.
Many thanks in advance
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
OK, it was a simple encoding mistake that has been solved using I18N. Thank you, guys!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Issa, building an OBR is not an option as long as the library in not an OSGi bundle in its own right. So it has its own manifest file. I attached the library JAR. Any ideas? ()
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes indeed for the OSGI requirements.
I'm clueless on what to do next. Either fix the problem with the JAR authors or fix it yourself (make it a OSGI bundle).
Maybe someone more knowledgeable than me might help.
Good luck.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Community moderators have prevented the ability to post new answers.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.