Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Summary - Haleh (first draft)

  • Its ready to use

Introduction

...

Many articles have been written about SOA and Service Component Architecture already1. We are not about to repeat the same story here. 2. This article focuses on a real, available, open source implementation for Service Component Architecture that provides a simple way to implement SOA solutions. This free open source project is called the Apache Tuscany Incubator project. The project started in 2006 and is being used by many who are looking for a simple SOA infrastructure. Apache Tuscany SCA vesion version 1.0, which was released in September 2007, supports the Service Component Architecture specification 1.0. In addition to implementing the SCA specification, Tuscany is also a nursery for new ideas that are not part of the specification yet. Some of these ideas will find their way to the specifications and some will be regarded as extensions avaialable available in Apache Tuscany. For example, support for Ruby, JavaScript, Xquery, web 2.0 and distribution are currently extensions beyond the specification.

This article will walk you through what is available in Apache Tuscany, and therefore it highlights the benefits of SCA benefits, with real use case , using some familiar scenarios. The sample code and configuration used in this article can be found in the Tuscany SCA Java SCA 2 distribution 3 and is available under the Apache License 14.6.

Using Tuscany SCA

A Common Approach To Application Construction and Deployment

...

Enterprise software development is increasingly influenced by technology choices, regulations, competition and expectations for responsiveness to change. Enterprises need the flexibility to adopt new business practices (like outsourcing of mortgage handling by a bank), enforce new regulations and extending extend or down-sizing size without much cost (M & Amergers and acquisitions). In addition, as the complexity of the enterprise grows, a common management paradigm becomes a necessasity necessity for managing the business applications. Service Component Architecture provides a simple programming model to address these challenges. SCA's simple language maps easily to the business. Let's consider we are building a banking application that handles account inquiries. The following table maps business level questions to SCA.

Business question

Banking example

SCA concept

What business functions are provided?

define services or use existing services: stock quote, account balance, etc.

Components/Services

What business functions are needed?<TBD>dependencies are there between business functions?

account balance depends onstock on stock quote service

References

How to handle flexibility in business processes?

ability to use configure different currencies

Properties

How to handle regulations ? or quality of service?

ability to handle account security

Intent/policy

What is the end to end solution?

Compose compose the services into a solution

Composition Composite/Wire

The next qustion might be if the existing IT infrastructure and skills can be used? The flexibility of SCA allows any implementation language or protocol to be used. Apache TUscany has a very extendible architecture that.....

SCA provides a consistent model of distributed applications and of the components from which they are constructed. This model explicitly separates business logic (Component/Services/References) from the details of how a running application is assembled (Composite/Wire) and deployed. This promotes a common terminology and supports a common understanding of the capability of applications and the way that applications work together. This common model also provides the hooks for tooling, governance, monitoring and management in the service oriented world.

When it comes to building a solution for real the next most important question is likely to be "how can existing IT infrastructure and skills be used?". Tuscany SCA does not invent new technologies for component implementations (Implementation) and message exchange (Binding)Tuscany SCA does not define new technologies for component implementations and message exchange. It neither requires you to learn a new programming language or communications protocol. You are free to leverage you your existing investment in applications and technology with the one proviso that a suitable binding exists in Tuscany SCA. This is not much of a hurdle though as Tuscany SCA has a straightforward extensibility model so new or proprietary technologies can easily be included.

This separation of business logic from the details of how a running application is assembled and deployed leads to a degree of software portability. More importantly though it leads to portability of ideas and a shared understanding of the capabilities and construction of the software.

Using a consistent model of applications and of the components from which they are constructed provides a common terminology and supports a common understanding of applications and they way that they work together. This common model provides the hook for tooling, governance, monitoring and management in the service oriented world.

= Move to deployment section =
The precise relationship between the abstract components and runtime infrastructure is further refined using policy statements to apply organizationally agreed constrains on the behaviour of the application in its deployed environment. For example, this could range from dictating which communications should be encrypted to describing what level of monitoring and logging is required.
= end move to deployment section =in applications, technology and skills with the one proviso that suitable support exists in Tuscany SCA. This is not much of a hurdle though as Tuscany SCA has a straightforward extensibility model so new or proprietary technologies can easily be included.

The following sections describe Tuscany SCA in the context of a number of familiar use casesthree familiar scenarios. It should be noted that Tuscany SCA is not restricted to these scenarios.

Enterprise Applications

...

In a typical enterprise, business functions are implemented using various technologies, business data are represented in different ways and business applications are communicated using heterogeneous protocols. It is almost impossible to converge all the applications onto one technology stack such as web services. To have all the applications in an enterprise talk to each other is a big challenge.

...

Tuscany SCA will use a default binding to communicate with the target service regardless of whether the service is local or remote to the calling component. In this way the infrastruture can be adjusted and the components redeployed without having to change any .composite file information. redeployed without having to change any .composite file information.

= Move to deployment section =
The precise relationship between the abstract components and runtime infrastructure is further refined using policy statements to apply organizationally agreed constrains on the behaviour of the application in its deployed environment. For example, this could range from dictating which communications should be encrypted to describing what level of monitoring and logging is required.
= end move to deployment section =

Getting Started With Your Own Project - TBD

...

There is set of guides for the Tuscany Java SCA software here (http://incubator.apache.org/tuscany/java-sca-documentation-menu.html). In particular the User Guide provides a simple walkthough of the Tuscany Java SCA Calculator sample. There is also a link (http://incubator.apache.org/tuscany/sca-java-releases.data/onlineStore.pdfImage Added) to detailed instructions of how to build a simple Web2.0 application using Tuscany Java SCA Calculator sample. There is also a link (http://incubator.apache.org/tuscany/sca-java-releases.data/onlineStore.pdfImage Removed) to detailed instructions of how to build a simple Web2.0 application using Tuscany Java SCA.

There are many more samples provided in the "samples" directory of the release. The file samples/README gives an overview of each of them and each sample comes with its own README and a graphical representation (.png file) of the services that the sample is demonstrating.

Once you have a feel for how Tuscany operates you will likely want to build a project of your own. Yo can of course take a suitable sample and use that as a starting point. Primarily you application development process will involved the following steps.

  • Identify the components in you application and the services that these components provide
  • Identify the services that these components depend on. These are the components references.
  • Build an XML (.composite) file describing the components, services, references and the relationships between them
  • Build the component implementations
  • Contribute the .composite file, the component implemenations and any dependencies to the Tuscany SCA runtime.

The order here varies as in may cases you may already have suitable component implementations that you just want to describe to Tuscany SCA.

Choosing how to run the Tuscany SCA runtime depends on you local environment but there are several options currently supported.

  • Embedded into your own Java application.
  • As a plugin to the Geronimo application server
  • As a WAR file contributed to a suitable web application server

Summary

V1.0 ready for prime time?
It is extensible so you can add to it (and contribute)

References

There are many more samples provided in the "samples" directory of the release. The file samples/README gives an overview of each of them and each sample comes with its own README and a graphical representation (.png file) of the services that the sample is demonstrating.

Once you have a feel for how Tuscany operates you will likely want to build a project of your own. Yo can of course take a suitable sample and use that as a starting point. Primarily you application development process will involved the following steps.

  • Identify the components in you application and the services that these components provide
  • Identify the services that these components depend on. These are the components references.
  • Build an XML (.composite) file describing the components, services, references and the relationships between them
  • Build the component implementations
  • Contribute the .composite file, the component implemenations and any dependencies to the Tuscany SCA runtime.

The order here varies as in may cases you may already have suitable component implementations that you just want to describe to Tuscany SCA.

Choosing how to run the Tuscany SCA runtime depends on you local environment but there are several options currently supported.

  • Embedded into your own Java application.
  • As a plugin to the Geronimo application server
  • As a WAR file contributed to a suitable web application server

Summary

V1.0 ready for prime time?
It is extensible so you can add to it (and contribute)

References

1 Real SOA - Web Services and Service Oriented Architecture, http://www.java.sys-con.com/read/299972.htmImage Added
2 What Is SCA, http://www.java.sys-con.com/read/325183.htmImage Added
3 Tuscany SCA Java downloads, http://incubator.apache.org/tuscany/sca-java-releases.htmlImage Added
4 Apache License Version 2.0 , http://www.apache.org/licenses/LICENSE-2.0Image Added

1 general SOA and SCA papers
1.5 Tuscany SCA Java download
1.6 http://www.apache.org/licenses/LICENSE-2.0
2 Getting Started With SCA - Store - http://cwiki.apache.org/confluence/display/TUSCANY/Getting+Started+with+Tuscany+Release+1.0 - Needs linking into the web page
3 sample/store
4 samplel/chat-webapp
5 sample/helloworld-ws-service-secure
6 demo/bigbank-account

Acknowledgements

A big thank you to the Apache Tuscany Incubator community for working hard to get recent SCA, SDO and DAS releases out.

Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both. Other company, product, or service names may be trademarks or service marks of others.

Old Words

Introduction

The Service Component Architecture would never claim to solve every one of your distributed computing problems, or even provide and answer to all of the questions you are likely to have about Service Oriented Architecutures. It does how ever provide a consistent component programming and assembly model that will pay dividends in lots of situations.

...