使用如下的pom.xml

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <groupId>com.nowcoder</groupId>
<artifactId>toutiao</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging> <name>toutiao</name>
<description>Demo project for Spring Boot</description> <parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.3.8.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
</properties> <dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-aop</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-velocity</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency> <dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies> <build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build> </project>

在maven -> reimport 时出现如下的错误

Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom:1.3.8.RELEASE from/to alimaven (http://maven.aliyun.com/nexus/content/repositories/central/): sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

网上的方法都不靠谱,最后使用这个办法解决:

https://maven.aliyun.com/mvn/search 中使用GAV搜索

group : spring-boot-starter-parent
artifactId: spring-boot-starter-parent
version: 1.3.8.RELEASE
把.pom文件下载到maven仓库的org/springframework/boot/spring-boot/1.3.8.RELEASE/中

然后重新reimport就可以了

解决IntelliJ无法导入maven包的问题的更多相关文章

  1. Intellij IDEA 导入Maven项目

    本人一直使用的eclipse, 但都说IDEA 是java界中最好使用的编辑器 ,所以开始了IDEA的学习,最近使用到了 IDEA 但是,既然编辑器有所差别,所以在使用过程中也难免遇到一些费劲的事情. ...

  2. 解决pycharm无法导入本地包的问题

    在用python写爬虫程序时,import 行无法通过,具体情况如下: pycharm运行程序后,程序pass了,但是出现了警告,如下图所示: 这是由于该程序不在根目录下,无法导入本地包,解决办法如下 ...

  3. intellij IDEA导入maven项目

    一.导入maven项目 1.打开intellij idea,点击File(如下图1),然后点击Open(如下图2)

  4. IntelliJ IDEA15导入jar包

    在IDEA中导入jar包和eclipse中是不一样的,那么现在我们就来看看在IDEA中如何导入jar包. 1.点击"File"-->"Project Structu ...

  5. 解决IntelliJ IDEA 创建Maven项目速度慢问题

    IntelliJ IDEA 创建maven项目速度很慢,甚至卡住不动了. 原因 IDEA根据maven archetype的本质,其实是执行mvn archetype:generate命令,该命令执行 ...

  6. IntelliJ IDEA导入Maven之后强制刷新项目解决无法识别为Maven项目的问题

    先点击左下角按钮以显示Maven Project 再点击右侧Maven Project 点击刷新按钮,当然也可以点击加号选择pom.xml文件. 最后是等待项目的更新.

  7. 解决pycharm无法导入本地包的问题(Unresolved reference 'tutorial')

    在用scrapy(python2.7)写爬虫的时候 from tutorail.items import DmozItem 这一行死活不成功 也就是出现 Unresolved reference 't ...

  8. IntelliJ IDEA导入Javax包(servlet-api.jar)

    在初次使用 IntelliJ IDEA 中,当你使用javax.servlet包下的类时(例:javax.servlet.http.HttpServlet), 在你会发现在IntelliJ IDEA里 ...

  9. 解决IntelliJ IDEA 创建Maven项目速度慢问题 DarchetypeCatalog

    原因 IDEA根据maven archetype的本质,其实是执行mvn archetype:generate命令,该命令执行时,需要指定一个archetype-catalog.xml文件. 该命令的 ...

随机推荐

  1. Linux 数据库MySql 安装配置教程!

    本文价绍Linux 相关mysql 安装和配置以及基本连接测试 1官网下载安装mysql-server # wget http://dev.mysql.com/get/mysql-community- ...

  2. 美化linux客户端zsh和oh-my-zsh

    linuxbashzshoh-my-zsh 一.安装zsh 二.安装oh-my-zsh 一.安装zsh 安装 zsh yum -y install zsh 替换默认shell chsh -s /bin ...

  3. XCode下在不同位置声明变量的用法(转)

    XCode下在不同位置声明变量的用法 方式一:直接在.h文件@interface中的大括号中声明. @interface Test : NSObject { NSString *str; // 私有变 ...

  4. 什么是实体关系图(ERD)? 转

    https://www.visual-paradigm.com/cn/guide/data-modeling/what-is-entity-relationship-diagram/#erd-data ...

  5. ajax检查用户名重复

    1.获取ajax对象 new XMLHttpRequest(); IE6-8: new ActiveXOject("Microsoft.XMLHTTP"); 兼容判断:if(XML ...

  6. impdp时报错ORA-39083&ORA-01917

    转自:http://www.codes51.com/article/detail_146662.html impdp时报错ORA-39083&ORA-01917ORA-39083: 对象类型 ...

  7. Eclipse安装windowsbuilder

    详见:https://www.cnblogs.com/plusplus/p/9864708.html https://www.cnblogs.com/lsy-blogs/p/7717036.html ...

  8. Codeforces 853B Jury Meeting

    题意 从城市1-n来的评审团到城市0商讨国家大事,离开和抵达的那一天不能讨论,飞机均当天抵达,给出所有飞机起飞抵达代价情况,问能否使所有评审员聚齐连续k天并返回,并求最小代价 思路 从前向后扫一遍,求 ...

  9. 【转】xshell 5评估期已过,不能访问的解决方案

    原文:https://blog.csdn.net/u010826617/article/details/79165540 重新安装Home & school 版本,原来访问的服务器信息不会丢失 ...

  10. python-----图片保存为视频

    #!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 2019/7/2 13:32 # @Author : xiaodai # -*- cod ...