You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@aries.apache.org by "De Backer Frederik (DBB)" <Fr...@dexia.com> on 2011/11/16 11:28:02 UTC

CXF DOSGI and transactions

Hello,

I have installed the latest single bundle release of CXF DOSGI. I have
played around a bit with it and it works ok to remotely expose a service
(see blueprint definition below). However, when I add a transaction
attribute on the bean definition (in comment below), the service is not
exposed anymore. The purpose is not to do transaction propagation from
client to service but just to start a transaction when the service
method is invoked.

	<service interface="dexia.osgipoc.sedm3.service.BankService"
		ref="bankServiceBean">
		<service-properties>
			<entry key="service.exported.interfaces"
value="*" />
			<entry key="service.exported.configs"
value="org.apache.cxf.ws" />
			<entry key="org.apache.cxf.ws.address"
value="http://localhost:9090/bankservice" />
		</service-properties>
	</service>

	<bean id="bankServiceBean"
class="dexia.osgipoc.sedm3.service.BankServiceImpl"
		activation="lazy">
		<!-- tx:transaction method="*" value="Required" /-->
		<property name="actorService" ref="actorServiceRef" />
		<property name="accountService" ref="accountServiceRef"
/>
	</bean>

In the console log I see (NULL for EndpointDescription):

16-nov-2011 10:41:09
org.apache.cxf.dosgi.topologymanager.TopologyManager$2 run
INFO: TopologyManager: export sucessful Endpoints:[Endpoint Desctiption
for Serv
iceReference
{dexia.osgipoc.sedm3.service.BankService}={osgi.service.blueprint.c
ompname=bankServiceBean,
org.apache.cxf.ws.address=http://localhost:9090/bankser
vice, service.exported.interfaces=*,
service.exported.configs=org.apache.cxf.ws,
 service.id=107}
*** EndpointDescription: ****
---> NULL <----

*** Exception: null ****
*** isClosed : false ****

]

While in the case that it works correctly, I see:

INFO: TopologyManager: export sucessful Endpoints:[Endpoint Desctiption
for Serv
iceReference
{dexia.osgipoc.sedm3.service.BankService}={osgi.service.blueprint.c
ompname=bankServiceBean,
org.apache.cxf.ws.address=http://localhost:9090/bankser
vice, service.exported.interfaces=*,
service.exported.configs=org.apache.cxf.ws,
 service.id=111}
*** EndpointDescription: ****
endpoint.framework.uuid  => c39d5ef1-ca55-4141-9901-d976b0e59ed1
endpoint.id  => http://localhost:9090/bankservice
endpoint.package.version.dexia.osgipoc.sedm3.service  => 0.0.1.SNAPSHOT
endpoint.service.id  => 111
objectClass  => [Ljava.lang.String;@c67f69
org.apache.cxf.ws.address  => http://localhost:9090/bankservice
osgi.service.blueprint.compname  => bankServiceBean
service.imported  => true
service.imported.configs  => [Ljava.lang.String;@1d6e4a4
service.intents  => [Ljava.lang.String;@13ceab3

*** Exception: null ****
*** isClosed : false ****

]

Thx a lot for the support,

Frederik.

-------------------------------------------------------------------------
Dexia disclaimer:

http://www.dexia.com/maildisclaimer.htm
-------------------------------------------------------------------------


RE: CXF DOSGI and transactions

Posted by Timothy Ward <ti...@apache.org>.
Hi,

I'll try to find someone to follow up on this, but you might want to raise this on the CXF list as well. There will be more DOSGi developers there than there are on the Aries lists.

Regards,

Tim Ward
-------------------
Apache Aries PMC member & Enterprise OSGi advocate
Enterprise OSGi in Action (http://www.manning.com/cummins)
-------------------


Subject: CXF DOSGI and transactions
Date: Wed, 16 Nov 2011 11:28:02 +0100
From: Frederik.DeBacker@dexia.com
To: user@aries.apache.org








CXF DOSGI and transactions




Hello,


I have installed the latest single bundle release of CXF DOSGI. I have played around a bit with it and it works ok to remotely expose a service (see blueprint definition below). However, when I add a transaction attribute on the bean definition (in comment below), the service is not exposed anymore. The purpose is not to do transaction propagation from client to service but just to start a transaction when the service method is invoked.

        <service interface="dexia.osgipoc.sedm3.service.BankService"


                ref="bankServiceBean">


                <service-properties>


                        <entry key="service.exported.interfaces" value="*" />


                        <entry key="service.exported.configs" value="org.apache.cxf.ws" />


                        <entry key="org.apache.cxf.ws.address" value="http://localhost:9090/bankservice" />


                </service-properties>


        </service>


        <bean id="bankServiceBean" class="dexia.osgipoc.sedm3.service.BankServiceImpl"


                activation="lazy">


                <!-- tx:transaction method="*" value="Required" /-->


                <property name="actorService" ref="actorServiceRef" />


                <property name="accountService" ref="accountServiceRef" />


        </bean>


In the console log I see (NULL for EndpointDescription):


16-nov-2011 10:41:09 org.apache.cxf.dosgi.topologymanager.TopologyManager$2 run


INFO: TopologyManager: export sucessful Endpoints:[Endpoint Desctiption for Serv


iceReference {dexia.osgipoc.sedm3.service.BankService}={osgi.service.blueprint.c


ompname=bankServiceBean, org.apache.cxf.ws.address=http://localhost:9090/bankser


vice, service.exported.interfaces=*, service.exported.configs=org.apache.cxf.ws,


 service.id=107}


*** EndpointDescription: ****


---> NULL <----


*** Exception: null ****


*** isClosed : false ****


]


While in the case that it works correctly, I see:


INFO: TopologyManager: export sucessful Endpoints:[Endpoint Desctiption for Serv


iceReference {dexia.osgipoc.sedm3.service.BankService}={osgi.service.blueprint.c


ompname=bankServiceBean, org.apache.cxf.ws.address=http://localhost:9090/bankser


vice, service.exported.interfaces=*, service.exported.configs=org.apache.cxf.ws,


 service.id=111}


*** EndpointDescription: ****


endpoint.framework.uuid  => c39d5ef1-ca55-4141-9901-d976b0e59ed1


endpoint.id  => http://localhost:9090/bankservice


endpoint.package.version.dexia.osgipoc.sedm3.service  => 0.0.1.SNAPSHOT


endpoint.service.id  => 111


objectClass  => [Ljava.lang.String;@c67f69


org.apache.cxf.ws.address  => http://localhost:9090/bankservice


osgi.service.blueprint.compname  => bankServiceBean


service.imported  => true


service.imported.configs  => [Ljava.lang.String;@1d6e4a4


service.intents  => [Ljava.lang.String;@13ceab3


*** Exception: null ****


*** isClosed : false ****


]


Thx a lot for the support,


Frederik.


-------------------------------------------------------------------------
Dexia disclaimer:

http://www.dexia.com/maildisclaimer.htm
-------------------------------------------------------------------------