Code:
....
<int:bridge input-channel="orders" output-channel="errorHandlingGatewayChannel">
<int:poller fixed-delay="5000" max-messages-per-poll="1" task-executor="taskExecutor">
<int:transactional propagation="REQUIRES_NEW" transaction-manager="transactionManager"/>
</int:poller>
</int:bridge>
<task:executor id="taskExecutor" pool-size="10"/>
<int:channel id="errorHandlingGatewayChannel"/>
<int:service-activator input-channel="errorHandlingGatewayChannel" ref="errorHandlingGateway"/>
<int:gateway id="errorHandlingGateway"
error-channel="ordersError"
default-reply-timeout="0"
default-request-channel="ordersForInvoicing"
service-interface="si.services.TransactionGateway"
/>
<int:channel id="ordersForInvoicing"/>
<int:service-activator input-channel="ordersForInvoicing" ref="orderInvoiceService" method="invoice"
output-channel="ordersFinished"/>
<int:channel id="ordersError"/>
Code:
java.lang.IllegalStateException: Failed to load ApplicationContext
at org.springframework.test.context.TestContext.getApplicationContext(TestContext.java:308)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.injectDependencies(DependencyInjectionTestExecutionListener.java:109)
at org.springframework.test.context.support.DependencyInjectionTestExecutionListener.prepareTestInstance(DependencyInjectionTestExecutionListener.java:75)
at org.springframework.test.context.TestContextManager.prepareTestInstance(TestContextManager.java:321)
....###TRACE Shortened so I can post###
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.integration.config.ConsumerEndpointFactoryBean#3': Cannot resolve reference to bean 'org.springframework.integration.config.ServiceActivatorFactoryBean#0' while setting bean property 'handler'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.integration.config.ServiceActivatorFactoryBean#0': FactoryBean threw exception on object creation; nested exception is java.lang.IllegalArgumentException: Found ambiguous parameter type [interface java.util.List] for method match: [public final boolean $Proxy13.isInterfaceProxied(java.lang.Class), public final void $Proxy13.removeAdvisor(int) throws org.springframework.aop.framework.AopConfigException, public final void $Proxy13.setExposeProxy(boolean), public final int $Proxy13.indexOf(org.aopalliance.aop.Advice), public final java.lang.Object $Proxy13.doInTransaction(java.lang.Object), public final int $Proxy13.indexOf(org.springframework.aop.Advisor), public final java.lang.String $Proxy13.toProxyConfigString(), public final void $Proxy13.setTargetSource(org.springframework.aop.TargetSource)]
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)
....###TRACE Shortened so I can post###
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:563)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:84)
at org.springframework.test.context.support.AbstractGenericContextLoader.loadContext(AbstractGenericContextLoader.java:1)
at org.springframework.test.context.TestContext.loadApplicationContext(TestContext.java:280)
at org.springframework.test.context.TestContext.getApplicationContext(TestContext.java:304)
... 27 more
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.integration.config.ServiceActivatorFactoryBean#0': FactoryBean threw exception on object creation; nested exception is java.lang.IllegalArgumentException: Found ambiguous parameter type [interface java.util.List] for method match: [public final boolean $Proxy13.isInterfaceProxied(java.lang.Class), public final void $Proxy13.removeAdvisor(int) throws org.springframework.aop.framework.AopConfigException, public final void $Proxy13.setExposeProxy(boolean), public final int $Proxy13.indexOf(org.aopalliance.aop.Advice), public final java.lang.Object $Proxy13.doInTransaction(java.lang.Object), public final int $Proxy13.indexOf(org.springframework.aop.Advisor), public final java.lang.String $Proxy13.toProxyConfigString(), public final void $Proxy13.setTargetSource(org.springframework.aop.TargetSource)]
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:149)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:102)
....###TRACE Shortened so I can post###
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:322)
... 43 more
Caused by: java.lang.IllegalArgumentException: Found ambiguous parameter type [interface java.util.List] for method match: [public final boolean $Proxy13.isInterfaceProxied(java.lang.Class), public final void $Proxy13.removeAdvisor(int) throws org.springframework.aop.framework.AopConfigException, public final void $Proxy13.setExposeProxy(boolean), public final int $Proxy13.indexOf(org.aopalliance.aop.Advice), public final java.lang.Object $Proxy13.doInTransaction(java.lang.Object), public final int $Proxy13.indexOf(org.springframework.aop.Advisor), public final java.lang.String $Proxy13.toProxyConfigString(), public final void $Proxy13.setTargetSource(org.springframework.aop.TargetSource)]
at org.springframework.util.Assert.isNull(Assert.java:89)
at org.springframework.integration.util.MessagingMethodInvokerHelper.findHandlerMethodsForTarget(MessagingMethodInvokerHelper.java:352)
at org.springframework.integration.util.MessagingMethodInvokerHelper.<init>(MessagingMethodInvokerHelper.java:167)
....###TRACE Shortened so I can post###
at org.springframework.integration.handler.MethodInvokingMessageProcessor.<init>(MethodInvokingMessageProcessor.java:56)
at org.springframework.integration.handler.ServiceActivatingHandler.<init>(ServiceActivatingHandler.java:34)
at org.springframework.integration.config.ServiceActivatorFactoryBean.createMethodInvokingHandler(ServiceActivatorFactoryBean.java:48)
at org.springframework.integration.config.AbstractStandardMessageHandlerFactoryBean.createHandler(AbstractStandardMessageHandlerFactoryBean.java:72)
at org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean.createHandlerInternal(AbstractSimpleMessageHandlerFactoryBean.java:89)
at org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean.getObject(AbstractSimpleMessageHandlerFactoryBean.java:68)
at org.springframework.integration.config.AbstractSimpleMessageHandlerFactoryBean.getObject(AbstractSimpleMessageHandlerFactoryBean.java:31)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:142)
... 48 more