EJB.C.6 Changes Since EJB.1.1 Draft 2


Fix an error in the requirement for how a container must deal with inter-EJB invocations when both the calling and called beans are in the same JVM. The correct requirement is that the RMI semantics must be ensured, and therefore the container must not pass non-remote objects by reference.

Clarified the requirements for serialization of the session objects.

Specified that an EJB compliant container may always return a null from the deprecated getCallerIdentity() method.

Added a section on distributed transaction scenarios involving access to the same entity from multiple clients in the same transaction.

Changed the specification of the return value type of the ejbCreate(...) methods for entities with container-managed persistence. The previous specification required that the ejbCreate methods are defined as returning void. The new requirement is that the ejbCreate methods be defined as returning the primary key class type. The implementation of the ejbCreate method should return null. This change is to allow tools, if they wish, to create an entity bean with bean-managed persistence by subclassing an original entity bean with container-managed persistence.

For compatibility with EJB 1.0, added the support for the java.rmi.RemoteException to be thrown from the enterprise bean class methods. This is needed to allow an EJB 1.1 container to support enterprise beans written to the EJB 1.0 specification. The use of the java.rmi.RemoteException in the enterprise bean class methods is deprecated, and new applications should throw the javax.ejb.EJBException instead.

Removed the deprecated package javax.ejb.deployment from the EJB interfaces. The deprecated package javax.ejb.deployment will be distributed only with the deployment descriptor conversion tool.

Updated the examples in the transaction chapter by removing the setAutoCommit and setTransactionIsolation calls. These calls are not typically done by the enterprise bean.

Added the <method-intf> element to allow a method element to differentiate between methods with same signature when defined in both the remote and home interfaces.

Specified the behavior of the getUserTransaction() , setRollbackOnly() , and getRollbackOnly() methods for the cases when the methods are invoked by beans that are not allowed to use these methods. The container will throw the java.lang.IllegalException in these situations.

Specified that PortableRemoteObject.narrow(...) must be used by a client to convert the result of Handle.getEJBObject() to the remote interface type.

Required portable enterprise bean clients to use the PortableRemoteObject.narrow(...).

Clarified the minimal lifetime for handles.

Clarified that the caller must have at least one security role (not all ) associated with the method permission in order to be allowed to invoke the method.

Support for entities has been made mandatory for the container provider.

Added a section to the Exception chapter dealing with the release of resources held by the instance when the instance is being discarded because of a system exception.

Added the res-auth element to the deployment descriptor for the bean provider to indicate whether the bean code performs an explicit signon to a resource manager, or whether the bean relies on the container to perform signon based on the information supplied by deployer.

Added java.io.Serializable as a superinterface of javax.ejb.Handle . The EJB 1.0 spec required that the implementation class implements the java.io.Serializable interface; this change expresses the requirement syntactically.

Added the interface javax.ejb.HomeHandle to provide support for handles for home objects.

Allowed a session bean instance to be removed upon a timeout while the instance is in the passivated state.

Add the javax.ejb.NoSuchEntityException exception to the API. Added requirements for throwing the java.rmi.NoSuchObjectExcetion to the chapter on exceptions.



Java 2 Platform, Enterprise Edition. Platform and Component Specifications
Java 2 Platform, Enterprise Edition: Platform and Component Specifications
ISBN: 0201704560
EAN: 2147483647
Year: 2000
Pages: 399

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net