SOA Fundamentals for Java Developers · SOA Fundamentals For Java Developers Alexander Ulanov,...

Preview:

Citation preview

SOA Fundamentals For Java DevelopersAlexander Ulanov, System Architect

Odessa, 30 September 2008

SOA Fundamentals For Java DevelopersAlexander Ulanov, System Architect

Odessa, 30 September 2008

What is SOA?What is SOA?

• Software Architecture style aimed on• Reuse• Growth• Interoperability

• Maturing technology framework supporting the architecture

• Next evolutionary step of enterprise information systems

• An effective mean to close the gap between business and IT

Enterprise EcosystemEnterprise Ecosystem

SOA

SOA for IT-resources integrationSOA for IT-resources integration

• Common infrastructure based on open and widely-adopted standards

• Reuse of enterprise information services and other software assets

• Going beyond the enterprise – integration with:• Partner’s IT• Global chain of information services providers and consumers

• Unified policies to all services and applications• Service level agreements

• Integrating legacy systems • Smooth transition

SOA for Business-IT AlignmentSOA for Business-IT Alignment

• Software resources (services) are designed as a business function

• The services are orchestrated to fulfill particular business-process

• This involves:• Services are understandable in terms of business (visibility)• Local changes in IT as response to new or changed business-

process• Events in information system can be simply abstracted to

business key performance indicators (KPI)

Reference ArchitectureReference Architecture

Principles of Service DesignPrinciples of Service Design

• Top-down: from business-processes to services contract

• Bottom-up: from existing software assets – how to fulfill the contract

Design by ContractDesign by Contract

• Contract• Interface definition

• Operations• Data types

• Policy assertions• Identify behavior

attributes

• “Contract first”

Loose CouplingLoose Coupling

• Service contracts impose low consumer coupling requirements

• Negative coupling:• to implementation of service

logic• to vendor technology• to resources of the

implementation environment• to parent business-process

AutonomyAutonomy

• High level of control over underlying runtime execution environment

• Gradual transformation• Reducing shared resources access• Increasing physical isolation

• Autonomy is especially important to the effectiveness of service compositions

ComposabilityComposability

• Fundamental principle - system decomposition and separation of concerns

• Ability to act as an effective composition member so that it can support the realization of new business requirements that can be fulfilled by the assembly of service compositions

• That involves service properties:• Designed from business-process

model• Autonomous• Loosely coupled

• Composition design pattern:• Functional call

StatelessnessStatelessness

• Concurrent access to statefull service is a scalability issue

• Deferring the management of state information when necessary• Empowers composition and reuse

AbstractionAbstraction

• General categories of information about service:• Functional• Technology• Programmatic• Quality of Service

• Service contracts contain only essential information

• Information about services is limited to what is published in service contracts

ReusabilityReusability

• Services contain and express agnostic logic• Contract centralization• Logic centralization

• Can be positioned as reusable enterprise resources• Inventory (Repository)

• To support reuse• Conservative

• Specify requirements to reuse that service

• Governance effort• Cultural change

• Developers encouraged to discoverfor reuse

DiscoverabilityDiscoverability

• Services are supplemented with communicative meta-data• Functional• Quality of Service

• And can be effectively discovered and interpreted• Service Registry

• Similar process for run-time (dynamical binding)

Standardized Service ContractStandardized Service Contract

• Same contract design standards within service inventory (repository)

• Standards enable automated policies governance

ProcessProcess

SOA ProgramSOA Program

Service Life-Cycle ManagementService Life-Cycle Management

Service InfrastructureService Infrastructure

Communication ProtocolsCommunication Protocols

• WS-*• Large set of standards issued by OASIS

• Security, reliable messaging, policies, etc..• SOAP – basic communication protocol• Standard Java API – JAX-WS

• RESTful Services• JAX-RS

• JMS

• EJB (RMI/IIOP)

• etc

Exposing and Calling Web-Services in JavaExposing and Calling Web-Services in Java

• JAX-WS: server • Expose service from

• EJB• POJO• Spring component

• From WSDL to code vs. from code to WSDL

• JAX-WS: client

Infrastructure FunctionsInfrastructure Functions

• Mediation & Messaging• Synchronous and

asynchronous message delivery

• Transport protocol adapters• HTTP, SOAP, SMTP/POP3,

JMS, FTP, …

• Caching

• Security• End-to-end• Message-level

• Dynamical binding

• Service Composition• Data transformation• Content-based routing• Event-flow orchestration

• Management• Service Provisioning• Traffic management• Monitoring, Logging,

Alerting

Apache Synapse / WSO2 ESBApache Synapse / WSO2 ESB

• Lightweight ESB • Mediation• Transformation (XSLT, XQuery)• Security (WS-Security)

Service Component Architecture (SCA)Service Component Architecture (SCA)

• Programming model seen by application code remains the same regardless to protocol

Service Component Architecture (SCA)Service Component Architecture (SCA)

• Assembly:• Packaging component as a

service• Combining into composites• Dependency Injection• Wiring, Auto-wiring• Properties

• Annotations• @Remotable, @Reference,

@Property…• SCDL configuration files

Service Component Architecture (SCA)Service Component Architecture (SCA)

Advantage over Spring:• remote components• multiple protocols for communication • variety of programming languages for application components• support for an asynchronous programming model • flexible application of policy to components and to communications

Open-Source Infrastructure ProductsOpen-Source Infrastructure Products

• JAX-WS Containers• Java 6 SDK WS-Container• Sun JAX-WS (Metro)• Apache CXF

• ESB• Apache ServiceMix

• IONA Fuse ESB• Mule ESB• Apache Synapse

• WSO2 ESB• Sun’s OpenESB• JBoss ESB

• SCA container• Apache Tuscany

• Messaging• Apache Active MQ

• Registry• ApacheDS (LDAP)• Sun OpenDS (LDAP)• Apache jUDDI (UDDI)

• Registry/Repository• Mule Galaxy• WSO2 Registry

What else is worth to study?What else is worth to study?

Questions?Questions?

Recommended