| By Haleh Mahbod, Raymond Feng, Simon Laws | Article Rating: |
|
| November 9, 2007 08:30 AM EST | Reads: |
39,570 |
Deploying Tuscany Solutions
The service-oriented approach to building applications promotes the benefits of deploying running solutions as a collection of loosely coupled services. Tuscany SCA provides a runtime that will host these loosely coupled services in a single JVM or across multiple JVMs distributed over the network.
Tuscany SCA uses the term Node to describe a single Tuscany SCA runtime and the term Domain to describe a collection of nodes that together run related but distributed services in an SCA application (see Figure 5).
As we have seen, SCA allows the location of target services to be described explicitly, for example, from the bigbank-account demo [5].
<component name="AccountServiceComponent">
<implementation.java class="bigbank.account.AccountServiceImpl"/>
<reference name="stockQuoteService">
<binding.ws uri="http://localhost:8081/services/StockQuoteWebService"/>
</reference>
...
This is very useful for contacting external services or, in the case of services, for exposing SCA services to external applications. As this approach requires that explicit endpoint information is provided, reference and service bindings are likely to require changing as services are moved between nodes in a domain. As a convenient alternative, any service within the SCA Domain can be identified simply by name.
<component name="AccountServiceComponent">
<implementation.java class="bigbank.account.AccountServiceImpl"/>
<reference name="stockQuoteService" target="StockQuoteServiceComponent/StockQuoteService">
</reference>
...
Tuscany SCA will automatically 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 infrastructure can be adjusted and the components redeployed without changing SCA configuration definitions.
Choosing how to run the Tuscany SCA runtime depends on your local environment, with several options currently supported. The Tuscany SCA runtime can be embedded or run with most available Web application servers. The Tuscany SCA 1.0 release has been tried with Apache Tomcat, Apache Geronimo, and IBM WebSphere application servers. There is work ongoing in the Apache Geronimo project to provide deeper integration between the Tuscany SCA runtime and Apache Geronimo.
It is also straightforward to use the Tuscany SCA runtime directly in your applications. It's simply a matter of starting the runtime and providing SCA configuration and associated component implementations collected together in what SCA calls a contribution (a packaging unit such as a jar file or directory).
Getting Started with Your Own Project
The easiest way to get started with Tuscany SCA is to download the latest release [3] and try some of the samples.
The SCA Java Web page [3] provides user documentation and extension guides. The User documentation provides a simple walkthrough of the SCA Java Calculator sample. There is also a paper giving detailed instructions on how to build the simple Web 2.0 application described in this paper [8].
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'll likely want to build a project of your own. You can of course take a suitable sample and use that as a starting point.
Returning to the business questions we discussed earlier, your application development process will involve some of the following steps. The order of the steps can vary since Tuscany SCA allows a top-down or bottom-up development approach.
Model the application in SCA configuration
• Identify which business functions are required and describe them using SCA components and services.
• Identify which dependencies each component has and provide each component with suitable SCA references.
• Introduce SCA Properties for any values that will have to change as the application is reconfigured or redeployed.
• Compose the services within an SCA composite structure and connect references to services using wires.
Provide business logic
• Declare interfaces as the contracts for references and services.
• Implement each component and reference the implementation from the component in the SCA configuration. The implementation may simply wrap existing application logic or may be completely new.
Provide deployment-specific information
• Describe any specific protocols that need to be used using bindings. References and services without bindings will automatically adopt a default communication strategy.
• Attach organizational policy intents to the model, for example, security intents such as authorization or confidentiality
The application model and its component implementation dependencies can now be deployed to the Tuscany SCA runtime.
Summary
We selected a few scenarios to demonstrate some of the key aspects of the SCA programming model and how it applies to the real world. Apache Tuscany currently implements version 1.0 of the SCA specifications and extends the SCA programming model with its support for many different binding types, implementation types, and runtime environments. Apache Tuscany's modular and extensible architecture makes it possible to select the set of features applicable to your solution or easily incorporate new ideas. Many businesses are using Apache Tuscany and their feedback is helping to solidify Apache Tuscany as a simple SOA infrastructure as well as making it a nursery for new ideas. You are welcome to try the software and contribute to the project.
References
1. Real SOA - Web Services and Service Oriented Architecture, www.java.sys-con.com/read/299972.htm
2. What Is SCA, www.java.sys-con.com/read/325183.htm
3. Tuscany SCA Java, http://incubator.apache.org/tuscany/sca-java.html (releases and documentation can be found on this site)
4. Apache License Version 2.0, www.apache.org/licenses/LICENSE-2.0
5. From the Tuscany SCA Java 1.0 distribution look for demos/bigbank-account
6. From the Tuscany SCA Java 1.0 distribution look for sample/helloworld-ws-service-secure
7. From the Tuscany SCA Java 1.0 distribution look for samples/store
8. Getting Started With SCA - Store - Click Here For THe PDF File
9. From the Tuscany SCA distribution look for samples/chat-webapp
10. Direct Web Remoting - https://dwr.dev.java.net/
Published November 9, 2007 Reads 39,570
Copyright © 2007 SYS-CON Media, Inc. — All Rights Reserved.
Syndicated stories and blog feeds, all rights reserved by the author.
More Stories By Haleh Mahbod
Haleh Mahbod is a program director with IBM, managing the team contributing to the Apache Tuscany as well as SOA for PHP open source. She has extensive development experience with database technologies and integration servers.
More Stories By Raymond Feng
Raymond Feng is a senior software engineer with IBM. He is now working on the Service Component Architecture (SCA) runtime implementation in Apache Tuscany project as a committer. Raymond has been developing SOA for more than 4 years and he was a key developer and team lead for WebSphere Process Server products since 2002.
More Stories By Simon Laws
Simon Laws is a member of the IBM Open Source SOA project team working with the open source Apache and PHP communities to build Java, C++, and PHP implementations of the Service Component Architecture (SCA) and Service Data Object (SDO) specifications. Prior to this role he was working in the distributed computing space building service-oriented solutions for customers with a particular interest in grid computing and virtualization.
![]() |
anonymous 03/12/08 06:13:08 PM EDT | |||
SCA sounds a lot like CORBA.. |
||||
![]() |
anonymous 11/11/07 09:28:46 PM EST | |||
SCA = CORBA |
||||
- Kindle 2 vs Nook
- Why IBM’s Server Chief Got Busted
- Is Cloud Computing Like Teenage Sex?
- Industry Experts Discuss the State of Cloud Computing
- Performance Tuning Essentials for Java
- Confessions of a Ulitzer Addict
- Tactical Cloud Computing Panel at 1st Annual GovIT Expo
- It's the Java vs. C++ Shootout Revisited!
- Cloud Computing Can Revitalize Your Career as Software Developer
- IBM Could "Reinvent" Java: Mills
- Oracle & Cloud Computing: Exclusive Q&A with SVP Richard Sarwal
- A Brief History of Cloud Computing
- Kindle 2 vs Nook
- Cloud CEOs, CTOs & SVPs to Speak at 4th International Cloud Computing Expo
- Why IBM’s Server Chief Got Busted
- Is Cloud Computing Like Teenage Sex?
- Industry Experts Discuss the State of Cloud Computing
- Performance Tuning Essentials for Java
- The Difference Between Web Hosting and Cloud Computing
- Cloud Computing Expo: Exclusive Q&A with Yahoo! SVP Cloud Computing
- Ajax in RichFaces 3.3, JSF 2 and RichFaces 4
- Confessions of a Ulitzer Addict
- My Thoughts on Ulitzer
- Tactical Cloud Computing Panel at 1st Annual GovIT Expo
- A Cup of AJAX? Nay, Just Regular Java Please
- Java Developer's Journal Exclusive: 2006 "JDJ Editors' Choice" Awards
- The i-Technology Right Stuff
- JavaServer Faces (JSF) vs Struts
- Rich Internet Applications with Adobe Flex 2 and Java
- Java vs C++ "Shootout" Revisited
- Bean-Managed Persistence Using a Proxy List
- Reporting Made Easy with JasperReports and Hibernate
- Creating a Pet Store Application with JavaServer Faces, Spring, and Hibernate
- What's New in Eclipse?
- Why Do 'Cool Kids' Choose Ruby or PHP to Build Websites Instead of Java?
- i-Technology Predictions for 2007: Where's It All Headed?










































