Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from solutions to this type of problem

    I recently changed my computer, so I re-built the Spring Boot environment on IEDA. I encountered a problem. I checked it online for a long time and practiced it. Finally, it was resolved. Here is a detailed record of the steps.

    Problem description: After creating IDEA's Maven project, there was a problem that the Maven plug-in could not be downloaded.

    

    First of all, go to the Internet to check it naturally. Some people say that they are looking for Maven in IDEA->setting. The following Maven home path is inconsistent with the User settings file path underneath, and I am also the same here.

    Someone said that it may be that the plug-in cannot be downloaded from the configured source in the setting.xml, so I also modified the ali source, the code is as follows.

  <mirror>
     <mirror>
           <id>alimaven</id>
         <mirrorOf>*</mirrorOf>
         <url>https://maven.aliyun.com/repository/central</url>
     </mirror>
  </mirrors>

    The result was still not good. Later, I finally saw an article saying that the certificate was wrong when I downloaded it, so I couldn't follow it.

    So, I went to IEDA->setting, went to find Maven, and added the following words in importing, and the problem was solved. It seems that there is still a certificate issue.

    -Dmaven.wagon.http.ssl.insecure=true -Dmaven.wagon.http.ssl.allowall=true

    

But after trying it well, this problem occurred again. Later, I added the following code to the pom to specify the download warehouse, and the problem was solved. This is very strange. Why is the configuration in the setting in maven useless? And want to write one more here? I don't understand, please help.

    <repositories>
        <repository>
            <id>alimaven</id>
            <url>https://maven.aliyun.com/repository/public</url>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>alimaven</id>
            <url>https://maven.aliyun.com/repository/public</url>
        </pluginRepository>
    </pluginRepositories>

 

 

Guess you like

Origin blog.csdn.net/sxeric/article/details/113730894