当前位置:   article > 正文

项目启东异常Failed to read candidate component class_logback: no context given for c.q.l.core.rolling.s

logback: no context given for c.q.l.core.rolling.sizeandtimebasedrollingpoli

项目启动时报错

  1. . ____ _ __ _ _
  2. /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
  3. ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
  4. \\/ ___)| |_)| | | | | || (_| | ) ) ) )
  5. ' |____| .__|_| |_|_| |_\__, | / / / /
  6. =========|_|==============|___/=/_/_/_/
  7. :: Spring Boot :: (v2.2.0.RELEASE)
  8. 2021-12-17 11:19:27.140 INFO 5506 --- [ main] c.t.a.s.m.ManagementApplication : Starting ManagementApplication vhtc-2.0.0 on acs2 with PID 5506 (/home/sacs/tendyron/management/management-starter-htc-2.0.0.jar started by sacs in /home/sacs/tendyron/management)
  9. 2021-12-17 11:19:27.151 INFO 5506 --- [ main] c.t.a.s.m.ManagementApplication : The following profiles are active: test
  10. 2021-12-17 11:19:29.257 WARN 5506 --- [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to read candidate component class: URL [jar:file:/home/sacs/tendyron/management/management-starter-htc-2.0.0.jar!/BOOT-INF/classes!/com/tdr/acs/skycity/management/controller/client/ClientController.class]; nested exception is java.lang.IllegalStateException: Failed to introspect Class [com.tdr.acs.standard.core.gate.service.config.MybatisPlusConfig] from ClassLoader [org.springframework.boot.loader.LaunchedURLClassLoader@49c2faae]
  11. 2021-12-17 11:19:29.271 INFO 5506 --- [ main] ConditionEvaluationReportLoggingListener :
  12. Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
  13. 2021-12-17 11:19:29.280 ERROR 5506 --- [ main] o.s.boot.SpringApplication : Application run failed
  14. org.springframework.beans.factory.BeanDefinitionStoreException: Failed to read candidate component class: URL [jar:file:/home/sacs/tendyron/management/management-starter-htc-2.0.0.jar!/BOOT-INF/classes!/com/tdr/acs/skycity/management/controller/client/ClientController.class]; nested exception is java.lang.IllegalStateException: Failed to introspect Class [com.tdr.acs.standard.core.gate.service.config.MybatisPlusConfig] from ClassLoader [org.springframework.boot.loader.LaunchedURLClassLoader@49c2faae]
  15. at org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider.scanCandidateComponents(ClassPathScanningCandidateComponentProvider.java:454) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  16. at org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider.findCandidateComponents(ClassPathScanningCandidateComponentProvider.java:316) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  17. at org.springframework.boot.context.properties.ConfigurationPropertiesScanRegistrar.scan(ConfigurationPropertiesScanRegistrar.java:83) ~[spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  18. at org.springframework.boot.context.properties.ConfigurationPropertiesScanRegistrar.registerBeanDefinitions(ConfigurationPropertiesScanRegistrar.java:60) ~[spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  19. at org.springframework.context.annotation.ImportBeanDefinitionRegistrar.registerBeanDefinitions(ImportBeanDefinitionRegistrar.java:86) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  20. at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.lambda$loadBeanDefinitionsFromRegistrars$1(ConfigurationClassBeanDefinitionReader.java:385) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  21. at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader$$Lambda$227/1368594774.accept(Unknown Source) ~[na:na]
  22. at java.util.LinkedHashMap.forEach(LinkedHashMap.java:676) ~[na:1.8.0_45]
  23. at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsFromRegistrars(ConfigurationClassBeanDefinitionReader.java:384) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  24. at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForConfigurationClass(ConfigurationClassBeanDefinitionReader.java:148) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  25. at org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitions(ConfigurationClassBeanDefinitionReader.java:120) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  26. at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:337) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  27. at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:242) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  28. at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  29. at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  30. at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:706) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  31. at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:532) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  32. at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141) ~[spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  33. at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747) [spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  34. at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397) [spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  35. at org.springframework.boot.SpringApplication.run(SpringApplication.java:315) [spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  36. at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226) [spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  37. at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215) [spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  38. at com.tdr.acs.skycity.management.ManagementApplication.main(ManagementApplication.java:33) [classes!/:htc-2.0.0]
  39. at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_45]
  40. at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_45]
  41. at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_45]
  42. at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_45]
  43. at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [management-starter-htc-2.0.0.jar:htc-2.0.0]
  44. at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [management-starter-htc-2.0.0.jar:htc-2.0.0]
  45. at org.springframework.boot.loader.Launcher.launch(Launcher.java:51) [management-starter-htc-2.0.0.jar:htc-2.0.0]
  46. at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52) [management-starter-htc-2.0.0.jar:htc-2.0.0]
  47. Caused by: java.lang.IllegalStateException: Failed to introspect Class [com.tdr.acs.standard.core.gate.service.config.MybatisPlusConfig] from ClassLoader [org.springframework.boot.loader.LaunchedURLClassLoader@49c2faae]
  48. at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:477) ~[spring-core-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  49. at org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:355) ~[spring-core-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  50. at org.springframework.util.ReflectionUtils.getUniqueDeclaredMethods(ReflectionUtils.java:411) ~[spring-core-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  51. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.lambda$getTypeForFactoryMethod$2(AbstractAutowireCapableBeanFactory.java:743) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  52. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$$Lambda$235/592959754.apply(Unknown Source) ~[na:na]
  53. at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660) ~[na:1.8.0_45]
  54. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryMethod(AbstractAutowireCapableBeanFactory.java:742) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  55. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineTargetType(AbstractAutowireCapableBeanFactory.java:681) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  56. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:649) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  57. at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1605) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  58. at org.springframework.beans.factory.support.DefaultListableBeanFactory.doGetBeanNamesForType(DefaultListableBeanFactory.java:520) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  59. at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType(DefaultListableBeanFactory.java:491) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  60. at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:613) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  61. at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:605) ~[spring-beans-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  62. at org.springframework.boot.context.TypeExcludeFilter.getDelegates(TypeExcludeFilter.java:77) ~[spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  63. at org.springframework.boot.context.TypeExcludeFilter.match(TypeExcludeFilter.java:65) ~[spring-boot-2.2.0.RELEASE.jar!/:2.2.0.RELEASE]
  64. at org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider.isCandidateComponent(ClassPathScanningCandidateComponentProvider.java:492) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  65. at org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider.scanCandidateComponents(ClassPathScanningCandidateComponentProvider.java:431) ~[spring-context-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  66. ... 31 common frames omitted
  67. Caused by: java.lang.NoClassDefFoundError: com/baomidou/mybatisplus/extension/plugins/PaginationInterceptor
  68. at java.lang.Class.getDeclaredMethods0(Native Method) ~[na:1.8.0_45]
  69. at java.lang.Class.privateGetDeclaredMethods(Class.java:2701) ~[na:1.8.0_45]
  70. at java.lang.Class.getDeclaredMethods(Class.java:1975) ~[na:1.8.0_45]
  71. at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:459) ~[spring-core-5.2.0.RELEASE.jar!/:5.2.0.RELEASE]
  72. ... 48 common frames omitted
  73. Caused by: java.lang.ClassNotFoundException: com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor
  74. at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[na:1.8.0_45]
  75. at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[na:1.8.0_45]
  76. at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:92) ~[management-starter-htc-2.0.0.jar:htc-2.0.0]
  77. at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[na:1.8.0_45]
  78. ... 52 common frames omitted
  79. LOGBACK: No context given for c.q.l.core.rolling.SizeAndTimeBasedRollingPolicy@998351292

在网上找都说是springboot和jdk版本不对应,我弄了半天也没弄出来

后来把mybatisplus的版本改了就好了

  1. <dependency>
  2. <groupId>com.baomidou</groupId>
  3. <artifactId>mybatis-plus-core</artifactId>
  4. <version>3.4.1</version>
  5. <scope>compile</scope>
  6. </dependency>
  7. <dependency>
  8. <groupId>com.baomidou</groupId>
  9. <artifactId>mybatis-plus-extension</artifactId>
  10. <version>3.4.1</version>
  11. <scope>compile</scope>
  12. </dependency>

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/我家自动化/article/detail/595090
推荐阅读
相关标签
  

闽ICP备14008679号