I have setup my atlassian sdk to be with Eclipse.
I tried to create a java file using com.atlassian.jira dependencies but got java errors saying the imports do not exist.
what is the correct way to do it with eclipse to recongize com.atlassian.jira* ?
Community moderators have prevented the ability to post new answers.
You need some useul things such as M2E for Eclipse, and could do worse than starting with the Atlassian SDK. To just start writing Java code without using Maven is going to be incredibly tough.
The Atlassian SDK is bundled with its own maven 2.10 binaries, it unforuntately doesn't work with Maven 3. If you are new to Maven, double the reason for following the SDK guide above.
Once you have a pom.xml, all dependencies will be 'realised' in Eclipse (ok, after a long wait whilst it downloads the universe).
Tricks: If you encounter difficulties, dont rely on Eclipse and M2E to download dependencies, it still has trouble in some scenarios. Always start off from the command line to pull in the bulk, once done, the IDE route works fine.
Andy or anyone,
Well I did install the SDK and followed the SDK setup and Eclipse setup. I have tried to do tutorial: https://developer.atlassian.com/display/DOCS/Plugin+Tutorial+-+Adding+your+own+Menu+Items+to+JIRA
and it worked.
But when I tried tutorial:https://developer.atlassian.com/display/DOCS/Plugin+Tutorial+-+Writing+Integration+Tests+for+your+JIRA+plugin
Importing did not find com.atlassian.jira.*.
dependencies with maven2 not set up.
I need to know how to setup maven to download JARs for com.atlassian.jira.
setting.xml and pom.xml examples would speed up my solution.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
With SDK in your path, you should be able to do 'atlas-create-jira-plugin' (follow prompts), then cd into that folder, and 'atlas-compile' to pull down main dependencies.
Its probable eclipse cannot locate the atlassian dependencies as you have not yet updated the Maven configuration in Eclipse to use the 'settings.xml' that details the repositories. This file is located in the SDK_HOME/apache-maven/conf/settings.xml
After importing the maven project into the eclipse workspace, judicious use of Update Project Configuration should kcik start dependencies to appear. At this point only, is it worth trying to write java code that imports packages.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Andy,
thanks for the update. I feel I am little bit clearer after looking through setting.xml and the POM.
After tracing the repository https://m2proxy.atlassian.com/repository/public and following the import path in the repository to the class I couldn't find it there. "com.atlassian.jira.issue.customfields.converters.DoubleCoverter" or others; So i couldn't make a dependency(s). IF my setting.xml is the basic file that comes with the SDK and have the only repository link(above), I would need another repository? Shouldn't the baisc sdk repository com with all the jira class to make example customfields for issues.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Actually I jist solved my problem....Dependenies just needed to be setup.
Thanks for the help
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.