This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
E.g. from MavenSourceJavadocAttacher, resolving javax.help:javahelp:2.0.05:sources:jar does not work, at least not with my Nexus config. One problem is likely that if there is no (Maven) project open - e.g. because you are just browsing a class opened from a JAR in Local - MSJA lists no remote repositories, whereas it ought to list central (mentioned in _maven.repositories); can be solved in the case of central by just hardcoding that id, but not clear how to solve generally, except by giving a remote repo with a dummy URL and the right ID and hoping there is a mirror definition. But even with a project open, it still does not work. ME.resolve apparently ought to be populating more fields in the ArtifactResolutionRequest, but that does not suffice.
(In reply to comment #0) > if there is no (Maven) project open Punting on this for now; various things do not work unless appropriate repos are defined. > that does not suffice. Seems those fields are ignored, but are searched for in the RepositorySystemSession.
core-main #9d464b81555e
Integrated into 'main-golden' Changeset: http://hg.netbeans.org/main-golden/rev/9d464b81555e User: Jesse Glick <jglick@netbeans.org> Log: #202703: MavenEmbedder.resolve not working
Not working today. org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolve gets a RepositorySystemSession with the correct mirrors configured, but its Collection<? extends ArtifactRequest> refer to the unmirrored location, and it does not itself seem to consult mirrors. No idea how I made it work before.
Weirder - it seems that EmbedderFactory.createRemoteRepository sometimes, but not always, replaced the URL in a repo with that of its mirror. When it works, it is because DefaultArtifactRepositoryFactory.injectSession replaces the repo URL with its mirror. Seems that it all depends on whether legacy support was yet set up in the current thread.
core-main #3ea001430dd6
Integrated into 'main-golden' Changeset: http://hg.netbeans.org/main-golden/rev/3ea001430dd6 User: Jesse Glick <jglick@netbeans.org> Log: #202703: MavenEmbedder.resolve ignoring mirror settings