Enterprise JavaBeans (3rd Edition)

Enterprise JavaBeans (3rd Edition)

$44.95

  • Release Date: 15 October, 2001
  • Used Price: $10.99
  • Availability: This item is currently not available.
  • Third Party Used Price: $13.85

Author: Richard Monson-Haefel

Similar Products

Core J2EE Patterns: Best Practices and Design Strategies, Second Edition

From $34.99:

Core J2EE Patterns: Best Practices and Design Strategies, Second Edition

Java Message Service (O'Reilly Java Series)

From $34.95:

Java Message Service (O'Reilly Java Series)

Programming Jakarta Struts

From $39.95:

Programming Jakarta Struts

Java Servlet Programming, 2nd Edition

From $29.67:

Java Servlet Programming, 2nd Edition

Expert One-on-One J2EE Design and Development (Programmer to Programmer)

From $59.99:

Expert One-on-One J2EE Design and Development (Programmer to Programmer)

Customer Rating: 4.45 of 5 (150 total reviews)

  • 4 starsGood book for jumping in

    All you need to jump in, for more details go for 'Special Edition Using Enterprise JavaBeans 2.0', rare case when O'Reilly's book is not a head above the rest. 'Special edition' is deepier and a better choice for advanced programmers.

  • 4 starsRecommended

    This book gives an excellent overview of Enterprise JavaBeans and their applications. At all times the author does an effective job of relating to the reader the concepts behind this new methodology. Even performance issues involved with the utilization of Enterprise JavaBeans is discussed briefly in the book and both versions 1.0 and 1.1 are covered. The reader is expected to be an expert in the Java programming language, and have familiarity with the JDBC API or SQL.

    The author begins Chapter 1 with an introduction to distributed objects, server-side components, and component transaction monitors (application servers). Enterprise JavaBeans is defined as a server-side component model for component transaction monitors. The standard 3-tier architecture is illustrated, along with definitions of stub and skeleton, and the RMI protocol. Effective diagrams and Java source code are used to describe the distributed object model. The chapter ends with a defense of using server-side components and the author employs an imaginary business application as an illustration of the concepts. This example is expanded upon throughout the rest of the book.

    The architecture of EJB is covered in Chapter 2, with entity beans and session beans the two main components. The author carefully distinguishes between these two bean types. The remote interface, the home interface, the bean class, and the primary key are all described in detail and the author shows how to build a bean with relevant Java code. Deployment descriptors, which enable customization of software behavior at runtime, and JAR files, used for packaging Java classes, are both treated in detail. The author is careful also to distinguish the differences between 1.0 and 1.1.

    The resource management capability of component transaction monitors are discussed in the next chapter. Application performance is critically dependent on this capability, and the author stresses the benefits of using EJB servers to meet the heavy load requirements while still maintaining optimum performance. State transition diagrams are effectively employed to explain instance swapping, the activation mechanism, concurrency, and persistence of beans. Security of EJB is also discussed with authentication, access control, and secure communication being supported.

    In the next chapter the example business application is used to guide the reader through the actual development of an entity bean and a session bean. Again, two different versions of the beans are developed, depending on whether 1.0 or 1.1 is used.

    JNDI is used in the next chapter to give an overview of beans from the clients perspective, and allows the application to view the EJB server as a collection of directories. After locating and obtaining the remote reference to the EJB home using JDNI, a remote reference to the bean can then be obtained. State transition diagrams are again employed to illustrate the Java RMI serialization and remote reference.

    The author returns to a more detailed discussion of entity beans in Chapter 6. He outlines the advantages of using entity beans instead of accessing the database directly. Container-managed and bean-managed persistence are thoroughly treated, and the author shows how Create methods come into play for both of these beans. A nice state transition diagram is given for the life cycle of an entity bean along with a detailed description on what causes transitions among the different states.

    Session beans are then the topic of Chapter 7, and the author discusses when to use session beans versus entity beans. In addition, the other properties of session beans are discussed and the lifecycles of both a stateless session bean and a stateful session are given in terms of state transition diagrams.

    Transactions are discussed in the next chapter, with the concept of declarative transaction management discussed, which allows the transactional behavior to be controlled using the deployment descriptor. The author details the advantages of employing declarative transaction management. Effective diagrams are employed to illustrate transaction attributes. In addition, isolation and database locking is discussed in detail along with explicit transaction management. The later is used with the Java Transaction API used by EJB to deal explicitly with transactions. A very useful state transition diagram is given for the transactional stateful session bean.

    The next two chapters are written from a design perspective, and discuss how to solve particular design problems, working with specific databases, and XML deployment descriptors. These chapters are specialized discussions and are geared toward those who are actually involved in the designing and coding of EJB applications. The author does address how to improve performance with session beans, treating in particular the network traffic and latency issues, and resource consumption. Method calls on a remote reference will initiate a remote method invocation loop, which will send streamed data from the stub to the server and then back to the stub, and thus consume bandwidth. Network traffic will mushroom as more clients create more beans, update their states, and request information. Reducing the EJB network traffic is a challenge to the application developer and many proposals have been given on the Web and in the literature for how to best do this. Network modelers have to pay particular attention to these issues when EJB is being deployed in an application to be run over a network.

    The last chapter covers the J2EE with discussions of servlets, application client components, and connectivity.

    There are very useful appendices inserted at the end, especially Appendix B, which gives the state and sequence UML diagrams for all of the bean types discussed in the book. Appendix D is also useful since it discusses the new features available in EJB 1.1.

  • 5 starsRequired reading

    We have been using this book on a large EJB project and have been very happy with it. Monson-Haefel addresses the most complex parts of the EJB platform with a style that makes the book enjoyable to read and EJB fairly easy to learn.

    The first three chapters of the book explain the purpose, architecture, and implementation of EJB servers. This really helps our people to understand what was going on under the hood and why beans behave the way they do. Without this material, EJB would be a mysterious black box. We now understand EJB at it lowest levels, which makes our people more productive.

    The rest of the book provides a detailed explanation of how to develop each kind of bean (stateless, stateful, and entity beans) using an example application. As the book proceeds it builds on the example increasing the complexity incrementally. What's especially appealing is that example is not so large that it's distracting. The book is very focused and the examples add rather then detract from the book.

    One of the books greatest strengths is the way it covers Enterprise JavaBeans in detail. Chapter 8, for example, goes into detail about transactions, database locking, isolation levels, and how transactions are propagated. In addition, the same chapter explains how exceptions impact transactions -- a very real issue when developing large-scale projects.

    There is also a great chapter on "design strategies" which introduces ideas like the business interface and bulk accessors. While these designs strategies are invaluable to our project, we would like to see a lot more of them. In particular a section on design patterns in EJB would be very helpful. Hopefully this kind of material will be added in a future edition.

    EJB is fairly complex, so a good book like this one is a gold mine. We now have about 20 developers working on our EJB project. Every time we add a developer to our project, they are handed a new copy of this book and told to read it. Without out this book most of our new developers would be hopelessly lost. If you are going to use EJB in your project, then you absolutely must have this book -- its essential.