Bootstrap

遇到的报错们

1org.thymeleaf.exceptions.TemplateInputException

1:视图渲染失败异常:没有往请求域中放参数

Caused by: org.springframework.expression.spel.SpelEvaluationException: EL1007E: Property or field 'id' cannot be found on null

2java.lang.IllegalStateException: Failed to load ApplicationContext

①java.lang.IllegalStateException: Failed to load ApplicationContext

②Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'hospitalSetServiceImpl': Unsatisfied dependency expressed through field 'baseMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.atguigu.yygh.mapper.HospitalSetMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}

③Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.atguigu.yygh.mapper.HospitalSetMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}

解决方法:

①启动类是否能扫描到该类

※②配置类是否没有配置

③查看mysql数据库服务器是否开启 或数据库信息名称是否匹配

3docker: 报错E: Package 'iproute2' has no installation candidate

在学习通过docker容器是否可以访问Linux宿主机时,运行apt update && apt install -y iproute2 && apt install -y net-tools && apt install -y iputils-ping 命令,结果下载完后,出现E: Package 'iproute2' has no installation candidate报错

当时看了这个文章 E: Package 'openswan' has no installation candidate - 简书 (jianshu.com)

;