Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IntelliJ Stuck "Scanning Maven Projects"

I just freshly installed IntelliJ Community Edition. When I try to import a Maven project, it gets stuck on the step "Scanning Maven Projects" and says its reading ".../pom.xml". It holds here for about 10 minutes, quits out of this window, and then doesn't import the projects at all.

Some other posts have recommended setting up /etc/hosts file, but mine is already set up with 127.0.0.1 localhost. I've set up the proxy information in IntelliJ and in my .m2/settings.xml file as well.

Any suggestions on how I can get IntelliJ just to open up my project?

Best, Keren

like image 694
Keren Avatar asked Sep 21 '16 15:09

Keren


People also ask

Why is IntelliJ not importing Maven dependencies?

If the dependencies weren't imported correctly (IntelliJ IDEA highlights them), try to perform the following actions: You can check your local maven repository in the Maven | Repositories settings and try to update it. You can check the jar file of the local . m2 repository to see if it was downloaded correctly.

How does IntelliJ recognize Maven project?

Add Maven supportIn the Project tool window, right-click your project and select Add Framework Support. In the dialog that opens, select Maven from the options on the left and click OK. IntelliJ IDEA adds a default POM to the project and generates the standard Maven layout in Project tool window.


1 Answers

Already answered here unable to import maven project into Intellij Idea :looking for available profile

The solution was to edit the /etc/hosts file and add at the first line:

127.0.0.1 localhost localhost

Also, make sure localhost is mapped only once.

(answered in the comments. I am just leaving this answer for reference as it's one of Google's first results when searching for this problem)

like image 174
GiovanyMoreno Avatar answered Sep 18 '22 05:09

GiovanyMoreno