Start swagger in the springboot project. If the following error is reported, two solutions can be adopted:
org.springframework.context.ApplicationContextException: Failed to start bean ‘documentationPluginsBootstrapper’; nested exception is java.lang.NullPointerException
This error is caused by the mismatch between SpringBoot version and Swagger version, the blogger Swagger and Swagger-UI are using Springfox 2.9.2, SpringBoot is automatically provided in Idea when created 2.6.2, Springfox uses path matching based on AntPathMatcher, while Spring Boot 2.6.X uses PathPatternMatcher, the two solutions are as follows:
1. Modify the version of springboot to use the earlier version to solve this problem;
2. Add configuration to YML configuration file: ant_path_matcherspring: mvc: pathmatch: matching-strategy: ant_path_matcher.
Read More:
- [Solved] integrated swagger Start Error: Failed to start bean ‘documentationPluginsBootstrapper‘;
- SpringBoot High Version Import Swagger 2.9.2 Error: ApplicationContextException: Failed to start bean ‘documentationPluginsBootstrapper‘
- [Solved] swagger3 Error: org.springframework.context.ApplicationContextException: Failed to start bean ‘documentationPluginsBootstrapper’; nested exception is java.lang.NullPointerException
- [Solved] SpringBoot Integrates Swagge Error: Failed to start bean ‘documentationPluginsBootstrapper‘
- How to Solve Internal Server Error: /swagger/v1/swagger.json
- [Solved] swagger Error: Fetch errorInternal Server Error /swagger/v1/swagger.jso
- Tomcat startup error: Failed to start component [StandardServer[8005]] solution
- [Solved] .NetCore2.2 Upgrade to 3.1 Error: HTTP Error 500.37 – ANCM Failed to Start Within Startup Time
- [Solved] UNABLE TO START SERVLETWEBSERVERAPPLICATIONCONTEXT DUE TO MISSING SERVLETWEBSERVERFACTORY BEAN
- [Solved] Springboot Startup Error: Consider defining a bean of type ‘XXX’ in your configuration.
- [Solved] Springboot project Create to start Error: APPLICATION FAILED TO START
- [Solved] SpringBoot Project Start Error: No bean named ‘org.springframework.context.xxxxx.importRegistry‘ available
- [Solved] renren-fast Startup Error: Error creating bean with name ‘scheduleJobController‘
- [Solved] nacos Startup Error: Error creating bean with name ‘authFilterRegistration‘ defined in class path resource
- AOP Error Cannot resolve reference to bean ‘txPointCut‘ while setting bean property ‘po
- nacos Start Error: Error creating bean with name ‘grpcClusterServer’
- [Solved] Error getting bean using springboot: no qualifying bean of type ‘xxx’ available
- Swagger-ui.html Open Error: There was an unexpected error (type=Not Found, status=404)
- [Solved] Mycat Startup Error: ERROR Startup failed: Timed out waiting for a signal from the JVM
- SpringBoot startup error Failed to determine a suitable driver class