Bean Provider's Responsibilities

From
Revision as of 12:40, 1 December 2004 by Bayarkhuu (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

The Bean Provider is responsible for providing the structural information for each enterprise bean in the deployment descriptor.

The Bean Provider must use the enterprise-beans element to list all the enterprise beans in the ejb-jar file.

The Bean Provider must provide the following information for each enterprise bean:

  • Enterprise bean’s name. The Bean Provider must assign a logical name to each enterprise bean in the ejb-jar file. There is no architected relationship between this name and the JNDI name that the Deployer will assign to the enterprise bean. The Bean Provider specifies the enterprise bean’s name in the ejb-name element.
  • Enterprise bean’s class. The Bean Provider must specify the fully-qualified name of the Java class that implements the enterprise bean’s business methods. The Bean Provider specifies the enterprise bean’s class name in the ejb-class element.
  • Enterprise bean’s remote home interface. The Bean Provider must specify the fully-quali-fied name of the enterprise bean’s remote home interface, if any, in the home element.
  • Enterprise bean’s remote interface. The Bean Provider must specify the fully-qualified name of the enterprise bean’s remote interface, if any, in the remote element.
  • Enterprise bean’s local home interface. The Bean Provider must specify the fully-qualified name of the enterprise bean’s local home interface, if any, in the local-home element.
  • Enterprise bean’s local interface. The Bean Provider must specify the fully-qualified name of the enterprise bean’s local interface, if any, in the local element.
  • Enterprise bean’s web service endpoint interface. The Bean Provider must specify the fully-qualified name of the enterprise bean’s web service endpoint interface, in any, in the service-endpoint element. This element may only be used for stateless session beans.
  • Enterprise bean’s type. The enterprise bean types are: session, entity, and message-driven. The Bean Provider must use the appropriate session, entity, or message-driven element to declare the enterprise bean’s structural information.
  • Re-entrancy indication. The Bean Provider must specify whether an entity bean is re-entrant or not. Session beans and message-driven beans are never re-entrant.
  • Session bean’s state management type. If the enterprise bean is a session bean, the Bean Provider must use the session-type element to declare whether the session bean is stateful or stateless.
  • Session or message-driven bean’s transaction demarcation type. If the enterprise bean is a session bean or message-driven bean, the Bean Provider must use the transaction-type element to declare whether transaction demarcation is performed by the enterprise bean or by the container.
  • Entity bean’s persistence management. If the enterprise bean is an entity bean, the Bean Provider must use the persistence-type element to declare whether persistence management is performed by the enterprise bean or by the container.
  • Entity bean’s primary key class. If the enterprise bean is an entity bean, the Bean Provider specifies the fully-qualified name of the entity bean’s primary key class in the prim-key-class element. The Bean Provider must specify the primary key class for an entity with bean-managed persistence.
  • Entity bean’s abstract schema name. If the enterprise bean is an entity bean with container-managed persistence and cmp-version 2.x, the Bean Provider must specify the abstract schema name of the entity bean using the abstract-schema-name element.
  • Container-managed fields. If the enterprise bean is an entity bean with container-managed persistence, the Bean Provider must specify the container-managed fields using the cmp-field elements.
  • Container-managed relationships. If the enterprise bean is an entity bean with container-managed persistence and cmp-version 2.x, the Bean Provider must specify the container-managed relationships of the entity bean using the relationships element.
  • Finder and select queries. If the enterprise bean is an entity bean with container-managed persistence and cmp-version 2.x, the Bean Provider must use the query element to specify any EJB QL finder or select query for the entity bean other than a query for the findByPrimaryKey method.
  • Environment entries. The Bean Provider must declare all the enterprise bean’s environment entries as specified.
  • Resource manager connection factory references. The Bean Provider must declare all the enterprise bean’s resource manager connection factory references as specified.
  • Resource environment references. The Bean Provider must declare all the enterprise bean’s references to administered objects that are associated with resources as specified in Subsection.
  • EJB references. The Bean Provider must declare all the enterprise bean’s references to the remote homes of other enterprise beans as specified in Subsection.
  • EJB local references. The Bean Provider must declare all the enterprise bean’s references to the local homes of other enterprise beans as specified in Subsection.
  • Web service references. The Bean Provider must declare all the enterprise bean’s references to web service interfaces as specified in Subsection.
  • Message destination references. The Bean Provider must declare all the enterprise bean’s references to message destinations as specified in Subsection.
  • Security role references. The Bean Provider must declare all the enterprise bean’s references to security roles as specified in Subsection.
  • Message-driven bean’s configuration properties. The Bean Provider may provide input to the Deployer as to how a message-driven bean should be configured upon activation in its operational environment. Activation configuration properties for a JMS message-driven bean include information about a bean’s intended destination type, its message selector, and its acknowledgement mode. Other bean types may make use of different properties.
  • Message-driven bean’s destination. The Bean Provider may provide advice to the Application Assembler as to the destination type to which a message-driven bean should be assigned when linking message destinations.

The deployment descriptor produced by the Bean Provider must conform to the XML Schema defintion the DTD definition from a previous version of this specification. The content of the deployment descriptor must conform to the semantics rules specified in the XML Schema or DTD comments and elsewhere in this specification.