ejb 2.0-fr ejb-2 0-fr2-spec, work, e-books, od włodara
[ Pobierz całość w formacie PDF ]
microsystems
Sun Microsystems
Enterprise JavaBeans
TM
Specification,
Version 2.0
This is the specification of the Enterprise JavaBeans
TM
architecture. The Enterprise JavaBeans
architecture is a component architecture for the development and deployment of component-
based distributed business applications. Applications written using the Enterprise JavaBeans
architecture are scalable, transactional, and multi-user secure. These applications may be writ-
ten once, and then deployed on any server platform that supports the Enterprise JavaBeans
specification.
EJB 2.0 Architects:
Linda G. DeMichiel,
Specification Lead
L. Ümit Yalçinalp
Sanjeev Krishnan
Please send technical comments on this specification to:
ejb-spec-comments@eng.sun.com
Version 2.0, Final Release
August 14, 2001
Enterprise JavaBeans 2.0, Final Release
Sun Microsystems, Inc.
Enterprise Java Beans (TM) Specification ("Specification")
Version: 2.0
Status: Final Release
Release: August 22, 2001
Copyright
Sun Microsystems, Inc.
901 San Antonio Road, Palo Alto, California 94303, U.S.A.
All rights reserved.
ã 2001
NOTICE
The Specification is protected by copyright and the information described therein may be protected by
one or more U.S. patents, foreign patents, or pending applications. Except as provided under the follow-
ing license, no part of the Specification may be reproduced in any form by any means without the prior
written authorization of Sun Microsystems, Inc. ("Sun") and its licensors, if any. Any use of the Speci-
fication and the information described therein will be governed by the terms and conditions of this license
and the Export Control and General Terms as set forth in Sun’s website Legal Terms. By viewing, down-
loading or otherwise copying the Specification, you agree that you have read, understood, and will com-
ply with all of the terms and conditions set forth herein.
Sun hereby grants you a fully-paid, non-exclusive, non-transferable, worldwide, limited license (without
the right to sublicense), under Sun’s intellectual property rights that are essential to practice the Specifi-
cation, to internally practice the Specification solely for the purpose of creating a clean room implemen-
tation of the Specification that: (i) includes a complete implementation of the current version of the
Specification, without subsetting or supersetting; (ii) implements all of the interfaces and functionality
of the Specification, as defined by Sun, without subsetting or supersetting; (iii) includes a complete im-
plementation of any optional components (as defined by Sun in the Specification) which you choose to
implement, without subsetting or supersetting; (iv) implements all of the interfaces and functionality of
such optional components, without subsetting or supersetting; (v) does not add any additional packages,
classes or interfaces to the "java.*" or "javax.*" packages or subpackages (or other packages defined by
Sun); (vi) satisfies all testing requirements available from Sun relating to the most recently published ver-
sion of the Specification six (6) months prior to any release of the clean room implementation or upgrade
thereto; (vii) does not derive from any Sun source code or binary code materials; and (viii) does not in-
clude any Sun source code or binary code materials without an appropriate and separate license from
Sun. The Specification contains the proprietary information of Sun and may only be used in accordance
with the license terms set forth herein. This license will terminate immediately without notice from Sun
if you fail to comply with any provision of this license.
Upon termination or expiration of this license,
you must cease use of or destroy the Specification.
TRADEMARKS
No right, title, or interest in or to any trademarks, service marks, or trade names of Sun or Sun’s licensors
is granted hereunder. Sun, Sun Microsystems, the Sun logo, Java, J2EE, Enterprise JavaBeans, EJB, JD-
BC, Java Naming and Directory Interface, "Write Once Run Anywhere", Java ServerPages, JDK, Java-
Beans, and the Java Coffee Cup are trademarks or registered trademarks of Sun Microsystems, Inc. in
the U.S. and other countries.
2
8/14/01
Enterprise JavaBeans 2.0, Final Release
Sun Microsystems, Inc.
DISCLAIMER OF WARRANTIES
THE SPECIFICATION IS PROVIDED "AS IS". SUN MAKES NO REPRESENTATIONS OR WAR-
RANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRAN-
TIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-
INFRINGEMENT THAT THE CONTENTS OF THE SPECIFICATION ARE SUITABLE FOR ANY
PURPOSE OR THAT ANY PRACTICE OR IMPLEMENTATION OF SUCH CONTENTS WILL
NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADE SECRETS OR OTHER
RIGHTS. This document does not represent any commitment to release or implement any portion of the
Specification in any product.
THE SPECIFICATION COULD INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL
ERRORS. CHANGES ARE PERIODICALLY ADDED TO THE INFORMATION THEREIN;
THESE CHANGES WILL BE INCORPORATED INTO NEW VERSIONS OF THE SPECIFICA-
TION, IF ANY. SUN MAY MAKE IMPROVEMENTS AND/OR CHANGES TO THE PRODUCT(S)
AND/OR THE PROGRAM(S) DESCRIBED IN THE SPECIFICATION AT ANY TIME. Any use of
such changes in the Specification will be governed by the then-current license for the applicable version
of the Specification.
LIMITATION OF LIABILITY
TO THE EXTENT NOT PROHIBITED BY LAW, IN NO EVENT WILL SUN OR ITS LICENSORS
BE LIABLE FOR ANY DAMAGES, INCLUDING WITHOUT LIMITATION, LOST REVENUE,
PROFITS OR DATA, OR FOR SPECIAL, INDIRECT, CONSEQUENTIAL, INCIDENTAL OR PU-
NITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF LIABILI-
TY, ARISING OUT OF OR RELATED TO ANY FURNISHING, PRACTICING, MODIFYING OR
ANY USE OF THE SPECIFICATION, EVEN IF SUN AND/OR ITS LICENSORS HAVE BEEN AD-
VISED OF THE POSSIBILITY OF SUCH DAMAGES.
You will indemnify, hold harmless, and defend Sun and its licensors from any claims arising or resulting
from: (i) your use of the Specification; (ii) the use or distribution of your Java application, applet and/or
clean room implementation; and/or (iii) any claims that later versions or releases of any Specification
furnished to you are incompatible with the Specification provided to you under this license.
RESTRICTED RIGHTS LEGEND
U.S. Government: If this Specification is being acquired by or on behalf of the U.S. Government or by
a U.S. Government prime contractor or subcontractor (at any tier), then the Government’s rights in the
Software and accompanying documentation shall be only as set forth in this license; this is in accordance
with 48 C.F.R. 227.7201 through 227.7202-4 (for Department of Defense (DoD) acquisitions) and with
48 C.F.R. 2.101 and 12.212 (for non-DoD acquisitions).
REPORT
You may wish to report any ambiguities, inconsistencies or inaccuracies you may find in connection with
your evaluation of the Specification ("Feedback"). To the extent that you provide Sun with any Feed-
back, you hereby: (i) agree that such Feedback is provided on a non-proprietary and non-confidential ba-
sis, and (ii) grant Sun a perpetual, non-exclusive, worldwide, fully paid-up, irrevocable license, with the
right to sublicense through multiple levels of sublicensees, to incorporate, disclose, and use without lim-
itation the Feedback for any purpose related to the Specification and future versions, implementations,
and test suites thereof.
(LFI#95239/Form ID#011801)
3
8/14/01
Enterprise JavaBeans 2.0, Final Release
Sun Microsystems, Inc.
4
8/14/01
Sun Microsystems, Inc.
Enterprise JavaBeans 2.0, Final Release
Table of Contents
Chapter 1
Introduction.................................................................................................................... 25
1.1
Target audience ................................................................................................ 25
1.2
What is new in EJB 2.0 ................................................................................... 25
1.3
Acknowledgments ........................................................................................... 26
1.4
Organization .................................................................................................... 27
1.5
Document conventions .................................................................................... 28
Chapter 2
Goals .............................................................................................................................. 29
2.1
Overall goals.................................................................................................... 29
2.2
EJB Releases 1.0 and 1.1................................................................................. 30
2.3
Goals for Release 2.0....................................................................................... 30
Chapter 3
EJB Roles and Scenarios ............................................................................................... 33
3.1
EJB Roles ........................................................................................................ 33
3.1.1
Enterprise Bean Provider .................................................................. 34
3.1.2
Application Assembler...................................................................... 34
3.1.3
Deployer ............................................................................................ 34
3.1.4
EJB Server Provider .......................................................................... 35
3.1.5
EJB Container Provider..................................................................... 35
3.1.6
System Administrator ....................................................................... 36
3.2
Scenario: Development, assembly, and deployment ....................................... 36
Chapter 4
Overview ........................................................................................................................ 41
4.1
Enterprise Beans as components ..................................................................... 41
4.1.1
Component characteristics ................................................................ 41
4.1.2
Flexible component model ................................................................ 42
4.2
Enterprise JavaBeans contracts........................................................................ 43
4.2.1
Client-view contracts for session beans and entity beans ................. 43
4.2.2
Component contract .......................................................................... 44
4.2.3
Ejb-jar file ......................................................................................... 46
4.2.4
Contracts summary ........................................................................... 46
4.3
Session, entity, and message-driven objects .................................................... 47
4.3.1
Session objects .................................................................................. 48
4.3.2
Entity objects..................................................................................... 48
4.3.3
Message-driven objects ..................................................................... 48
4.4
Standard mapping to CORBA protocols ......................................................... 49
Chapter 5
Local and Remote Client Views..................................................................................... 51
5.1
Overview ......................................................................................................... 51
5.2
Remote Clients ................................................................................................ 52
5
8/14/01
[ Pobierz całość w formacie PDF ]