Dev 328.NET & J2EE Strategies for Interoperability David Aiken Lead Enterprise Architect.

Post on 13-Dec-2015

216 views 0 download

Transcript of Dev 328.NET & J2EE Strategies for Interoperability David Aiken Lead Enterprise Architect.

Dev 328

.NET & J2EEStrategies for Interoperability

David Aiken

Lead Enterprise Architect

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Motivation

J2EE/Java applications exist

Migration is not an “Overnight” process

Design for InteroperabilityRe-use legacy systems

Replacement (phased)

Pilot for adoption

Cost savings for developer Resources

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Interoperability ScenariosTechnology Map

J2EE

.NET

ASP.NETServiced

Components

JSP/StrutsServlets

EJB’sDatabase

Message Queue

Broker

Interoperability ScenariosPresentation Tier

J2EE

.NET

ASP.NETServiced

Components

JSP/StrutsServlets

EJB’sDatabase

Message Queue

Broker

Interoperability ScenariosBusiness Tier

J2EE

.NET

ASP.NETServiced

Components

JSP/StrutsServlets

EJB’sDatabase

Message Queue

Broker

Interoperability ScenariosShared Resources

J2EE

.NET

ASP.NETServiced

Components

JSP/StrutsServlets

EJB’sDatabase

Message Queue

Broker

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Integration Technologies

Wire Level

Message Queues

Web Services

Integration TechnologiesWire Level

ProductsJa.NET (Intrinsyc), JNBridge Pro (JNBridge)

AdvantagesWire Level, Binary Performance

Keep Alive

DisadvantagesTightly Coupled Interface

Vendor Specific

Integration TechnologiesMessage Queues

ProductsMSMQ, IBM WebSphere MQHost Integration Server 2000, BizTalk Server 2002

AdvantagesLoosely Coupled, N to N Scenarios, SOATransactions, Security, RM

DisadvantagesSynchronous Operation is LimitedPossible Port / Firewall IssuesMessage Queue between Organizations?

Integration TechnologiesWeb Services – The way forward!

Products Standards-based SOAP stacksMS ASP.NETApache Axis, Glue etc.

AdvantagesLeverage component architectures & design patternsFacilitate service-orientationLoosely Coupled

DisadvantagesVerbose

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Complex DataIntegration Challenge

.NET and Java Data Types do NOT map.net DataSet = ????

Java Vector = ????

We like to work with Native ObjectsDataSets, Collections, etc.

Complex DataIntegration Challenge - Facts

Thoughts:We Should be Thinking Service

We Should be Thinking Multiplatform

We Should NOT be Thinking RPC’si.e. Method Calls

We are Exchanging Messages

XML is our Data Format

XSD Should Define Message Structure

Complex DataIntegration Technology Factors

WireCreates proxies of data typesProxies Not Platform Friendly (e.g. No Data Binding)

Message QueuesAlready exchange messages!Need a common format

Web ServicesShould be exchanging messages!WSDL differences

RPC vs. document style interfaces

Not Platform Friendly (e.g. No Data Binding)

Complex DataIntegration Solution

Exchange Messages as XMLReturn XML

Return String containing XML

All Platforms Understand String

All Platforms can Parse XMLAfter all its just text!

Structure Defined Using XSD

Loosely Coupled

Supports Versioning!

Complex DataKey Lesson

XSD (Data Transfer Objects)Programming model independent

XSD(DTO)

J2EE™™

DOMJAXM

Custom Serializer Vendor Tools

.NET™™

Typed DataSet Xml Serialization

Namespace

Web ServicesComplex Data Types

David Aiken

Lead Enterprise Architect

demodemo

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Integration Architecture

Design GoalsCapture Use Case in Code

Allow Interoperability to Change

Change Integration without breaking code

Use Best Practices

XBikes Sample ApplicationBased on Downhill Bikes

Several Flavours.net, J2EE IBM WebSphere

JBoss, WebLogic soon!

Object1 Object2 Object3 Object4

Actor3

Message5

Message6 Message7

Message8

Message9

Message10

System

UseCase1

UseCase2

UseCase3Actor1

UseCase4

«extends»

*

*

* **

*

Component1

Component2

Component3

Actor2

Message1

Message2

Message3

Component4

Message4

Use CaseModel

CollaborationDiagram

Object SequenceDiagramGUI Prototype

DomainModel

ClassModel

Dynamic

Static

«datatype»DataType1

«datatype»DataType2

«datatype»DataType3

Class1

Class2 Class3

Class4

1 *

Designing for Integration

Code

Design Patterns

CommandEncapsulate a request as an object, thereby letting you parameterize clients with different requests, queue or log requests, and support undoable operations.

AdapterConvert the interface of a class into another interface clients expect. Adapter lets classes work together that couldn't otherwise because of incompatible interfaces

FactoryProvide an interface for creating families of related or dependent objects without specifying their concrete classes.

Presentation Business Logic Data

XBikes Execution

.NET.NET .NET.NET

J2EEJ2EE

SQL

SQL

Use CaseFactory

Config.xml

CommandAdapters

Client Use CaseAdapter

IUseCase uc = Factory.GetUseCase(“XXXX”);DataSet dto = uc.execute();

WS

Wire

MQ

WS

Wire

MQ

BizServiced

Components

DALADO.NET

BizSessionBeans

DALEntityBeans

Se

rvic

e F

ad

eS

erv

ice

Fa

ça

de

Integration – XBikesArchitecture

David Aiken

Lead Enterprise Architect

demodemo

Integration – XBikesWeb Services

David Aiken

Lead Enterprise Architect

demodemo

Agenda

Motivation

Integration Scenarios

Integration Technologies

Complex Data

Integration Architecture

Taking it Further

Taking it Further

Orchestration

XML Web Services Standards Architecture

Orchestration layer (BizTalk)Business Logic DataPresentation

DTO

.ASPX Code

Behind.ASPX

BizTalkBizTalk Multipoint Multipoint

OrchestrationOrchestration

Orchestration LayerOrchestration Layer

BizTalkBizTalkWS WS

AdapterAdapter

MSMQMSMQ (Asych (Asych Adapter)Adapter)

J2EEJ2EE JDBCJDBC

ADO.ADO.NETNET.NET.NET

XML WSXML WS

XML WSXML WS

UCAdapter

OTHEROTHER(NOT XML WS)(NOT XML WS)

Web Service Standards

Web Services Interoperability Organisation

Safe subset of SOAP / WSDL etc.http://www.ws-i.org/

Basic Profile (Draft) 1.0

Usage Scenarios

Some testing tools

Follow specification for higher success

XML Web Services Standards Architecture (WS interop platform)

SOAP

HTTP/SMTPXMLTCP/IP

Directory

InspectionSOAP SOAP ModulesModules

SOAPSOAPProtocolsProtocols

Referral

Routing

Security

License

Eventing Transactions

Queuing

The Internet

…Description

… …

DiscoveryDiscovery Application InfrastructureApplication Infrastructure

BasicBasic

Web Services Standards

Microsoft(WSE)

IBM(WSTK)

J2EE™™APPLICATION

SERVER

WINDOWS™™

IIS / COM+

Recommendations

Look out for the Microsoft Patterns & Practices Guide – Coming Soon!

Download DHB/XBikes demo apps to understand J2EE & .NET interop issues http://www.dotnetland.co.uk

DHB / XBikesIntegration Reloaded

David Aiken

Lead Enterprise Architect

demodemo

Summary

Design Integration at the use case levelSelect technology

Default = Web Services

DataThink XML

Use Factory / Adapter Pattern to protect code from changesRemember Loosely Coupled, Message Based, Use-case Driven Architecture

Ask The ExpertsGet Your Questions Answered

Thursday 9-11am

Community Resources

Community Resourceshttp://www.microsoft.com/communities/default.mspx

Most Valuable Professional (MVP)http://www.mvp.support.microsoft.com/

NewsgroupsConverse online with Microsoft Newsgroups, including Worldwidehttp://www.microsoft.com/communities/newsgroups/default.mspx

User GroupsMeet and learn with your peershttp://www.microsoft.com/communities/usergroups/default.mspx

evaluationsevaluations

© 2003 Microsoft Corporation. All rights reserved.© 2003 Microsoft Corporation. All rights reserved.This presentation is for informational purposes only. MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS SUMMARY.This presentation is for informational purposes only. MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS SUMMARY.