1. Error prompt
java.lang.NoSuchMethodError: javax.servlet.http.HttpServletRequest.getHttpServletMapping()Ljavax/servlet/http/HttpServletMapping;
2. The reason is that the Tomcat version is incompatible with springboot
I use
<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.3.10.RELEASE</version> </parent>
2. The solution is to modify the below codes in pom.xml
<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.3.10.RELEASE</version> </parent>
to:
<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.0.5.RELEASE</version> </parent>
Problem-solving
Read More:
- Springboot Project Error: Failed to execute goal org.apache.maven.plugins
- [Solved] SpringBoot Pack Project: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources
- [Solved] Project Startup Error: Redis health check failed:Unable to connect to localhost6379
- [Solved] Project Startup Error: Redis health check failed: Unable to connect to localhost6379
- Springboot Project: How to Introduces Local Jar Package
- [Solved] Springboot Project Error: Mail server connection failed;
- [Solved] Springboot Project Startup Error: Unable to Identify bootstrap.yml Configuration
- [ERROR] Failed to execute goal on project simple-project: Could not resolve dependencies for project
- [Solved] Springboot project introduces Font library error: java.awt.fontformatexception: bad table, tag = XXXXXX
- [Solved] Springboot integrate swagger error: Failed to start bean ‘documentationPluginsBootstrapper‘
- Springboot integrates Redis annotation and access error: java.io.NotSerializableException: com.demo.entity.MemberEntity
- [Solved] Springboot upload failed to find the temporary directory error
- Springboot Integrate Swagger2 Error: Failed to start bean ‘documentationPluginsBootstrapper‘;
- Springboot WARNING: An illegal reflective access operation has occurred
- Springboot uses Oracle database to report property ‘sqlsessionfactory’ or ‘sqlsessiontemplate’ are required
- NULL value exception occurs when freemarker renders the page globally in the springboot project
- [Solved] Springboot Project Start Error: An attempt was made to call the method com.google.common.collect.Multimaps.asMap
- [Solved] springboot Project Run Error: HikariPool-1 – Exception during pool initialization.
- [Solved] IDEA Import springboot Project Error: Cannot resolve plugin org.springframework.boot:spring-boot-maven-plugin:<unknown>
- [Solved] Springboot Error: swagger-UI/index.html Access Error 404