IntelliJ IDEA 2017.3.5旗舰版下载依赖卡顿求助
Hey there, let's tackle that frustrating dependency download lag you're dealing with in IntelliJ IDEA 2017.3.5 Ultimate. I've got a handful of practical, tested solutions to help speed things up:
1. Switch to a Domestic Maven Mirror
The default Maven Central Repository is hosted overseas, which is often the main culprit for slow downloads. Update your Maven settings.xml to use a local mirror like Alibaba's:
Open your Maven configuration file (usually located at {Maven_Home}/conf/settings.xml or ~/.m2/settings.xml), and add the following inside the <mirrors> section:
<mirror> <id>aliyunmaven</id> <mirrorOf>central</mirrorOf> <url>https://maven.aliyun.com/repository/public</url> </mirror>
If you're using IDEA's built-in Maven, you can specify your custom settings.xml in IDEA's settings (more on that below).
2. Verify IDEA's Maven Configuration
Double-check that IDEA is using the right Maven setup:
- Go to
File > Settings > Build, Execution, Deployment > Build Tools > Maven - Ensure Maven home directory points to your local Maven installation (not the IDEA-bundled one, which might lack custom mirror configs)
- Check the Override box next to
User settings fileand select your modifiedsettings.xml - Confirm the Local repository path is correct and you have write permissions for that folder
3. Clear Maven Cache & Force Update
Corrupted or incomplete cached dependencies can cause hangs. Here's how to fix it:
- Navigate to your local Maven repository (default:
~/.m2/repository) and delete any folders with broken dependencies or the_remote.repositoriesfiles - In IDEA's right-side Maven panel, click
Cleanfollowed byInstall - Alternatively, run this command in your project root to force update snapshots:
mvn clean install -U
4. Adjust IDEA's Import Timeout & Memory
Sometimes IDEA's default settings aren't enough for large dependency trees:
- Go to
File > Settings > Build, Execution, Deployment > Build Tools > Maven > Importing - Increase the
VM options for importer(e.g.,-Xmx1024mto give more memory to the import process) - Raise the
Timeout for downloading sources/javadocvalue (try setting it to 300 seconds to avoid premature timeouts)
Your Partial pom.xml (for reference)
<modelVersion>4.0.0</modelVersion> <groupId>com.deal.padang</groupId> <artifactId>padangdeal</artifactId> <version>0.0.1-SNAPSHOT</version> <packaging>jar</packaging> <name>padangDeal</name> <description>Demo project for Spring Boot</description> <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-b... </parent>
内容的提问来源于stack exchange,提问作者Timothy

