SCA and OSGi Applications

You can use OSGi applications as component implementations in Service Component Architecture (SCA) composite applications. You can use SCA to link between OSGi applications, and between an OSGi application and another component type such as a Java™ EE application, a Java Message Service (JMS) resource, or a web service.

Defining OSGi applications as SCA components

The SCA programming model supports the use of OSGi applications as SCA component implementations. You can expose an OSGi application as an SCA service by writing code that defines the application as an SCA component and enables the application to participate in an SCA composite. For more information, see Using OSGi applications as SCA component implementations.

OSGi Applications and the SCA interaction intent model for transactions

You can declare transaction policy at the services level to describe the transactional contract that the service provider offers to the consumer, following the SCA interaction intents model for transactions. For an OSGi application, you declare the interaction intents for services in a module Blueprint file. The interaction intent is associated with a service entry in the standard OSGi manner: by recording the intent as a service property in the service registry. For more information, see Transactions and OSGi Applications.

SCA and the configuration domain for an OSGi application

When a service is exported by an application, it is registered in the WebSphere® Application Server global service registry. This registry is available throughout the configuration domain for the application, which means that it is available throughout the OSGi framework instance in which the exporting application is hosted, and throughout the OSGi framework instances of all other OSGi application containers in the same OSGi application configuration domain.

The scope of the configuration domain for an OSGi application depends upon the runtime provider:
  • For WebSphere Application Server Version 7.0, the configuration domain is scoped to cell scope.
  • For an SCA runtime provider, the configuration domain is scoped to the SCA domain.

If an OSGi application imports a service reference, that service must be resolved from the global service registry. To resolve references to services that are outside the configuration domain for the application, you can install proxy services into the global service registry.

Enabling OSGi applications to invoke Enterprise JavaBeans (EJBs) through SCA

An OSGi bundle or a web application bundle (WAB) cannot look up and invoke an EJB directly. However, you can include your OSGi application in an SCA environment, and the SCA modules can be configured to bind to EJB modules.


Icon that indicates the type of topic Concept topic

Terms and conditions for information centers | Feedback


Timestamp icon Last updated: Tuesday, 19 June 2012
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=matt&product=was-nd-mp&topic=ca_sca
File name: ca_sca.html