The error reporting information is as follows:
Error creating bean with name
'com.github.pagehelper.autoconfigure.PageHelperAutoConfiguration'
Description:
The dependencies of some of the beans in the application context form a cycle:
┌──->──┐
| com.github.pagehelper.autoconfigure.PageHelperAutoConfiguration
└──<-──┘
└──<-──┘
The spring boot version is 2.6.1
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.6.1</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
The page helper version is 1.2.3
<!-- pageHelper -->
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.2.3</version>
</dependency>
After verification by many parties, it is found that the error is due to the conflict between the springboot version and the PageHelper version.
Solution:
-
- reduce the springboot version, such as 2.5 3 (the PageHelper version remains unchanged from 1.2.3)
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.5.3</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
Increase the version of PageHelper, such as 1.4 1 (the springboot version remains unchanged from 2.6.1)
<!-- pageHelper -->
<dependency>
<groupId>com.github.pagehelper</groupId>
<artifactId>pagehelper-spring-boot-starter</artifactId>
<version>1.4.1</version>
</dependency>
I hope my solution will help you a little. Good luck!!!
Read More:
- [Solved] ‘build.plugins.plugin.version‘ for org.springframework.boot:spring-boot-maven-plugin is missing.
- Spring integrated HBase error [How to Solve]
- [Solved] IDEA Import springboot Project Error: Cannot resolve plugin org.springframework.boot:spring-boot-maven-plugin:<unknown>
- Spring boot real time HTML page
- [Solved] Spring Boot Error: org.springframework.jdbc.datasource.embedded.EmbeddedData
- Spring-boot-maven-plugin Error [How to Solve]
- Eclipse relies on spring boot configuration processor, and there is no prompt for writing properties and YML
- [Solved] Spring Boot Package Error: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0
- Spring Boot Error starting ApplicationContext. To display the auto-configuration report re-run you
- [Solved] spring boot Startup Error: Error creating bean with name ‘requestMappingHandlerMapping‘ defined in class path
- How to Solve Spring Boot Maven Build Error
- [Solved] Spring Boot Project Error: Failed to load property source from
- [Solved] Spring Boot Startup Error: Failed to load property source from location ‘classpath:/application-dev.yml‘
- [Solved] Mybatis integrates PageHelper and uses sqlserver paging error
- Split log by date in log4j2 of spring boot
- [Solved] Spring boot Run Error: o.s.b.d.LoggingFailureAnalysisReporter ERROR;
- [Solved] error running ‘xx‘ Command line is too long shorten command line for xx or also for Spring Boot defa
- spring cloud 2020 gateway Error 503 [How to Solve]
- Spring boot uses thread pool to realize asynchronous processing without return and asynchronous processing with return
- How to Solve Spring integrate Seata startup error