.NET AND JAVA
INTEROPERABILITY
Pooya
http://blogs.msdn.com/pooyad/
Interop
Beyond .NET
Open Source
Cool Stuff
Background
Velocigen Inc
High performance CGI engine (C++, Perl, Tcl)
XML processing engine – pre-cursor to ESB
Velometer (Java open source web testing tool)
Blue Titan Inc
Web Services Governance
Management
Routing and Reliability
…
J2EE
Java Language
Java Enterprise API (EJB, JSP, JDBC, JNDI, JTS, etc.)
Java Extension API (javax.*)
Java Base API (AWT, IO, Collections, etc.)
Java Virtual Machine
Operating System
.Net Framework
VB
C++
C#
IronPython
J#
Common Language Specification
Windows
Forms
ADO.NET and XML
Base Class Library
Common Language Runtime
Operating System
Visual Studio
ASP.NET
Web Forms Web Services
Comparing the Stacks
What they have in common
abstract stack machines (runtime type control,
exception handling, garbage collection)
rich base class libraries
The most obvious difference
Java supports one language on multiple OS
.Net is language neutral (20+ supported) on one OS
The main .NET languages (C#/VB) and Java are
advancing along similar paths, e.g.
Both now have generics
Java has added annotations (analogous to .NET’s
attributes)
Java Platform/.NET Framework
JDBC
Browser
HTML, XML
HTTP
Device
Servlet
or
JSP
HOME
REMOTE
Transactions
Concurrency
RMI
Entity
Bean
Security
http
server
Rich GUI
client
Data
Context
JVM
Session
Bean
Containers
EJB Server
App Server
any OS
Browser
Device
ADO.NET
HTML, XML, SOAP
ASP.NET
HTTP
or
ISAPI
IIS
Rich GUI
client
Managed
Object
Security
Transactions
Managed
Object
Concurrency
Web Svc,
Remoting
Context
Windows
.NET Framework
Data
Interop: many alternatives
.NET Application
COM
Interop
ASP.NET &
WSE
Windows Communication
Foundation
.NET
Remoting
Remoting
channel
WS-* / SOAP / HTTP
BizTalk
SOAP Server
JACOB,
JaWin
JMS
J-Integra,
Visibroker,
JNBridge
EJB
IIOP
JNI
ActiveX
Bridge
JAX-WS,
JAXB
JMS
Java application
EJB
File System
File
System
Database
Data
Store
Middleware / Queues
Middleware / Queue
Remoting - Integration with Java via IIOP
Intrinsyc’s J-Integra Espresso product
Next version will integrate IIOP as a WCF channel
Current version links .NET to CORBA ORB via .NET Remoting
Other ISV products that use .NET Remoting as the
bridge:
JNBridge Pro , Borland Visibroker , Open Source IIOP.NET
Interop options
Shared database between .NET and J2EE
Queues – MSMQ, IBM MQ Series
Middleware – Biztalk, Websphere
UI - shared session state and shared authentication
Remoting
Web services
Web services to
the rescue
Web Services as Component Object
Model
Application
Concepts
Standards
Framework
Data
XML
Objects
Schema
XSD
Classes
Services
WSDL
Methods
Invocation
SOAP
Calls
XML is the key
XML
WS-* Advanced Standards
WS-Trust
WS-Secure
Reliability
Transactions
WS-Reliable
WS-AtomicTransaction
Messaging
WS-Coordination
Conversation
WS-Federation
Messaging
SOAP, MTOM, WS-Addressing
XML
XML, XSD, XPath
Transports
HTTP
Metadata
WS-Security
WSDL, WS-Policy,
Security
WS-MetadataExchange
Broad industry support
WS-* Architecture
WS-Federation
WS-Management
Devices
Profile
>Infrastructure
and Profiles
Metadata
WS-Metadata
Exchange
WS-Secure
WS-Business
Conversation
Activity
WS-Atomic
WS-Discovery
Transaction
UDDI
WS-Trust
WS-Security
WS-Reliable
Messaging
WS-Coordination
WS-Transfer
WS-Enumeration
WS-Eventing
SOAP
WS-Addressing
MTOM
XML Infoset
XML 1.0
Assurances
WS-Policy
Messaging
XML Schema
SOAP / UDP
XML
Namespaces
MIME
WSDL
SOAP / HTTP
Foundation
Windows Communication
Foundation Introduction
WS-* Standards support
Write once expose multiple ways
WS-*
HTTP
TCP/IP
…
REST
JSON
Unifying Communication
WCF
.NET Framework 2.0
Applications
API
ASMX & WSE
.NET Remoting
System. Messaging
Protocol
SOAP & WS-*
Remoting
MSMQ
Enterprise
Services
DCOM
protbinaryocol
.NET Framework 3.0
Applications
API
Protocol
Windows Communication Foundation
SOAP & WS-*
WCF binary
protocol
MSMQ
Others
WS Interop Pulg-Fests
Interoperability Workshops
Companies attending:
BEA
Canon
Iona
Jboss
Microsoft Corporation
Nokia
Oracle
Reactivity
Sonic Software
Sun Microsystems
WSO2 (Apache)
…
Does it really work?
.NET StockTrader Example
http://msdn2.microsoft.com/en-us/vstudio/bb499684.aspx
Equivalent to IBM Websphere 6.1 Stock Trader
application
Same services exposed
Web UI
SOAP
Services Layer
True Interop
Services in the application are exposed, via WCF, as
industry-standard Web Services.
The .NET StockTrader Web application seamlessly
interoperates with the backend J2EE services of the
WebSphere Trade 6.1 application
Conversely, the WebSphere Trade 6.1 Web application is
able to seamlessly utilize the backend services of the
.NET StockTrader. In each case, a simple endpoint
configuration allows this interoperability, with no code
changes required to either application.NET StockTrader
and J2EE Interoperability
How about something
more complex?
Project Tango (WSIT)
Sun-Microsoft partnership
A part of Sun’s Glassfish initiative (open source JEE5
server) – Project Metro
Goal: Java™ technology Web Services interoperability
with .NET 3.0. (showcased at JavaOne)
Accomplished by fully interoperable implementations of:
WS-Addressing, WS-Transfer, WS-MetadataExchange and WSPolicy for discovery and routing
WS-Security, WS-Trust, WS-SecurityPolicy for secure messaging
MTOM and XOP for attachment encoding
WS-ReliableMessaging, WS-Coordination and WSAtomicTransaction for reliability and transactions
For more information:
http://java.sun.com/developer/technicalArticles/glassfish/
ProjectTango/
Project Tango - WSIT Demo
Try it on your own: (bits are available)
http://blogs.sun.com/arungupta/entry/excel_using
_wsit_javaone_2007
Scenario: Excel 2007 accessing webservices
running in Glassfish
WS-Security - Kerberos
Excel calling Java webservice
SOAP
.NET Client calling Java Webservice
Before Project Tango
WS-Trust
Federated Trust
Microsoft
STS
Oracle
T
STS
MEX
WS-Trust
Metadata Exchange
Jean-Luc Picard
(Excel, WCF)
Data
(Oracle Fusion Middleware)
Interop
Beyond .NET
Open Source
Cool Stuff
Beyond .NET
SQL
Sharepoint
Office
Silverlight 1.0 + 2.0
Live Services
Live Maps
Messenger
…
SQL
SQL 2008
.NET – Java Portal Integration
.NET Application
NetUnity
WSRP .NET Framework™
.NET XML / XSLT
WCF
ASP.NET / WSE
BizTalk
SOAP Server
WSRP / SOAP
WSRP Framework
JAX / Web Services Framework
Weblogic Portal 8.1 SP3
BEA Weblogic
Office as a Development Platform
Open Office XML
Excel demo – Project Tango
Word demo – OOXML
OOXML Interop Demo
1. Generate Document
Application
3. Edit Document
2. Download
4. Upload
Tomcat JSP
DB
Word 2007
IE
Windows OS
Desktop
5. Publish to Web
6. View in Browser
Web Server
VM
Linux OS
Server
Silverlight (1.0)
MLB.com
Silverlight on top of JSP – through javascript
Javascript can access Silverlight Objects
HTML + Javascript
Interop options – lots of them
Shared files
Shared database between .NET and J2EE
Queues – MSMQ, IBM MQ Series
Middleware – Biztalk, Websphere
UI - shared session state and shared authentication
Remoting
Web services
This is the key one
Standards
Resources
Microsoft Interop Portal:
http://www.microsoft.com/interop
MSDN Web Services Interoperability Home Page
http://msdn.microsoft.com/webservices/building/interop
MSDN .Net/Java Interoperability Home Page
http://msdn.microsoft.com/vstudio/java/interop
Microsoft Public Web Services Interop Tests
http://mssoapinterop.org/ilab/
Windows Communication Foundation
http://msdn.microsoft.com/webservices/indigo/
Web Services Interoperability Blogs
http://pluralsight.com/blogs/kirillg/
http://blogs.cocoondev.org/dims/index.rdf
Interop
Beyond .NET
Open Source
Cool Stuff
Open Source Initiatives
CodePlex is Microsoft's open source project
hosting web site. Start a new project, join an
existing one, or download software created
by the community.
home to the open source
community at Microsoft. This
represents an open conversation
dedicated Linux, Windows and
open source interoperability
Interop
Beyond .NET
Open Source
Cool Stuff
Cool Stuff
WPF
Silverlight 2.0
Photosynth
Popfly
Surface
Labs.live.com
http://blogs.msdn.com/pooyad
© 2006 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.
The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not
be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.
MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.