...
In a typical enterprise, business functions are implemented using various technologies, business data are is represented in different formats and business applications communicate using heterogeneous protocols. It is almost impossible to converge all applications onto one technology stack such as web services and so it remains difficult and costly to integrate different applications in an enterprise. Some of the challenges that enterprises are faced with are listed below.
- Business applications are tightly-coupled with the IT infrastructure and early design decisions have to be made before real deployment.
- Application developers are forced to learn and understand many technologies beyond the business domain knowledge
- Business logic is polluted and coupled by various technology-specific API calls imposed by the IT infrastructure. It's not easy to write and not easy to change.
SCA separates business services from the concerns related to specific hardware, software and network protocols by providing a unified programming model which allows the SCA runtime to handle these seamlessly. Let's look at a simple business scenario to see how Tuscany SCA can help with enterprise application integration. The scenario here is the BigBank demo from the Tuscany distribution 5. As illustrated below, the application comprises a number of assembled components and ultimately returns a total account balance in response to account inquires. For demonstration purposes, the scenario uses a selection of implementation and binding options.
The use of the SCA programming model allows the BigBank developer to decouple the process of designing and creating the scenario from infrastructure concerns. In the BigBank composite, basic units of business logic are modeled modelled as SCA components , called AccountComponent, StockQuoteComponent etc. Once all and their business logic is implemented. Component references are wired to services. This relationship between component reference and services resolves to runtime proxies when the application is deployed. Where appropriate Tuscany SCA uses dependency injection to introduce proxies into each components reference.
Once all business logic is implemented, appropriate bindings were applied to references and services so that they can collaborate. , appropriate bindings are applied to references and services so that they can collaborate. The XML SCA configuration language, called Service Component Description Language (SCDL), describes is used to describe the loosely coupled enterprise component integration . It allows the developer to;Expose services using a variety of binding technologies and the bindings. Since binding information can be changed without changing the business logic. This allows business logic developers to build components without regard for the specifics of the particular infrastructure or network protocol to be used when the component is deployed, the implementation code is not polluted with protocol handling information and furthermore can be changed during deployment without impacting the application. The following example shows the SCDL for defining the jsonrpc binding type. The binding can be changed to rmi by changing that line to rmi.
Code Block |
---|
<component name="AccountServiceComponent"> <implementation.java class="bigbank.account.AccountServiceImpl" /> <service name="AccountService"> <tuscany:binding.jsonrpc uri="/AccountJSONService" /> <binding.ws wsdlElement="http://bigbank#wsdl.port(AccountService/AccountServiceSoap)" /> <binding.sca /> </service> ... </component> |
...