I have atlassian-jira.4.4.1 dependency and have downloaded the source (we have a license) and right clicked on the dependency and did "Add Local Source". The source shows up in my local Maven repo, so I know that worked. However, if I navigate to anything in that dependency, I just get the reflected Java stubs and not the attached source. Ubuntu 11.04 (GNU/Linux 2.6.38-11-generic-pae i686) NetBeans IDE 7.0.1 (Build 201107282000) Java 1.6.0_24; Java HotSpot(TM) Client VM 19.1-b02 Attachments to follow.
Created attachment 111870 [details] screenshot: source jar in local repo
Created attachment 111871 [details] screenshot - maven plugin version
Created attachment 111872 [details] screenshot: shows sources attached to dependency #1
Created attachment 111873 [details] screenshot: shows sources attached to dependency #2
Created attachment 111874 [details] screenshot: navigating to source #1
Created attachment 111875 [details] screenshot: navigating to source #2
irritating, but I'm not sure this is a P2. :)
Without access to the sources myself, I cannot diagnose for sure. My best guess is that your atlassian-jira-4.4.1-sources.jar is not in the correct format; for example, com/atlassian/jira/plugin/report/impl/AbstractReport.java is not a ZIP entry.
I independently had the same issue myself. I tried several different file names and directory structures for the docs jar, including exactly mimicking the docs jars of other items in the repository. Is it possible that it won't show up until you manually reindex the local repository? I didn't try that...
Jesse's observation on the structure of the .jar is correct in my case. The source archive provided by Atlassian for JIRA is not compatible. I am currently building JIRA from source and executing 'atlas-mvn source:jar' and will then manually install those locally (I'm not a maven wizard so I don't know how to get the source jars into the local repo without manually editing each of the 100 pom files before calling 'atlas-mvn install' to include the source jars in the deployment). athompson: I would expect you would have to manually re-index the local repository. I have done that each time I have made changes to the local repo since I didn't see any background task doing it. I've conceded this isn't a P2, but if it actually is a bug (and not just a PEBCAK), it's more than irritating: it drastically reduces productivity.
If you have to reindex manually that's still a bug IMO, so can we reopen?
There should be no need to reindex the local repository so far I as know. As soon as jar:file:/home/mike-jansen/.m2/repository/com/atlassian/jira/atlassian-jira/4.4.1/atlassian-jira-4.4.1-sources.jar!/com/atlassian/jira/plugin/report/impl/AbstractReport.java exists, the IDE should be able to find it.
Hmm, it doesn't work for me. Mike, how exactly did you get it to work?
I haven't gotten it to work yet. The maven projects for the dependencies that I'm dealing with aren't creating the source jar properly that I need and I haven't had time to get back and resolve it. I don't know that it doesn't work, I just haven't had a chance to determine if it does.