0

I have following snippet in pom.xml:

<dependency>
    <groupId>org.apache.mina</groupId>
    <artifactId>mina-core</artifactId>
    <version></version>
</dependency>

When I put cursor in between version tags and do CTRL+Space for displaying options, I expect to see the versions available, instead IDE shows only:

  • RELEASE
  • LATEST

I cannot find any configuration to this behavior in IDE.

Thanks for help.

kensai
  • 943
  • 9
  • 16
  • Try updating repository index, see http://stackoverflow.com/a/42427510/104891. – CrazyCoder Mar 23 '17 at 12:43
  • I tried, maybe I am using my own Nexus group which is proxing about 15 external internet repositories. Idea downloads the index fine, it has 2,5 GB size, so I am not sure if the index is corrupted or too big. In case of corrupted I am not positive much as soon as in Nexus is browsable. – kensai Mar 23 '17 at 19:27
  • Ok, something is wrong I found 2017-03-23 19:29:45,381 [27843728] WARN - #org.jetbrains.idea.maven - Failed to update Maven indices for: [prokyon-repository,central] http://blackhole.archenroot.org:50001/nexus/content/groups/public org.jetbrains.idea.maven.server.MavenServerIndexerException ---> Caused by: java.lang.NullPointerException – kensai Mar 23 '17 at 19:30

1 Answers1

0

I went trough link provided in comment by CrazyCoder recursively and finally found issue in idea.log:

2017-03-23 19:29:45,381 [27843728] WARN - #org.jetbrains.idea.maven - Failed to update Maven indices for: [prokyon-repository,central] blackhole.archenroot.org:50001/nexus/content/groups/public org.jetbrains.idea.maven.server.MavenServerIndexerException ---> Caused by: java.lang.NullPointerException  

I tried refresh index multiple times during day (3x) and still the same failure. I did also optimizations of index on Nexus server, no luck.

Finally I started suspecting the size of index as root cause, so removed from the Nexus repository group most of proxy repositories (I left there only Attlasian, Sonatype and Central public proxies). This reduced size of index from 2,5GB to < 400MB. With such size the update in Intellij Idea finished without exception and now the IDE offers again the versions + RELEASES+LATEST as well, which is expected correct behaviour.

So I think the size of the index was probably the root cause.

Solution: Instead of linking into maven one BIG repository group, it might be better to list in settings.xml maven configuration file all proxies as mirrors and let IDE download multiple smaller indexes which the maven plugin could process without issue.

Community
  • 1
  • 1
kensai
  • 943
  • 9
  • 16
  • In general, maven repository should start using XZ or defacto LZMA2 or some other then GZip algorithm for compression. – kensai Aug 24 '17 at 09:14