close

Head First EJB

Head First EJB

With Head First EJB, you'll learn not just what the technology *is*, but more importantly, *why* it is, and what it is and isn't good for. You'll learn tricks and tips for EJB development, along with tricks and tips for passing this latest, very challenging Sun Certified Business Component Developer (SCBCD) exam. You'll learn how to think like a server. You'll learn how to think like a bean. And because this is a Head First book, you'll learn how to think about thinking... And nobody knows the certification like they do—they're co-developers of Sun's actual exam! In Head First EJB, you'll learn all about:
  • Component-based and role-based development
  • The architecture of EJB, distributed programming with RMI
  • Developing and Deploying an EJB application
  • The Client View of a Session and Entity bean
  • The Session Bean Lifecycle and Component Contract
  • The Entity bean Lifecycle and Component Contract
  • Container-managed Persistence (CMP)
  • Container-managed Relationships (CMR)
  • EJB-QL
  • Transactions
  • Security
  • EJB Exceptions
  • The Deployment Descriptor
  • The Enterprise Bean Environment in JNDI
  • Programming Restrictions and Portability

A collection of images from inside the book.

What you need for this book

Besides your brain and a pencil, you need Java, J2EE and a computer.

You do not need any other development tool, such as an Integrated Development Environment (IDE). We strongly recommend that you not use anything but a basic editor until you complete this book. A bean-aware IDE can protect you from some of the details that really matter (and that you'll be tested on), so you're much better off developing the bean code completely by hand. Once you really understand what's happening, you can move to a tool that automates some of the bean-creation steps. We do recommend that you use a tool to build the XML deployment descriptor. You can use the j2EE Reference Implementation deploytool, or xDoclet.

Getting J2EE

  • If you don't already have a 1.3 or greater J2SE SDK, you need it. Although J2EE is not guaranteed to work with J2SE version 1.4 or beyond, you shouldn't have problems with J2SE 1.4. But the spec guarantees ONLY J2SE 1.3 support. (You might be tested on that!)
  • If you don't already have an EJB 2.0-compliant server, go to java.sun.com and download J2EE 1.3. It includes the JAR file with the entire J2EE API (including the classes you'll need for EJB development), and a practice Reference Implementation (RI) server. Do not get the new J2EE 1.4! The exam is based on J2EE 1.3, because 1.4 is too early in its life to be in widespread use in business. We expect that very few enterprise systems will migrate to J2EE 1.4 until late 2004 at the earliest. When J2EE 1.4 support hits critical mass, the exam will be upgraded to the new spec.
  • The J2EE SDK does not include the API documentation, and you need it. Go back to java.sun.com and get the J2EE API docs. You can also access the API docs online, without downloading them, but that's a pain. Once you've downloaded and unpacked/zipped/whatever (depends on which version and for which OS), you need to add a few environment variables, if you're going to use the J2EE RI as your practice server. The download includes instructions, but expect to modify your PATH and CLASSPATH, and add new entries for J2EE_HOME and JAVA_HOME.
  • If you're going to take the exam, you're gonna need the spec. Download the EJB 2.0 (not 2.1!) specification and keep it handy. There is nothing on the exam that isn't mentioned in the spec. Most of our mock exam answers reference specific pages in the spec, where you can go to learn more about why you might have missed that question.

Last-minute things you need to know:

We use simple UML-like diagrams.

Although there's a good chance you already know UML, it's not covered on the exam, and it's not a prerequisite for the book. So you won't have to worry about learning EJB and UML at the same time.

We don't cover every single picky detail from the spec.

The exam is pretty detailed, though, and so are we. But if there's a detail in the spec that's not covered in the exam, we don't talk about it unless it's important to most component developers. What you need to know to begin developing EJB components, and what you need to pass the exam, overlap about 95%. We cover a few things not on the exam, but we point them out so you don't have to try to memorize them. And there is a very tiny percentage of details that might show up on the exam, but that we haven't covered in detail. We created the real exam, so we know where you should focus your energy! If there's a chance that this one picky detail might be on one question on the exam, but the effort to learn it isn't really worth it, we might skip it, or cover it only very lightly, or only in a mock exam question.

Extras

Review Quotes

The book includes over 200 mock exam questions that match the tone, style, difficulty, and topics on the real SCBCD exam. See why Kathy and Bert are responsible for thousands of successful exam-passers!

"The Sun certification exam was certainly no walk in the park, but Kathy's material allowed me to not only pass the exam, but Ace it!"
—Mary Whetsel, Sr. Technology Specialist, Application Strategy and Integration, The St. Paul Companies

"Kathy Sierra and Bert Bates are two of the few people in the world who can make complicated things seem damn simple, and as if that isn't enough, they can make boring things seem interesting."
—Paul Wheaton, The Trail Boss, javaranch.com

"Who better to write a Java study guide than Kathy Sierra, reigning queen of Java instruction? Kathy Sierra has done it again. Here is a study guide that almost guarantees you a certification!"
—James Cubetta, Systems Engineer, SGI

 

Order
(opens a new window)

Read it on Safari


(opens a new window)

Buy 2 books, get 1 free!

Buy 2 books and get the third free! Use the coupon code OPC10 when you check out.

Free Downloads
Who is this book for?

If you can answer "yes" to all of these:

  • Do you know Java? (You don't need to be a guru.)
    (You'll probably be Ok if you know C# instead.)
  • Do you want to learn, understand, and remember EJB, with a goal of passing the SCBCD exam and developing business components?
  • Do you prefer stimulating dinner party conversation to dry, dull, academic lectures?

You should probably back away from this book if you can answer "yes" to any of these:

  • Are you completely new to Java?
    (You don't need to be advanced, but you should have some experience. If not, go get a copy of Head First Java, right now, today, and then come back and get this book. )
  • Are you a kick-butt Java developer looking for an EJB reference book?
  • Are you a J2EE veteran looking for ultra-advanced server techniques, server-specific how-to's, enterprise design patterns, and long, complex, robust real-world code?
  • Are you afraid to try something different? Would you rather have a root canal than mix stripes with plaid? Do you believe that a technical book can't be serious if Java components are anthropomorphized?

Also by Kathy Sierra & Bert Bates

Head First Java

Head First Java

Head First Design Patterns

Head First Design Patterns