Comments
Richard Davies wrote: The UK has a good crop of technology pioneers in cloud computing - for example ElasticHosts, FlexiScale, Flexiant, OnApp - and also some strong government initiatives such as G-Cloud. We will have to see whether this kind of technical leadership converts into swift mass-market adoption or not.
Cloud Expo on Google News


2008 West
DIAMOND SPONSOR:
Data Direct
SOA, WOA and Cloud Computing: The New Frontier for Data Services
PLATINUM SPONSORS:
Red Hat
The Opening of Virtualization
GOLD SPONSORS:
Appsense
User Environment Management – The Third Layer of the Desktop
Cordys
Cloud Computing for Business Agility
EMC
CMIS: A Multi-Vendor Proposal for a Service-Based Content Management Interoperability Standard
Freedom OSS
Practical SOA” Max Yankelevich
Intel
Architecting an Enterprise Service Router (ESR) – A Cost-Effective Way to Scale SOA Across the Enterprise
Sensedia
Return on Assests: Bringing Visibility to your SOA Strategy
Symantec
Managing Hybrid Endpoint Environments
VMWare
Game-Changing Technology for Enterprise Clouds and Applications
Click For 2008 West
Event Webcasts

2008 West
PLATINUM SPONSORS:
Appcelerator
Get ‘Rich’ Quick: Rapid Prototyping for RIA with ZERO Server Code
Keynote Systems
Designing for and Managing Performance in the New Frontier of Rich Internet Applications
GOLD SPONSORS:
ICEsoft
How Can AJAX Improve Homeland Security?
Isomorphic
Beyond Widgets: What a RIA Platform Should Offer
Oracle
REAs: Rich Enterprise Applications
Click For 2008 Event Webcasts
SYS-CON.TV
Top Links You Must Click On


Java in the Middle Tier
Java in the Middle Tier

This month the Java platform segues into the new millennium. These are very exciting times; 1999 was a crucial year in the acceptance of Java in the enterprise as one of the key drivers of e-business. It's ironic that applets ­ the components of Java that helped propel it into the mainstream of Internet applications ­ currently occupy a backseat in the vehicle that propels Java into the 21st century. During the year gone by, the focus was on server-side Java, as predicted last year by several industry pundits ­ more precisely, on Java in the middle tiers of distributed computing.

This month in e-Java we'll take a look at some of the developments in Java that have had an impact on Java-based e-business. Specifically, we'll examine the segregation of Java into three separate editions, the role of Java servlets and JavaServer Pages and the impact of J2EE in defining middle-tier business logic.

The Three Lives of Java
At JavaOne '99 Sun made an important announcement that defines the future direction of the Java platform. The architecture for the platform was redefined, aimed at making it simpler for software developers, service providers and device manufacturers to target specific markets. The revised structure defines three editions of the platform:

  • Java 2 Platform, Standard Edition (J2SE)
  • Java 2 Platform, Enterprise Edition (J2EE)
  • Java 2 Platform, Micro Edition (J2ME)
Each of the new Java platform editions combines the Java Virtual Machine, the Java programming language, core packages and optional packages. The new editions share many core packages and the Java programming environment. Each comes with its own set of core APIs to enable development of business solutions in its respective domain.

Applications on all three editions may be developed using a common application programming model. Those developed using this model should be able to scale upwardly from systems built with J2ME to systems built with J2SE. With the Java 2 platform Sun defines what constitutes the core Java technology platform for the enterprise. A core set of APIs forms the "least common denominator" of APIs offered by the platform. For programmers on virtually any Java platform ­ from smart cards to the mainframe ­ that means that 15 class libraries have been declared "core," and thus constitute the soul of all Java technology. These are applet, awt, beans, io, lang, math, net, rmi, security, sql, text, util, accessibility, swing and corba. The three editions of the platform are described below.

Java 2 Platform, Micro Edition
J2ME is a new edition of the Java 2 platform targeted at consumer electronics and embedded devices. It consists of a virtual machine and a minimal layer of APIs targeted at providing only enough functionality to securely and safely download Java classes to a device and configure the Java environment. The rest of the Java functionality needed to provide a complete Java runtime environment for a particular kind of device is provided within the context of an industry-defined profile. J2ME comes in two flavors, called configurations, that are targeted at two broad categories of devices:

  • Devices with 128­512K of memory available for the Java environment and applications
  • Devices with 512K+ of memory available for the Java environment and applications

Java 2 Platform, Standard Edition
J2SE provides a complete, secure foundation for building and deploying network-centric enterprise applications ranging from the PC desktop computer to the workgroup server. It's implemented by the Java 2 Software Development Kit (SDK), Standard Edition, and the Java 2 Runtime Environment, Standard Edition. J2SE includes the following APIs:

  • Java Foundation Classes (JFC) and Swing
  • Pluggable Look & Feel (PLAF)
  • Accessibility
  • Drag and drop
  • Security
  • Java Interface Definition Language (Java IDL)
  • JDBC
  • Remote Method Invocation (RMI)
  • Java 2D
  • The Collections Framework
Java 2 Platform, Enterprise Edition
J2EE enhances J2SE to server-side, middle-tier applications that address multitier enterprise solutions. It enables solutions for developing, deploying and managing multitier server-centric applications. J2EE is a unified platform for building, deploying and managing enterprise-class software applications that have the ability to run on a variety of computing environments. The primary technologies in J2EE (in addition to the J2SE technologies) are:
  • Enterprise JavaBeans (EJB)
  • Java Servlets and JavaServer Pages (JSP)
  • Java Naming and Directory Interface (JNDI)
  • Java Transaction API (JTA)
  • CORBA
  • JDBC

EJB technology, the basis of J2EE, provides a scalable architecture for executing business logic in a distributed computing environment. J2EE combines the EJB component architecture with other enterprise technologies to offer solutions on the Java platform for development and deployment of server-side applications.

. . .

If we cut through the entire gamut of Java technologies that hold the promise of enabling the development of enterprise-wide business solutions, Java servlets (and JSPs), RMI and Enterprise JavaBeans emerge at the core of these technologies.

Java Servlets and JavaServer Pages
Java servlets play the role of access mechanisms to middle-tier services. They are a specific enhancement to the world of enterprise computing, not a Java layer on top of an existing service. The popularity of Java servlets is based on the premise that most enterprises are taking advantage of the thin-client environment made possible by the ubiquitous acceptance of the worldwide Web and the Internet. Under this model the Web server becomes enterprise middleware and is responsible for running applications for clients. Servlets are used primarily by Web servers as Java-based replacements for CGI scripts. They can access server-side APIs in a variety of ways ­ by sending and receiving e-mail, invoking methods on remote objects using RMI or CORBA, or by obtaining directory information via JNDI and using that information to invoke business services offered by EJBs.

JavaServer Pages are based on servlet technology and are currently poised as one of the most significant elements of dynamic content presentation in e-business applications.

JSPs combine markup (HTML or XML) languages with blocks of Java code to produce dynamic Web pages. Each of these pages is compiled into a servlet by the JSP engine the first time it's requested. Subsequent requests for the page use the compiled servlet. JSPs provide a variety of ways to talk to Java classes, servlets, applets and the Web server. Using JSPs, an application developer can split the functionality of a Web application into components with well-defined public interfaces. These components are contained in a single page. JSPs also have mechanisms that allow the application to leverage JavaBean components so as to present different data views to the Web browser. They facilitate the creation of front-end business components such as shopping carts and user profile managers.

Enterprise JavaBeans
Enterprise Java Beans form the core of Java enterprise computing. EJB defines how server-side components are written and provides standard contracts between components and application servers that manage them. EJB promotes the development of a component marketplace in the enterprise, where vendors can sell reusable components that can be purchased to help solve business problems. Thus EJBs offer business services in the form of APIs that may be accessed via a distributed object framework. This framework is offered by Java in the form of RMI.

The idea behind EJBs is to enable the creation of business services in the middle tier. The business objects defined via EJBs are responsible for accessing data from the end-server tier, processing it and making the results available to the presentation tier via RMI. If the presentation tier is accessed via a Web browser, servlets and JSPs are used to make the results available in HTML (or XML) format via a Web server.

Trading Places
When Java first emerged as a popular technology, its scope was more or less limited to the client. Client-side technologies were used to access server-side services via different protocols, depending on the programming environment. With the advent of J2EE, Java has firmly ensconced itself in the middle tier. In the new millennium we can hope to see further penetration of Java in various tiers of the enterprise.

About Ajit Sagar
Ajit Sagar is a principal architect with Infosys Technologies, Ltd., a global consulting and IT services company. Ajit has been working with Java since 1997, and has more than 15 years experience in the IT industry. During this tenure, he's been a programmer, lead architect, director of engineering, and product manager for companies from 15 to 25,000 people in size. Ajit has served as JDJ's J2EE editor, was the founding editor of XML Journal, and has been a frequent speaker at SYS-CON's Web Services Edge series of conferences, JavaOne, and international conference. He has published more than 125 articles.

In order to post a comment you need to be registered and logged in.

Register | Sign-in

Reader Feedback: Page 1 of 1

Enterprise Open Source Magazine Latest Stories . . .
Apache Deltacloud, the Red Hat-contributed ReSTful API that abstracts differences between clouds so services on any cloud can be managed – provided of course there’s a driver – has graduated from the Apache Foundation’s incubator and is now a full-fledged Top-Level Project (TLP). The...
With Cloud Expo 2012 New York (10th Cloud Expo) just four months away, what better time to start introducing you in greater detail to the distinguished individuals in our incredible Speaker Faculty for the technical and strategy sessions at the conference... We have technical and st...
AMD said late Tuesday that its chief sales officer Emilio Ghilardi had left the company and that CEO and president Rory Read is going to do his job while a replacement is sought. AMD didn’t say why Ghilardi left but it’s assumed Read wants his own people. Read is relatively new to th...
During the lifespan of M3 (Monitis Monitor Manager) there has always been something lacking – timers. M3 execution procedure was outlined in this previous article. The execution mentioned in the latter was a one-time-execution, whereas server monitoring requires periodic invocati...
Red Hat is putting its bought-in Gluster scale-out NAS storage technology, acquired in October, on the Amazon cloud. It’s styled Red Hat Virtual Storage Appliance for Amazon Web Services and other clouds are supposed to follow in short order.
A new episode of the screencast series is now available at the OpenNebula YouTube Channel. This screencast demonstrates the new easily-customizable self-service portal for cloud consumers. Its aim is to offer a simplified access to shared infrastructure for non-IT end users. The scree...
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021


SYS-CON Featured Whitepapers
ADS BY GOOGLE