
springboot
文章平均质量分 68
sinJack
别让太多的欲望阻碍着你前进的方向
展开
-
mapper.xml文件启动报错:Result Maps collection already contains value for
分析:根据提示,可以知道,是ClientDetailMapper.xml文件有错误,导致报错。异常信息:Caused by: java.lang.IllegalArgumentException: Result Maps collection already contains value for com.kehua.business.client.dao.ClientDetailMapper.findMemberMap可能导致异常的原因:在xml中,存在id相同的sql<select原创 2020-07-07 13:58:43 · 32244 阅读 · 0 评论 -
多maven项目的搭建和依赖关系详细讲解
项目结构各工程介绍1、父工程<?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原创 2020-09-02 19:18:50 · 33884 阅读 · 1 评论 -
mybatis配置文件报错的几种情况
mybatis配置文件报错的几种情况1、mybatis配置文件的标签顺序不对。提示以下错误信息(鼠标放置在标签上):The content of element type “configuration” must match “(properties?,settings?,typeAliases?,typeHandlers?,objectFactory?,objectWrapperFactory?,reflectorFactory?,plugins?,environments?,databaseIdPr原创 2020-05-11 15:38:59 · 32833 阅读 · 0 评论 -
mybatis在maven项目中运行报错
主要异常信息如下:org.apache.ibatis.binding.BindingException:Invalid bound statement(not found):com.example.dao.IStuDao.insert分析:根据报错信息,可以知道项目中存在这个接口,但是映射文件中没有实现这个接口。检查原因:可以通过查询编译后的classes文件的方式,查看异常相关的文件是否全部正常编译生成了对应的.class文件。很明显,可以看出。编译后的文件中,并没有发现mapper接口对应原创 2020-06-10 12:02:12 · 32571 阅读 · 0 评论 -
获取Spring容器bean
springboot项目正常启动,但是访问接口404。原创 2023-03-18 19:10:28 · 1448 阅读 · 0 评论 -
redis锁和分布式锁的实现
redis环境搭建redis在java、spring、springboot中的简单应用redis锁1、添加依赖<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-redis</artifactId></dependency>2、application.yml配置sprin原创 2020-10-08 16:25:03 · 33226 阅读 · 3 评论 -
Springboot整合RabbitMQ详细讲解
搭建RabbitMQ环境Springboot整合RabbitMQ1、添加整合依赖<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-amqp</artifactId></dependency>2、配置application.yml提供者1)创建交换机和队列@Configurati原创 2020-08-26 16:47:28 · 34220 阅读 · 1 评论 -
springboot项目本地运行正常,部署服务器报错
报错信息Description:Reason: Failed to determine a suitable driver classConsider the following:If you want an embedded database (H2, HSQL or Derby), please put it on the classpath.If you have database settings to be loaded from a particular profile you may原创 2020-08-06 16:40:02 · 36870 阅读 · 0 评论 -
Springboot整合Freemarker详细过程
基本配置、测试1、导入依赖<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-freemarker</artifactId></dependency>2、准备一个Freemarker模板(.ftl)3、注入Configuration对象(freemarker.template包下)原创 2020-08-05 15:05:34 · 34324 阅读 · 2 评论 -
Springboot整合Solr详细讲解
搭建Solr环境SpringBoot整合Solr1、添加整合依赖<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-solr</artifactId></dependency>2、配置application.yml3、注入Solr对象,实现crud@RunWith(Spr原创 2020-07-28 14:33:44 · 33162 阅读 · 0 评论 -
Required String parameter ‘msg‘ is not present
异常信息:Whitelabel Error PageThis application has no explicit mapping for /error, so you are seeing this as a fallback.Tue Jul 28 23:32:38 CST 2020There was an unexpected error (type=Bad Request, status=400).Required String parameter ‘msg’ is not present原创 2020-07-20 10:56:55 · 33261 阅读 · 0 评论 -
springboot整合mybatis的简单过程
前言什么是springboot?Spring Boot 是由 Pivotal 团队提供的全新框架。Spring Boot 是所有基于 Spring Framework 5.0 开发的项目的起点。Spring Boot 的设计是为了让你尽可能快的跑起来 Spring 应用程序并且尽可能减少你的配置文件。项目的框架...原创 2020-07-16 08:46:57 · 32073 阅读 · 0 评论 -
Springboot整合FastDFS
搭建FastDFS环境前端通过WebUploader组件实现文件上传SpringBoot整合FastDFS1、添加springboot和FastDFS整合依赖 <dependency> <groupId>com.github.tobato</groupId> <artifactId>fastdfs-client</artifactId> <version>1.26.6</version>原创 2020-06-22 16:54:37 · 32430 阅读 · 0 评论 -
druid监控中心的使用和sql监控
添加依赖相关配置注意: 只有配置druid.filter.stat.enabled=true时,才能看到sql监控页面的sql执行情况。原创 2020-06-18 18:59:42 · 32619 阅读 · 0 评论 -
springboot项目中访问不到html页面问题
描述:搭建了一个简单的springboot项目。启动时通过请求访问页面。发现报404页面找不到。项目结构:导入thymeleaf的依赖。templates目录controller层分析问题:仔细的读者,应该能很快看出来什么问题导致的。粗心大意的我,搞了大半天才发现是依赖的问题。应该导入与springboot整合的thymeleaf依赖。正确的依赖如下:说明: 1、Thymeleaf模版默认会使用templates作为视图文件夹,默认以/templates作为前缀,原创 2020-06-15 16:24:20 · 45553 阅读 · 1 评论 -
springboot项目中dubbo应用启动报错
主要报错信息:Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.com.alibaba.dubbo.remoting.RemotingException: Failed to bind NettyServer on /192.168.65.1:20880, cause: Failed to bind to: /0.0.0.0:20原创 2020-06-15 15:53:26 · 32924 阅读 · 1 评论