Skip to Main Content
Enterprise JavaBeans, Second Edition
book

Enterprise JavaBeans, Second Edition

by Richard Monson-Haefel
September 2001
Intermediate to advanced content levelIntermediate to advanced
489 pages
14h 44m
English
O'Reilly Media, Inc.
Content preview from Enterprise JavaBeans, Second Edition

The ejb-jar File

The JAR file format is a platform-independent format for compressing, packaging, and delivering several files together. Based on ZIP file format and the ZLIB compression standards, the JAR ( Java archive) packages and tool were originally developed to make downloads of Java applets more efficient. As a packaging mechanism, however, the JAR file format is a very convenient way to “shrink-wrap” components and other software for delivery to third parties. The original JavaBeans component architecture depends on JAR files for packaging, as does Enterprise JavaBeans. The goal in using the JAR file format in EJB is to package all the classes and interfaces associated with one or more beans, including the deployment descriptor, into one file.

The JAR file is created using a vendor-specific tool, or using the jar utility that is part of the Java 2, Standard Edition development kit. An ejb-jar file contains:

  • The XML deployment descriptor

  • The bean classes

  • The remote and home interfaces

  • The primary key class

  • Dependent classes and interfaces

The XML deployment descriptor must be located in the path META-INF/ejb-jar.xml, and must contain all the deployment information for all the beans in the ejb-jar file. For each bean declared in the XML deployment descriptor, the ejb-jar file must contain its bean class, remote and home interfaces, and dependent classes and interfaces. Dependent classes and interfaces are usually things like application-specific exceptions, business interfaces, ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Enterprise JavaBeans, Third Edition

Enterprise JavaBeans, Third Edition

Richard Monson-Haefel
Enterprise JavaBeans, Fourth Edition

Enterprise JavaBeans, Fourth Edition

Sacha Labourey, Bill Burke, Richard Monson-Haefel
Enterprise JavaBeans 3.0, 5th Edition

Enterprise JavaBeans 3.0, 5th Edition

Richard Monson-Haefel, Bill Burke
Enterprise JavaBeans 3.1, 6th Edition

Enterprise JavaBeans 3.1, 6th Edition

Andrew Lee Rubinger, Bill Burke

Publisher Resources

ISBN: 1565928695Supplemental ContentCatalog PageErrata