java - Cannot use transaction manager - autowiring ends with exception -


i never ever thought had huge problems spring configuration, cannot project work @transactional annotations @ (i'm using jpa). each time getting no qualifying bean of type in entities @transactional annotation used. application context:

<?xml version="1.0" encoding="utf-8"?> <beans xmlns="http://www.springframework.org/schema/beans"        xmlns:xsi="http://www.w3.org/2001/xmlschema-instance"        xmlns:context="http://www.springframework.org/schema/context"        xmlns:tx="http://www.springframework.org/schema/tx"        xmlns:jpa="http://www.springframework.org/schema/data/jpa"        xsi:schemalocation="http://www.springframework.org/schema/beans         http://www.springframework.org/schema/beans/spring-beans.xsd         http://www.springframework.org/schema/context         http://www.springframework.org/schema/context/spring-context-3.1.xsd         http://www.springframework.org/schema/tx         http://www.springframework.org/schema/tx/spring-tx-3.1.xsd         http://www.springframework.org/schema/data/jpa         http://www.springframework.org/schema/data/jpa/spring-jpa.xsd">        <!-- can use annotations -->     <context:annotation-config />      <!--&lt;!&ndash; package annotated classes &ndash;&gt;-->     <context:component-scan base-package="a.b.c.d.service" />       <bean id="transactionmanager" class="org.springframework.orm.jpa.jpatransactionmanager">         <property name="entitymanagerfactory" ref="entitymanagerfactory" />     </bean>      <!-- manage transactions annotations -->     <tx:annotation-driven transaction-manager="transactionmanager"/>      <!--&lt;!&ndash; data source our database &ndash;&gt;-->     <bean id="datasource" class="org.springframework.jdbc.datasource.drivermanagerdatasource">         <property name="driverclassname" value="oracle.jdbc.oracledriver" />         <property name="url" value="jdbc:oracle:thin:@//oracle11:1521/deviso" />         <property name="username" value="aaa" />         <property name="password" value="xxx" />     </bean>      <bean id="entitymanagerfactory" class="org.springframework.orm.jpa.localcontainerentitymanagerfactorybean">         <property name="persistenceunitname" value="mypersistenceunit"/>         <property name="packagestoscan" value="a.b.c.d.domain" />         <property name="datasource" ref="datasource"/>         <property name="jpavendoradapter">             <bean class="org.springframework.orm.jpa.vendor.hibernatejpavendoradapter">                 <property name="showsql" value="false"/>                 <property name="generateddl" value="true"/>                 <property name="databaseplatform" value="org.hibernate.dialect.oracle10gdialect"/>             </bean>         </property>      </bean>      <jpa:repositories base-package="a.b.c.d.repository"                       entity-manager-factory-ref="entitymanagerfactory">     <!--transaction-manager-ref="transactionmanager">-->      </jpa:repositories>  </beans> 

can please give advice what's wrong settings?

edit: stacktrace:

2015-07-13 19:31:38,230 error [org.jboss.as.webservices.invocation.invocationhandlerjaxws] (default task-3) jbas015594: method invocation failed exception: org.springframework.beans.factory.beancreationexception: injection of autowired dependencies failed class [class a.b.c.d.ws.xmlproviderendpointimpl$$$view1]; nested exception org.springframework.beans.factory.beancreationexception: not autowire field: private a.b.c.d.service.xmlprofileservice a.b.c.d.ws.xmlproviderendpointimpl.profileservice; nested exception org.springframework.beans.factory.nosuchbeandefinitionexception: no qualifying bean of type [a.b.c.d.service.xmlprofileservice] found dependency: expected @ least 1 bean qualifies autowire candidate dependency. dependency annotations: {@org.springframework.beans.factory.annotation.autowired(required=true)}: java.lang.runtimeexception: org.springframework.beans.factory.beancreationexception: injection of autowired dependencies failed class [class a.b.c.d.ws.xmlproviderendpointimpl$$$view1]; nested exception org.springframework.beans.factory.beancreationexception: not autowire field: private a.b.c.d.service.xmlprofileservice a.b.c.d.ws.xmlproviderendpointimpl.profileservice; nested exception org.springframework.beans.factory.nosuchbeandefinitionexception: no qualifying bean of type [a.b.c.d.service.xmlprofileservice] found dependency: expected @ least 1 bean qualifies autowire candidate dependency. dependency annotations: {@org.springframework.beans.factory.annotation.autowired(required=true)}     @ org.jboss.as.webservices.invocation.abstractinvocationhandler.getcomponentview(abstractinvocationhandler.java:85)     @ org.jboss.as.webservices.invocation.abstractinvocationhandler.invoke(abstractinvocationhandler.java:117)     @ org.jboss.wsf.stack.cxf.jbosswsinvoker.performinvocation(jbosswsinvoker.java:175)     @ org.apache.cxf.service.invoker.abstractinvoker.invoke(abstractinvoker.java:104)     @ org.apache.cxf.jaxws.abstractjaxwsmethodinvoker.invoke(abstractjaxwsmethodinvoker.java:237)     @ org.apache.cxf.jaxws.jaxwsmethodinvoker.invoke(jaxwsmethodinvoker.java:69)     @ org.jboss.wsf.stack.cxf.jbosswsinvoker.invoke(jbosswsinvoker.java:146)     @ org.apache.cxf.interceptor.serviceinvokerinterceptor$1.run(serviceinvokerinterceptor.java:58)     @ java.util.concurrent.executors$runnableadapter.call(executors.java:471) [rt.jar:1.7.0_71]     @ java.util.concurrent.futuretask.run(futuretask.java:262) [rt.jar:1.7.0_71]     @ org.apache.cxf.workqueue.synchronousexecutor.execute(synchronousexecutor.java:37)     @ org.apache.cxf.interceptor.serviceinvokerinterceptor.handlemessage(serviceinvokerinterceptor.java:107)     @ org.apache.cxf.phase.phaseinterceptorchain.dointercept(phaseinterceptorchain.java:272)     @ org.apache.cxf.transport.chaininitiationobserver.onmessage(chaininitiationobserver.java:121)     @ org.apache.cxf.transport.http.abstracthttpdestination.invoke(abstracthttpdestination.java:241)     @ org.jboss.wsf.stack.cxf.requesthandlerimpl.handlehttprequest(requesthandlerimpl.java:97)     @ org.jboss.wsf.stack.cxf.transport.servlethelper.callrequesthandler(servlethelper.java:131)     @ org.jboss.wsf.stack.cxf.cxfservletext.invoke(cxfservletext.java:88)     @ org.apache.cxf.transport.servlet.abstracthttpservlet.handlerequest(abstracthttpservlet.java:286)     @ org.apache.cxf.transport.servlet.abstracthttpservlet.dopost(abstracthttpservlet.java:206)     @ javax.servlet.http.httpservlet.service(httpservlet.java:707) [jboss-servlet-api_3.1_spec-1.0.0.final.jar:1.0.0.final]     @ org.jboss.wsf.stack.cxf.cxfservletext.service(cxfservletext.java:136)     @ org.jboss.wsf.spi.deployment.wsfservlet.service(wsfservlet.java:140) [jbossws-spi-2.3.1.final.jar:2.3.1.final]     @ javax.servlet.http.httpservlet.service(httpservlet.java:790) [jboss-servlet-api_3.1_spec-1.0.0.final.jar:1.0.0.final]     @ io.undertow.servlet.handlers.servlethandler.handlerequest(servlethandler.java:85) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.security.servletsecurityrolehandler.handlerequest(servletsecurityrolehandler.java:61) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.servletdispatchinghandler.handlerequest(servletdispatchinghandler.java:36) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ org.wildfly.extension.undertow.security.securitycontextassociationhandler.handlerequest(securitycontextassociationhandler.java:78)     @ io.undertow.server.handlers.predicatehandler.handlerequest(predicatehandler.java:43) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.security.sslinformationassociationhandler.handlerequest(sslinformationassociationhandler.java:131) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.security.servletauthenticationcallhandler.handlerequest(servletauthenticationcallhandler.java:56) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.server.handlers.predicatehandler.handlerequest(predicatehandler.java:43) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.security.handlers.abstractconfidentialityhandler.handlerequest(abstractconfidentialityhandler.java:45) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.security.servletconfidentialityconstrainthandler.handlerequest(servletconfidentialityconstrainthandler.java:63) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.security.handlers.authenticationmechanismshandler.handlerequest(authenticationmechanismshandler.java:58) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.security.cachedauthenticatedsessionhandler.handlerequest(cachedauthenticatedsessionhandler.java:70) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.security.handlers.securityinitialhandler.handlerequest(securityinitialhandler.java:76) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.server.handlers.predicatehandler.handlerequest(predicatehandler.java:43) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ org.wildfly.extension.undertow.security.jacc.jacccontextidhandler.handlerequest(jacccontextidhandler.java:61)     @ io.undertow.server.handlers.predicatehandler.handlerequest(predicatehandler.java:43) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.server.handlers.predicatehandler.handlerequest(predicatehandler.java:43) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.servletinitialhandler.handlefirstrequest(servletinitialhandler.java:261) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.servletinitialhandler.dispatchrequest(servletinitialhandler.java:247) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.servletinitialhandler.access$000(servletinitialhandler.java:76) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.servlet.handlers.servletinitialhandler$1.handlerequest(servletinitialhandler.java:166) [undertow-servlet-1.1.0.final.jar:1.1.0.final]     @ io.undertow.server.connectors.executeroothandler(connectors.java:197) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ io.undertow.server.httpserverexchange$1.run(httpserverexchange.java:759) [undertow-core-1.1.0.final.jar:1.1.0.final]     @ java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor.java:1145) [rt.jar:1.7.0_71]     @ java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor.java:615) [rt.jar:1.7.0_71]     @ java.lang.thread.run(thread.java:745) [rt.jar:1.7.0_71] caused by: org.springframework.beans.factory.beancreationexception: injection of autowired dependencies failed class [class a.b.c.d.ws.xmlproviderendpointimpl$$$view1]; nested exception org.springframework.beans.factory.beancreationexception: not autowire field: private a.b.c.d.service.xmlprofileservice a.b.c.d.ws.xmlproviderendpointimpl.profileservice; nested exception org.springframework.beans.factory.nosuchbeandefinitionexception: no qualifying bean of type [a.b.c.d.service.xmlprofileservice] found dependency: expected @ least 1 bean qualifies autowire candidate dependency. dependency annotations: {@org.springframework.beans.factory.annotation.autowired(required=true)}     @ org.springframework.beans.factory.annotation.autowiredannotationbeanpostprocessor.processinjection(autowiredannotationbeanpostprocessor.java:319) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.web.context.support.springbeanautowiringsupport.processinjectionbasedoncurrentcontext(springbeanautowiringsupport.java:85) [spring-web-4.0.5.release.jar:4.0.5.release]     @ org.springframework.web.context.support.springbeanautowiringsupport.<init>(springbeanautowiringsupport.java:68) [spring-web-4.0.5.release.jar:4.0.5.release]     @ a.b.c.d.ws.xmlproviderendpointimpl.<init>(xmlproviderendpointimpl.java:25) [classes:]     @ a.b.c.d.ws.xmlproviderendpointimpl$$$view1.<init>(unknown source) [classes:]     @ sun.reflect.nativeconstructoraccessorimpl.newinstance0(native method) [rt.jar:1.7.0_71]     @ sun.reflect.nativeconstructoraccessorimpl.newinstance(nativeconstructoraccessorimpl.java:57) [rt.jar:1.7.0_71]     @ sun.reflect.delegatingconstructoraccessorimpl.newinstance(delegatingconstructoraccessorimpl.java:45) [rt.jar:1.7.0_71]     @ java.lang.reflect.constructor.newinstance(constructor.java:526) [rt.jar:1.7.0_71]     @ java.lang.class.newinstance(class.java:379) [rt.jar:1.7.0_71]     @ org.jboss.invocation.proxy.abstractclassfactory.newinstance(abstractclassfactory.java:225)     @ org.jboss.invocation.proxy.proxyfactory.newinstance(proxyfactory.java:270)     @ org.jboss.as.ee.component.viewservice$defaultviewinstancefactory.createviewinstance(viewservice.java:271)     @ org.jboss.as.ee.component.viewservice$view.createinstance(viewservice.java:177)     @ org.jboss.as.ee.component.viewservice$view.createinstance(viewservice.java:173)     @ org.jboss.as.webservices.invocation.abstractinvocationhandler.getcomponentview(abstractinvocationhandler.java:83)     ... 49 more caused by: org.springframework.beans.factory.beancreationexception: not autowire field: private a.b.c.d.service.xmlprofileservice a.b.c.d.ws.xmlproviderendpointimpl.profileservice; nested exception org.springframework.beans.factory.nosuchbeandefinitionexception: no qualifying bean of type [a.b.c.d.service.xmlprofileservice] found dependency: expected @ least 1 bean qualifies autowire candidate dependency. dependency annotations: {@org.springframework.beans.factory.annotation.autowired(required=true)}     @ org.springframework.beans.factory.annotation.autowiredannotationbeanpostprocessor$autowiredfieldelement.inject(autowiredannotationbeanpostprocessor.java:522) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.beans.factory.annotation.injectionmetadata.inject(injectionmetadata.java:88) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.beans.factory.annotation.autowiredannotationbeanpostprocessor.processinjection(autowiredannotationbeanpostprocessor.java:316) [spring-beans-4.0.9.release.jar:4.0.9.release]     ... 64 more caused by: org.springframework.beans.factory.nosuchbeandefinitionexception: no qualifying bean of type [a.b.c.d.service.xmlprofileservice] found dependency: expected @ least 1 bean qualifies autowire candidate dependency. dependency annotations: {@org.springframework.beans.factory.annotation.autowired(required=true)}     @ org.springframework.beans.factory.support.defaultlistablebeanfactory.raisenosuchbeandefinitionexception(defaultlistablebeanfactory.java:1118) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.beans.factory.support.defaultlistablebeanfactory.doresolvedependency(defaultlistablebeanfactory.java:967) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.beans.factory.support.defaultlistablebeanfactory.resolvedependency(defaultlistablebeanfactory.java:862) [spring-beans-4.0.9.release.jar:4.0.9.release]     @ org.springframework.beans.factory.annotation.autowiredannotationbeanpostprocessor$autowiredfieldelement.inject(autowiredannotationbeanpostprocessor.java:494) [spring-beans-4.0.9.release.jar:4.0.9.release]     ... 66 more 

the code simple. dtos has no logic, primitive types.

@transactional public void update(string password, xmlproviderprofiledto dto) { } 

when delete transactional annotation, works, assume proxifying transtactional classes.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -