Download DOCMT

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Enterprise Component Comparison:
An Examination of J2EE, CORBA, and .NET
Midterm Specification
Seth Freeman
Phil Griffith
Frank Manni
10/21/2005
Prof. Steve Demurjian
1.
Overview
The goal of our project is to perform a comparison of J2EE, .NET, and CORBA
capabilities for component-based application design in four important areas of
computing. These areas include database connectivity, Web Services, security and
interoperability. In each of these areas, we will evaluate how each platform performs in
comparison to the others. By comparing these platforms for these tasks, we hope to know
which one is the best to use for implementation of a specific task.
All large distributed applications depend on databases to store application-related
data. We will explore the facilities in J2EE, .NET and CORBA that support database
connectivity. We will examine the different ways J2EE and .NET handle database
updates, insertions and queries. We will also compare the performance of J2EE and .NET
in updating and querying a sample database.
Web Services allow applications to share functionality using communication
protocols such as HTTP, SOAP and XML. We will examine the facilities in J2EE and
NET to create and deploy a web service. We will also explore the mechanism for each
platform to invoke the methods of a web service. Finally, we will compare the ease of use
of implementing a web service in J2EE vs. .NET, as well as the performance of each.
CORBA provides similar functionality to Web Services in that it facilitates the
communication between multiple distributed applications. We will examine the benefits
of utilizing web services vs. CORBA.
Security of distributed applications is paramount. Platforms used for developing
distributed applications must provide API's to enforce security. We will focus on the
security mechanisms performed directly by the application and application framework to
enable authentication, authorization and the encryption of data. J2EE, .NET and CORBA
each include services to do this. We will explore these technologies in detail and
determine their strengths and weaknesses. We will also compare the ease of use of
incorporating authentication and authorization in applications developed by J2EE, .NET
and CORBA.
The interoperability of an application determines how well the application can
exchange information with other applications residing on heterogeneous platforms. This
is an important factor when designing distributed applications, because clients, servers,
databases, and other components often reside on different platforms. Thus there must be
tools that allow the application developer to translate data and information among
different platforms. We will examine what support J2EE, .NET and CORBA provide to
facilitate this exchange.
2.
Detailed Discussion/Scope
In this project, we plan to compare/contrast the functionality of J2EE, .NET, and
CORBA for component-based application development. Below is a brief description of
each of the technologies, and their underlying components.
2.1
J2EE
J2EE (Java 2 Platform, Enterprise Edition) is a specification to enable application
developers to develop multi-tier enterprise-wide distributed applications. Developed by
Sun Microsystems in collaboration with leaders in the enterprise software arena, J2EE
focuses on providing a software platform that promotes the development and deployment
of reusable software components.
J2EE is an extension of J2SE (Java Platform 2, Standard Edition). J2SE consists
of a robust set of API’s for application developers based on the Java programming
language. Applications developed in J2SE are compiled into Java byte code and run on
the Java Virtual Machine (JVM). The core Java API’s and the JVM together constitute
the Java Runtime Environment (JRE) which is required on any hardware platform which
wants to support J2SE. Figure 2 is a diagram of J2SE v1.5 which shows the relationship
between J2SE, JRE, JVM as well as the numerous packages available.
Figure 2. Java 2 Standard Edition version 1.5
J2EE extends the J2SE by adding support for Enterprise JavaBeans components,
Java Servlets, JavaServer Pages, XML technologies and Web Services. Enterprise Java
Beans are server-side components used to encapsulate the business logic of an
application. Java Servlets are Java programs used to extend the functionality of a server.
JavaServer Pages (JSP) are HTML documents embedded with Java code, used to
dynamically create HTML pages. XML technologies are used to allow the transfer of
data between various components in a distributed application, and are realized through
multiple packages including Java API for XML Processing (JAXP). Web Services are
supported through Java packages such as Java API for XML-based RPC (JAX-RPC).
This extra functionality provided in J2EE is what enables the development of enterprisewide applications.
2.2
.NET
.NET, developed by Microsoft in 2002, is a platform designed for application
developers to quickly develop Internet-based applications. .NET supports distributed
application development by including database support through ADO.NET, legacy
support through IIOP.NET, as well as support for Web Services and XML. The .NET
Framework is the infrastructure to support .NET technologies consists of the following
components, illustrated in Figure 2.
VB.NET
C#
VJ#
VC++.NET
Web
forms
XML Web
Services
ASP.NET
……..
Window
Forms
.NET Framework class Library
Common Language Runtime (CLR)
Win 32
Figure 2: Framework for .NET
The .NET Architecture is comprised mostly of two components. One is the .NET
Framework class library and the other is the Common Language Runtime (CLR). The
CLR is responsible for providing the run time environment and services to the .NET
framework. The CLR consists of many components including the garbage collector,
Class Loader, thread support, Type checker, Security engine, etc. The compilers of the
.NET languages turn the source code into Microsoft Intermediate Language (MSIL),
which is used by the CLR to execute code. This is beneficial as it makes developing
applications in .NET easier since the choice of language in the .NET framework wont
matter because they will all be interoperable. This also leads to reusability of classes
among different languages. So a class in one language can be used for another
application that is being coded in a different language.
The classes in this library support object oriented capabilities like inheritance,
polymorphism, etc. The class library provides a common type system shared among all
of the languages. This means that a String in one language for example, Visual
Basic.NET, is the same type as a String in C#. So the class libraries are universal for
every language in the framework. .NET is very XML oriented and several features make
use of its benefits. As a result there exists XML Classes in the class library that are used
to provide support for communicating with relational and non-relational data sources
through XML format. At the top layer, application developers can develop either
Windows Forms for a user of the application to interact with, and/or develop Web Forms
and XML Web Services through the programming language ASP.NET. Overall the
.NET framework provides a consistent language independent model for developing all
types of applications, making it great environment for developers.
2.3
CORBA
CORBA (Common Object Request Broker Architecture) developed by Object
Management Group (OMG) is a middleware architecture used to facilitate
communication between heterogeneous applications over a network. Because of this, the
main focus of CORBA is interoperability.
CORBA allows for objects written in one programming language to be mapped to
objects in a different language. Of paramount importance to CORBA is the object. Any
reference to this object must use the object's interface [OMG]. In CORBA, an objects
interface is completely separate from its implementation, and when an object is
referenced through its interface, both the input and output parameters must be supplied.
This is done by defining an OMG IDL (Interface Definition Language) for each object to
be shared locally, or across the network. Clients can then send requests to a given object
through the ORB (Object Request Broker), which transparently sends/receives
requests/responses to distributed or local object implementations. Using the ORB for an
object requires a common protocol, but the overwhelming majority of CORBA
applications use a standard protocol [OMG].
Figure 3: The above figure shows how a client references an object. The client
references the IDL (interface) Stub, which arrives as a request to the ORB. The ORB
then accesses the IDL Skeleton to reference an object directly.
A key strength of CORBA is its use of remote method invocation. For every
instance of an object, CORBA keeps track of a reference to that instance. When a request
is made for an object, CORBA looks at the reference. If the reference is to a remote
object, the request is sent across the network. If the reference is to a local object, CORBA
performs a local invocation.
3. Component Project Breakdown
3.1
Database Connectivity
In this section we will compare the technologies in .NET, J2EE and CORBA to
facilitate database usage. We are focusing on the following areas:




Components – What are the underlying classes that enable database
interoperability?
Connectivity -What is the process of establishing connections to various
databases?
Interactions – How are updates to the database executed? How are the results of
queries are obtained and processed?
Performance – What platform performs best on real-world data?
3.1.1
3.1.2
3.1.3
3.1.4
3.1.5
ADO .NET (Frank)
JDBC (Seth)
CORBA (Phil)
Comparison (All)
Example code and analysis (All)
3.2
Security
In this section we will compare the technologies in .NET, J2EE and CORBA to
enable security measures. We are focusing on the following areas:
 Authentication – What capabilities exist within an application to determine an
entity’s identity?
 Authorization – What capabilities exist within an application to restrict/grant
resources based on the requesting entity’s identification?
 Encryption - What built-in techniques are there to encrypt data?
 Development – Which of these utilities that enable authentication and
authorization are easier for the application developer to use?
3.2.1
3.2.2
3.2.3
3.2.4
3.2.5
.NET (Frank)
J2EE (Seth)
CORBA (Phil)
Comparison (All)
Example code and analysis (All)
3.3
Web Services
In this section we will compare the technologies in .NET, J2EE and CORBA to
support Web Services. We are focusing on the following areas:
 Functionality – How are Web Services supported?
 Development – How easy is it to develop a Web Service on each platform?
 Performance – Which client on a given platform performs better for a given Web
Service? For the same Web Service created on (two) different platforms, which
performs better?
3.3.1 .NET (Frank)
3.3.2 J2EE (Seth)
3.3.3 CORBA (Phil)
3.3.3.1 CORBA vs. Web Services (Which performs better?) (Phil)
3.3.4 Comparison (All)
3.3.5 Example code and analysis (All)
3.3.6 Interoperability
In this section we will compare the technologies in .NET, J2EE and CORBA that
facilitate communication between heterogeneous applications. We are focusing on the
following areas:
 Components – What classes/packages support interoperability?
 Functionality – How do applications designed for each platform typically
communicate with heterogeneous/homogeneous components?
 Remote Communication – How are remote methods handled in J2EE and
.NET?
3.3.7
3.3.8
3.3.9
3.3.10
.NET (Frank)
J2EE (Seth)
CORBA (Phil)
Comparison (All)
4.
Progress and Changes
4.1
Progress to Date
In the first half of the project we focused on Database connectivity and Web
Services.
We did the preliminary research in both of these areas leaving the code
section until the last 2-3 weeks of the semester to focus on.
For .NET there is a detailed description of the ADO.NET interface. This includes
the functionality, the role of XML including the benefits, and the components associated
with ADO.NET. For J2EE research was conducted on the different categories of JDBC
drivers used in the J2EE. The underlying classes and functionality were also researched.
After comparing .NET and J2EE it was evident both platforms function very closely each
other. The biggest difference was in the data structures used to store the results of
queries, DataSet for .NET and ResultSet for J2EE. These components both attempted to
process information locally rather than maintaining a continuous connection to the
database. The DataSet on the other hand is a bit more complex and has more power of
the J2EE ResultSet, as it can perform more database operations like creating tables and
performing updates. The dataset can behave like a temporary relational database that is a
subset of the original database. It was also discovered that while CORBA can be used for
database connectivity it is not as relevant as the other two technologies. While you can
add the middleware of CORBA to the database connection it doesn’t make much sense to
add an unnecessary tier. While it is not overly pertinent it will still be discussed in
detail.
In evaluating Web Services J2EE and .NET are more or less the same. They both
implement web services using XML over the SOAP and HTTP protocols. At this point
in time there are no underlying differences between the two as they function almost
identical with some minor differences. In evaluating some web service code in the
upcoming weeks there will be performance tests, which may or may not reveal some
performance discrepancy.
There is a debate however about whether of not CORBA is better than Web
Services. They both provide similar functionality, but CORBA provides more structure.
CORBA also automatically creates certain communication areas that are not necessarily
generated with a Web Service. However, to further confuse the issue, CORBA also is
compatible with Web Services. In our research, we still need to investigate which one is
better and why.
4.1.2
Project Changes
The following changes have been made since our initial specification:




5.
Changed the Multi-threading section to Interoperability..
Updated the database interoperability section to database connectivity.
Added experimentation to database connectivity, web services and remote
communication.
Focused on what we are examining for security and Web Services.
The main change was in our fourth topic. In the initial specification we didn’t
have a clear direction in our research. This issue has been resolved and is now
more focused. Additionally there is more focus in the other areas and the overall
scope is more defined.
Remaining Schedule
In the next two weeks we will focus on the two remaining topics security and
interoperability. We will devote 1 week or so for each topic. Then in the following 2-3
week period we will focus on assembling some example code for each of the four areas.
We will then test the code and evaluate how the 3 technologies perform. For the
remainder of the semester the project will breakdown as follows:

10-20-05:10-26-05: Prepare the presentation for the upcoming week. Plan to
finish in the weekend before the 24th.

10-27-05:11-07-05 Conduct research on security.

11-08-05: 11-18-05 Conduct research on interoperability.

11-19-05:11-28-05 Start getting some code together over Thanksgiving Break that
demostrate the capabilities of the 3 platforms. We will cover some sample DB
interaction code. We will implement some sample web service code. Lastly there
will be some security code.
11-29-05: 12-09-05 Start preparing the final report and final presentation to be handed in
by the assigned date and present the final presentation on our scheduled date which is
TBD.6.
References
[ADO.NET 1] overview of ADO.NET
http://www.csharphelp.com/archives3/archive586.html
[ADO.NET 2] paper about ADO.NET and .NET framework
http://www.perfectxml.com/apress/ADONETIntro.pdf
[CORBA/SOAP] Web Services/SOAP and CORBA,
http://www.xs4all.nl/~irmen/comp/CORBA_vs_SOAP.html
[J2EE App Model] J2EE Application Model,
http://www.java.sun.com/j2ee/appmodel.html
[J2EE Intro] Developing Distributed Applications in J2EE,
James L. Weaver, Kevin Mukhar, Jim Crume Beginning J2EE 1.4, From Novice to
Professional New York, NY Apress 2004
[J2EE Spec] J2EE Specification, v1.4, http://java.sun.com/j2ee/j2ee-1_4-fr-spec.pdf
[.NET Intro] Includes some background info on .NET,
David S.Platt Introducing Microsoft.NET 2002 Microsoft Press Redmond, Washington.
[.NET Oracle] .NET Application Development with Oracle,
http://www.oracle.com/technology/pub/articles/mastering_dotnet_oracle/index.html
[.NET Report] Previous semester report,
http://www.engr.uconn.edu/~steve/Cse298300/Fall02Projs/NetInitiative/NIFinalReport.doc
[.NET Web] Includes Web Services and Database information,
Bob Willer Developing XML Web Services and server components with Microsoft
Visual Basic.NET and C#.NET Redmond, WA Microsoft Press 2003.
[OMG] Getting Started with CORBA, http://www.omg.org/gettingstarted/corbafaq.htm
7.
Appendices
ADO.NET architecture
.NET Data Provider
Connection
Transaction
Command
Parameters
DataSet
Connection
Select Command
Insert Command
Update Command
DataTableCollection
DataRowCollection
DataColCollection
ConstraintCollection
Delete Command
Data Reader
DataRelationCollection
XML