UK Sales: 0800 035 6364 | sales@2020media.com | We'll Call You

Introduction to EJB

Notice

This is a personal view of EJB and the Java Enterprise Platform (J2EE). I expect that is does not nearly cover the scope of these technologies or bring out the many applications in which they could be used. However I have found it difficult to find concise descriptions of the beneifts of EJB and J2EE and I hope this brief introduction may at least spark some ideas and further Interest.

General

Most business systems (and many others) can be viewed as a number of transactions between different components of the business. For example buying a ticket involves a transaction from the request to the seller, which then could cause multiple transations to stock control, accounts etc. Each of these transactions and the items that they work on can be represented by Enterprise JavaBeans, and the environment in which they work is J2EE.

Enterprise Beans

Enterprise beans come in two flavours: entity beans and session beans. Typically entity beans represent ideas that can be expressed as nouns - a customer, an item, a place, or any other 'real-world' object. On the other hand session beans tend to manage 'transactions' - the process of buying a ticket,

Enterprise Platform

The environment in which these beans exist provides much of the power of the whole concept. Entity beans (which represent real-world objects) are 'persistant' - they need to maintain state - and the platform provides a variety of mechanisms for easily storing this state. Session beans doesn't retain state, but needs to manage transations - this involves the ability to recover from particular functions that might not suceed. For example, two ticking buying processes might be competing for the last seat - one of these processes will need to abort the transaction and recover any state changes back to their origional states. The platform also provides mechanisms for this.

The Big Winner

All the above things can be implemented reasonably well in other systems - where J2EE wins is in the scaleability of the system. Object pooling, location independence and flexibility mean that systems can be build that will handle huge number of transactions reliably. Objects can be seamless distributed between multiple servers.

Finding Out More

Books

Enterprise JavaBeans by Richard Monson-Haefel Published by O'Reilly & Associates 1999 ISBN 1-56592-605-6
Java 2 Platform, Enterprise Edition by Bill Shannon et al. Published by Addison-Wesley 2000 ISBN 0-201-70456-0

Web Sites

http://www.java.sun.com/products/ejb/index.html

Comments

Did you find this information useful? Let me have your feedback.

2020Media is a leading provider of small business Wi-Fi hotspots. If you want to offer free Wi-Fi to your customers or users, our service could be exactly what you are looking for. Our Hotspots are managed in the cloud, ultra-reliable and give you loads of information about behaviour patterns of your users. Read More   Read more...
2020Media introduces Moodle Hosting - UK servers and UK Moodle experts setup your site ready to use. Read more...
Special Offer for Longer Registration Periods Register or renew a .com, .net or .org domain name for 5 years we'll include 1 year free*. Read more...
2020Media is now offering zero-click installation of the popular TYPO3 content management system. Read more...

Our blog is regularly updated with news, tips and industry opinion.

Clients

  • AggieWestons
  • baker-and-mckenzie
  • arts-council-england
  • Big Finish
  • barratt-developments-logo
  • City-of-Lincoln-council-logo
  • brora-logo
  • DenisMacShane
  • Construction-Industry-Council
  • colchester