Spring Boot 1.3.1.RELEASE + IntelliJ Debug mode -
i have built spring data rest app spring boot in memory security, gradle:
dependencies { runtime("mysql:mysql-connector-java") compile("org.springframework.boot:spring-boot-starter") compile("org.springframework.boot:spring-boot-starter-logging") compile("org.springframework.boot:spring-boot-starter-data-rest") compile("org.springframework.boot:spring-boot-starter-data-jpa") compile("org.springframework.boot:spring-boot-starter-security") compile("org.springframework.boot:spring-boot-devtools") compile("org.projectlombok:lombok:1.14.8") compile("com.mysema.querydsl:querydsl-jpa:3.7.0") compile("com.mysema.querydsl:querydsl-apt:3.7.0") compile("org.apache.httpcomponents:httpclient:4.5.1") testcompile("org.springframework.boot:spring-boot-starter-test") }
all works fine except intellij debug mode - when try debug main class:
@configuration @enableautoconfiguration @componentscan public class application { public static void main(string[] args) {springapplication.run(application.class, args);} }
i below exception:
java.lang.nosuchmethoderror: org.springframework.boot.autoconfigure.condition.conditionoutcome.inverse(lorg/springframework/boot/autoconfigure/condition/conditionoutcome;)lorg/springframework/boot/autoconfigure/condition/conditionoutcome; @ org.springframework.boot.autoconfigure.security.oauth2.resource.resourceservertokenservicesconfiguration$notjwttokencondition.getmatchoutcome(resourceservertokenservicesconfiguration.java:369) @ org.springframework.boot.autoconfigure.condition.springbootcondition.matches(springbootcondition.java:45) @ org.springframework.context.annotation.conditionevaluator.shouldskip(conditionevaluator.java:92) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:190) @ org.springframework.context.annotation.configurationclassparser.processmemberclasses(configurationclassparser.java:304) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:235) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:258) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:258) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.processdeferredimportselectors(configurationclassparser.java:389) @ org.springframework.context.annotation.configurationclassparser.parse(configurationclassparser.java:165) @ org.springframework.context.annotation.configurationclasspostprocessor.processconfigbeandefinitions(configurationclasspostprocessor.java:305) @ org.springframework.context.annotation.configurationclasspostprocessor.postprocessbeandefinitionregistry(configurationclasspostprocessor.java:243) @ org.springframework.context.support.postprocessorregistrationdelegate.invokebeandefinitionregistrypostprocessors(postprocessorregistrationdelegate.java:254) @ org.springframework.context.support.postprocessorregistrationdelegate.invokebeanfactorypostprocessors(postprocessorregistrationdelegate.java:94) @ org.springframework.context.support.abstractapplicationcontext.invokebeanfactorypostprocessors(abstractapplicationcontext.java:611) @ org.springframework.context.support.abstractapplicationcontext.refresh(abstractapplicationcontext.java:464) @ org.springframework.boot.context.embedded.embeddedwebapplicationcontext.refresh(embeddedwebapplicationcontext.java:109) @ org.springframework.boot.springapplication.refresh(springapplication.java:691) @ org.springframework.boot.springapplication.run(springapplication.java:320) @ org.springframework.boot.springapplication.run(springapplication.java:952) @ org.springframework.boot.springapplication.run(springapplication.java:941) @ com.xxx.core.application.main(application.java:26) 2016-01-15 21:40:34.007 info 14606 --- [ main] ationconfigembeddedwebapplicationcontext : closing org.springframework.boot.context.embedded.annotationconfigembeddedwebapplicationcontext@5ddf0d24: startup date [fri jan 15 21:40:32 gmt 2016]; root of context hierarchy 2016-01-15 21:40:34.011 warn 14606 --- [ main] ationconfigembeddedwebapplicationcontext : exception thrown applicationlistener handling contextclosedevent java.lang.illegalstateexception: applicationeventmulticaster not initialized - call 'refresh' before multicasting events via context: org.springframework.boot.context.embedded.annotationconfigembeddedwebapplicationcontext@5ddf0d24: startup date [fri jan 15 21:40:32 gmt 2016]; root of context hierarchy @ org.springframework.context.support.abstractapplicationcontext.getapplicationeventmulticaster(abstractapplicationcontext.java:346) @ org.springframework.context.support.abstractapplicationcontext.publishevent(abstractapplicationcontext.java:333) @ org.springframework.context.support.abstractapplicationcontext.doclose(abstractapplicationcontext.java:882) @ org.springframework.boot.context.embedded.embeddedwebapplicationcontext.doclose(embeddedwebapplicationcontext.java:141) @ org.springframework.context.support.abstractapplicationcontext.close(abstractapplicationcontext.java:843) @ org.springframework.boot.springapplication.run(springapplication.java:342) @ org.springframework.boot.springapplication.run(springapplication.java:952) @ org.springframework.boot.springapplication.run(springapplication.java:941) @ com.xxx.core.application.main(application.java:26) 2016-01-15 21:40:34.012 warn 14606 --- [ main] ationconfigembeddedwebapplicationcontext : exception thrown lifecycleprocessor on context close java.lang.illegalstateexception: lifecycleprocessor not initialized - call 'refresh' before invoking lifecycle methods via context: org.springframework.boot.context.embedded.annotationconfigembeddedwebapplicationcontext@5ddf0d24: startup date [fri jan 15 21:40:32 gmt 2016]; root of context hierarchy @ org.springframework.context.support.abstractapplicationcontext.getlifecycleprocessor(abstractapplicationcontext.java:359) @ org.springframework.context.support.abstractapplicationcontext.doclose(abstractapplicationcontext.java:890) @ org.springframework.boot.context.embedded.embeddedwebapplicationcontext.doclose(embeddedwebapplicationcontext.java:141) @ org.springframework.context.support.abstractapplicationcontext.close(abstractapplicationcontext.java:843) @ org.springframework.boot.springapplication.run(springapplication.java:342) @ org.springframework.boot.springapplication.run(springapplication.java:952) @ org.springframework.boot.springapplication.run(springapplication.java:941) @ com.xxx.core.application.main(application.java:26) exception in thread "main" java.lang.nosuchmethoderror: org.springframework.boot.autoconfigure.condition.conditionoutcome.inverse(lorg/springframework/boot/autoconfigure/condition/conditionoutcome;)lorg/springframework/boot/autoconfigure/condition/conditionoutcome; @ org.springframework.boot.autoconfigure.security.oauth2.resource.resourceservertokenservicesconfiguration$notjwttokencondition.getmatchoutcome(resourceservertokenservicesconfiguration.java:369) @ org.springframework.boot.autoconfigure.condition.springbootcondition.matches(springbootcondition.java:45) @ org.springframework.context.annotation.conditionevaluator.shouldskip(conditionevaluator.java:92) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:190) @ org.springframework.context.annotation.configurationclassparser.processmemberclasses(configurationclassparser.java:304) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:235) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:258) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.doprocessconfigurationclass(configurationclassparser.java:258) @ org.springframework.context.annotation.configurationclassparser.processconfigurationclass(configurationclassparser.java:218) @ org.springframework.context.annotation.configurationclassparser.processimports(configurationclassparser.java:435) @ org.springframework.context.annotation.configurationclassparser.processdeferredimportselectors(configurationclassparser.java:389) @ org.springframework.context.annotation.configurationclassparser.parse(configurationclassparser.java:165) @ org.springframework.context.annotation.configurationclasspostprocessor.processconfigbeandefinitions(configurationclasspostprocessor.java:305) @ org.springframework.context.annotation.configurationclasspostprocessor.postprocessbeandefinitionregistry(configurationclasspostprocessor.java:243) @ org.springframework.context.support.postprocessorregistrationdelegate.invokebeandefinitionregistrypostprocessors(postprocessorregistrationdelegate.java:254) @ org.springframework.context.support.postprocessorregistrationdelegate.invokebeanfactorypostprocessors(postprocessorregistrationdelegate.java:94) @ org.springframework.context.support.abstractapplicationcontext.invokebeanfactorypostprocessors(abstractapplicationcontext.java:611) @ org.springframework.context.support.abstractapplicationcontext.refresh(abstractapplicationcontext.java:464) @ org.springframework.boot.context.embedded.embeddedwebapplicationcontext.refresh(embeddedwebapplicationcontext.java:109) @ org.springframework.boot.springapplication.refresh(springapplication.java:691) @ org.springframework.boot.springapplication.run(springapplication.java:320) @ org.springframework.boot.springapplication.run(springapplication.java:952) @ org.springframework.boot.springapplication.run(springapplication.java:941) @ com.xxx.core.application.main(application.java:26)
if switch springbootversion = '1.3.1.release' 1.1.8 example (and remove devtools comes 1.3.1), exception not being thrown , debug works fine.
i tried remove security starter didn't help. maybe have encountered similar behavior? miss here?
Comments
Post a Comment