Hi Jokoul,
Yeah I see what you mean, didn't know you context was so complex :)
are you using oSGI?
Ok what you can do it's to use the other integration method with
Spring that I provided thta it's exporting the jEmbedded container
into the Spring context, a layer or just a service:
1) Exporting a service from the jembedded repo to the spring context:
your-spring-context.xml file
<bean id="echoMuleService"
class="org.jsemantic.jembedded.support.spring.exporter.ServiceExporter">
<property name="id" value="echoMuleService"/>
<property name="annotatedClasses">
<list>
<value>org.jsemantic.jembedded.examples.services.mule.EchoMuleService</
value>
</list>
</property>
</bean>
now you can inject this jembedded-service-bean whenever you needed it
as it would be available in the spring-context.
2) Maybe the best option it's to configure the services into a layer
and export it to the spring-context, this way you could apply the
transactionality support at the layer level:
your-spring-context.xml file
<import resource="classpath:META-INF/properties-service/properties-
service.xml"/>
<bean id="servicesLayer"
class="org.jsemantic.jembedded.support.spring.exporter.ServiceLayerExporter">
<property name="exportedLayer" value="${layer.services}"/>
<property name="annotatedClasses">
<list>
<value>${layer.integration}</value>
<value>${layer.business}</value>
<value>${layer.services}</value>
</list>
</property>
</bean>
This way you make available the ServicesLayer to the spring context.
2) Exporting the full jEmbedded container into the spring-context:
your-spring-context.xml file
<bean id="handler"
class="org.jsemantic.jembedded.support.spring.EmbeddedContainerRunner">
<property name="annotatedClasses">
<list>
<value>class1</value>
<value>class2</value>
<value>class3</value>
</list>
</property>
</bean>
then you would have the handler available in the spring-context, maybe
it's not the best approach.
Hope this helps, I think the second option would work and in fact I
will implement it in the case study.
Take care
Adolfo