An Enterprise JavaBeans(EJB) container is used to provide a run-time environment for enterprise beans within the application server. The container handles operation of EJBs and also act as an intermediary between business logic layer and the rest of the Java EE environment. In Geronimo, OpenEJB is included as a plugin to manage EJBs.
The EJB Server
portlet that displays the EJB containers available in the server and their status is available by selecting EJB Server on the Console Navigation menu on the left hand side. You will be also presented with all the EJBs that the container is holding. The following figures illustrate the portlet layout.
Stateful Container
Configuring
In the the config.xml, find the "EJBNetworkService" gbean and add this gbean next to it:
<gbean name="DefaultStatefulContainer"> <attribute name="properties"> TimeOut=20 PoolSize=1000 BulkPassivate=100 </attribute> </gbean>
Properties
Each property is as follows:
Property Name |
Description |
---|---|
TimeOut |
Specifies the time to wait between invocations. This |
PoolSize |
Specifies the size of the bean pools for this |
BulkPassivate |
Property name that specifies the number of instances |
Stateless Container
Configuring
In the the config.xml, find the "EJBNetworkService" gbean and add this gbean next to it:
<gbean name="DefaultStatelessContainer"> <attribute name="properties"> TimeOut=0 PoolSize=10 StrictPooling=true </attribute> </gbean>
Properties
Each property is as follows:
Property Name |
Description |
---|---|
TimeOut |
Specifies the time to wait between invocations. This |
PoolSize |
Specifies the size of the bean pools for this |
StrictPooling |
StrictPooling tells the container what to do when the pool |