请稍等 ...
×

采纳答案成功!

向帮助你的同学说点啥吧!感谢那些助人为乐的人

老师,我运行 java -jar emos-workflow.jar --spring.config.location=application.yml报错

:: Spring Boot ::                (v2.4.2)

01:16:42  INFO   Starting EmosWorkflowApplication using Java 1.8.0_261 on DESKTOP-S3K73DK with PID 7680 (E:\springboot\emos-workflow\emos-workflow.jar started by Administrator in E:\springboot\emos-workflow)
01:16:42  INFO   No active profile set, falling back to default profiles: default
01:16:45  WARN   Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.example.emos.workflow.EmosWorkflowApplication]; nested exception is java.lang.IllegalArgumentException: Unresolvable class definition for class [org.activiti.spring.boot.ActivitiProperties]
01:16:45  INFO

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
01:16:46  ERROR  Application run failed
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.example.emos.workflow.EmosWorkflowApplication]; nested exception is java.lang.IllegalArgumentException: Unresolvable class definition for class [org.activiti.spring.boot.ActivitiProperties]
        at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:610)
        at org.springframework.context.annotation.ConfigurationClassParser.access$800(ConfigurationClassParser.java:111)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.lambda$processGroupImports$1(ConfigurationClassParser.java:812)
        at java.util.ArrayList.forEach(ArrayList.java:1259)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.processGroupImports(ConfigurationClassParser.java:809)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorHandler.process(ConfigurationClassParser.java:780)
        at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:193)
        at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:336)
        at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:252)
        at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:285)
        at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:99)
        at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:751)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:569)
        at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:144)
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:767)
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:759)
        at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:426)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:326)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:1311)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:1300)
        at com.example.emos.workflow.EmosWorkflowApplication.main(xb:80)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:107)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:58)
        at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:88)
Caused by: java.lang.IllegalArgumentException: Unresolvable class definition for class [org.activiti.spring.boot.ActivitiProperties]
        at org.springframework.util.ClassUtils.resolveClassName(ClassUtils.java:331)
        at org.springframework.core.annotation.TypeMappedAnnotation.adapt(TypeMappedAnnotation.java:446)
        at org.springframework.core.annotation.TypeMappedAnnotation.getValue(TypeMappedAnnotation.java:369)
        at org.springframework.core.annotation.TypeMappedAnnotation.asMap(TypeMappedAnnotation.java:284)
        at org.springframework.core.annotation.AbstractMergedAnnotation.asAnnotationAttributes(AbstractMergedAnnotation.java:193)
        at org.springframework.core.type.AnnotatedTypeMetadata.getAnnotationAttributes(AnnotatedTypeMetadata.java:106)
        at org.springframework.context.annotation.AnnotationConfigUtils.attributesFor(AnnotationConfigUtils.java:285)
        at org.springframework.context.annotation.AnnotationBeanNameGenerator.determineBeanNameFromAnnotation(AnnotationBeanNameGenerator.java:102)
        at org.springframework.context.annotation.AnnotationBeanNameGenerator.generateBeanName(AnnotationBeanNameGenerator.java:81)
        at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.doScan(ClassPathBeanDefinitionScanner.java:280)
        at org.springframework.context.annotation.ComponentScanAnnotationParser.parse(ComponentScanAnnotationParser.java:132)
        at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:296)
        at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:250)
        at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:600)
        ... 28 common frames omitted
Caused by: java.lang.UnsupportedClassVersionError: org/activiti/spring/boot/ActivitiProperties has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
        at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
        at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:151)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:348)
        at org.springframework.util.ClassUtils.forName(ClassUtils.java:284)
        at org.springframework.util.ClassUtils.resolveClassName(ClassUtils.java:324)
        ... 41 common frames omitted

正在回答 回答被采纳积分+3

1回答

神思者 2021-08-28 10:11:16

应该是你的jdk版本的问题,建议你使用15.0.2版本的jdk

0 回复 有任何疑惑可以回复我~
  • 提问者 慕瓜0421253 #1
    谢谢老师,已经好了
    回复 有任何疑惑可以回复我~ 2021-08-28 15:24:42
  • 慕勒8322402 回复 提问者 慕瓜0421253 #2
    你好,我也遇到同样的问题,请问怎么切换15.0.2版本?我是JAVA_HOME多设置了一个jdk 15.0.2 的,但还是不行?
    回复 有任何疑惑可以回复我~ 2021-09-21 18:25:17
问题已解决,确定采纳
还有疑问,暂不采纳
意见反馈 帮助中心 APP下载
官方微信