Designing and developing SCA components using the Spring framework, part 1th

Source: Internet
Author: User
Tags php and sca

Designing and developing SCA components using the Spring Framework, part 1th-Musketeers: Spring, SCA, and Apache Tuscany

In the "using the Spring framework design and Development SCA Components" series, learn how to effectively combine the service component Architecture (Services Component Architecture,sca) with the spring framework to create distributed services Application. The first article will outline the advantages of combining SCA with Spring. Learn how to use the spring Framework to design and develop SCA components, how to expose Spring beans as an SCA service, and how to access SCA services and properties in a spring application. The examples in this article will use the Apache Tuscany SCA Java™ Technology Runtime.

Brief introduction

After the Open SOA (OSOA) project publishes a white paper titled "Powerful Combinations: SCA, OSGi, and Spring", the combination of these three technologies raises some concerns. Spring Dynamic Module is a commercial implementation of this infrastructure that combines spring and OGSi. The Spring beans can be used as a component implementation of the Service Component Architecture (SCA). The Java implementation of the Apache Tuscany is based on the Apache OSGi Framework (Felix).

In this series, learn how to design and develop SCA components using the Spring Framework and the Apache Tuscany SCA Java Runtime. Examples and snippets will help you understand the benefits of combining SCA with Spring. You'll also learn how to combine SCA with Spring to create distributed service applications.

This article describes some of the basic design principles that you need to learn to develop SCA components using Spring. You will explore how to expose the spring beans as an SCA service and how to access SCA services and properties in a spring application.

Part 2nd will delve into some advanced features, such as handling multiple application contexts through SCA and using SCA annotations in Spring beans.

Download the sample source code. This example needs to run in the Apache Tuscany runtime, but its focus is not on demonstrating how to develop SCA components. This article will focus on how to use the Spring application as an implementation technology for SCA components.

Program

This article discusses the following programs.

SCA provides a programming model for creating applications and solutions based on service-oriented architectures (service-oriented architecture, SOA). SCA relies on the idea of delivering business functions as a series of services to create solutions that meet specific business needs. These composite sets can contain new services created for applications and business functions in existing systems, as well as applications that are reused as part of a composite application. SCA provides the following:

A model for service composition and service component creation, including reuse of existing applications in SCA composite sets.

Flexible compounding, reuse, technology, and deployment choices make it an ideal environment for building heterogeneous distributed systems.

Supports multiple implementations of language and communication mechanisms.

A simplified component programming model for implementing business services using a variety of technologies such as Enterprise JavaBeans, Java pojos, Spring beans, BPEL Process, COBOL, C + +, and PHP.

The spring framework, often called spring, is an open source project that tries to improve the applicability of the EE environment by addressing the complexities of enterprise application development. One of the advantages of Spring is its layered architecture. It allows you to choose which components to use, while providing a tightly coupled framework for Java EE application development. Spring provides a framework for simple Java objects that enable them to use the Java-EE container through wrapper classes and XML configurations. The goal of Spring is to get great benefits from the project and improve the test scope and application quality by improving development productivity and run-time performance. Spring is often described as a lightweight container environment, but a more appropriate metaphor might be "a framework that simplifies development". The Apache Tuscany Open source Apache Tuscany Project is dedicated to implementing SCA specifications (and some other SCA specifications, such as service data Objects and data Access service). In accordance with the Open service-oriented Architecture (OSOA) and some of the criteria for the Global Information Society (OASIS SCA Java) specification, Apache Tuscany provides a comprehensive infrastructure for the SCA runtime. The example in this article will use the Apache Tuscany V1.5, which is the latest version as of this writing. To run the sample application, you need to download the binary release of the Apache Tuscany SCA Java implementation.

SCA Assembly Model

The basic artifact of SCA is the component, which is the basic constituent unit of SCA. The component contains a configured implementation instance, where the implementation is the program code that provides the business functionality. Business functions will be provided by other components as services. Implementations sometimes need to rely on services provided by other components. These dependencies are referred to as references.

Implementations have properties that can be set, which are data values that affect the operation of business functions. The component configures the implementation by providing a value for the property and by associating the reference to a service provided by the other component. Multiple components can use and configure the same implementation, and each component can configure the implementation in different ways.

SCA Support:

Various implementation technologies, such as Java POJOs, EJBs, Spring beans, BPEL Process, COBOL, and C + +

Some scripting languages, such as PHP and JavaScript

Some declarative languages, such as XQuery and SQL

SCA describes the content and association of an application in a collection called a composite set (composites), as shown in Figure 1. A composite set can contain components, services, references, property declarations, and association descriptions between those elements. A composite set can be grouped and linked to components built with different implementation technologies, allowing for the adoption of appropriate technologies in each business task. The composite set is deployed in the SCA domain.

Figure 1. SCA Composite Diagram

The SCA Assembly Model contains a series of artifacts that define the configuration of the SCA domain in terms of a composite set, including service components and related artifacts that describe the association between components.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.