概述
踩坑:(两次中招)IDEA创建maven项目慢!显示loading archetype list
标签(空格分隔): 踩坑
第一次
在某一天下午,突然发现在创建Maven工程还是一直lodading arhtype list。
在stackoverflow上一查,有一哥们有一样的问题:
When choosing the Create New Project option after launching IntelliJ 2017.2, I get this endlessly spinning wheel on the Maven tag, saying “Loading archetype list…”.
扫一眼下面的靠谱回答,很好!
I just hit this on 2017.2.3 (just updated now) on Fedora 24 (oops time to upgrade)
The immediate solution was to change the Maven settings (File > Settings > Maven) to use my on-machine Oracle JDK 1.8.0_144 instead the default “internal JRE” 1.8.0_152. Btw, the importer uses JVM option -Xmx768m by default.
照做:
File –> Settings –> Build –> Build Tools –> Maven –> Importing –> VM options for importer
将其内容改为,-Xmx1024m
再将其下面的JDK FOR importer改成本地的JDK
就成了
第二次
就在半个小时后,我又遇到了这个问题。可以我已经改过了。
于是我又在stackoverflow上搜,找到一个老爷子的回答:
down vote
accepted
Wait
Loading the full list of Maven archetypes seems to be quite an exertion for IntelliJ. Surprising, as I don't recall any such long delays in NetBeans.
So wait, be patient. May take a couple minutes. Make tea, pat the dog. Wait for the fan on your computer to spin up and then quiet again.
Use more memory
I currently have VM options for importer set to -Xmx2048m as shown in the Answer by Tonhofer.
I do not know if this point was key, but my problem has gone away «knock-on-wood». So this might be helping.
FYI… I have a 16-gig MacBook Pro (Retina, 15-inch, Late 2013) running Sierra 10.12.6 with two Java implementations, Java 8 Update 144 from Oracle and Java 9 beta jdk-9+181 from OpenJDK.
Quit, update repositories
While I do not understand what all is going on, it seems like this has been a workaround for me.
Quit IntelliJ, then launch again.
In Preferences/Settings, go to Build, Execution, Deployment> Build Tools > Maven > Repositories. Click each of the listed repositories, and click the Update button. A spinning wheel appears for the duration of the update.
A copy of each repository’s data is being downloaded and parsed on your local machine, descriptions of all the libraries known by that repository. Some of the repositories may be quite large with many listed projects. So this process may take a while, possibly more than several minutes.
When the updates are complete, try the New Project feature again.
大意就是除了等,再就是扩大内存,或者更新库。并且老爷子比较推荐更新库。
不过我点进去发现,我的库里啥也没有,更谈不上更新。
因此我只有吧内存调到2048,OK了
但是比较害怕。。这到底是咋回事。
最后
以上就是朴实帽子为你收集整理的踩坑:(两次中招)IDEA创建maven项目慢!显示loading archetype list踩坑:(两次中招)IDEA创建maven项目慢!显示loading archetype list的全部内容,希望文章能够帮你解决踩坑:(两次中招)IDEA创建maven项目慢!显示loading archetype list踩坑:(两次中招)IDEA创建maven项目慢!显示loading archetype list所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复