23.2.5. Assign Bean Pools for Session and Message-Driven Beans
slsb-strict-max-pool and mdb-strict-max-pool for stateless session beans and message-driven beans respectively.
Procedure 23.7. Assign Bean Pools for Session and Message-Driven Beans using the Management Console
- Login to the Management Console. Section 3.4.2, “Log in to the Management Console”
- Click on the tab at the top of the screen. Expand the menu and select . Select the tab.
- Click .
- Select the bean pool to use for each type of bean from the appropriate combo-box.
- Click to finish.
Procedure 23.8. Assign Bean Pools for Session and Message-Driven Beans using the CLI
- Launch the CLI tool and connect to your server. Refer to Section 3.5.4, “Connect to a Managed Server Instance Using the Management CLI”.
- Use the
write-attributeoperation with the following syntax./subsystem=ejb3:write-attribute(name="BEANTYPE", value="BEANPOOL")
- Replace BEANTYPE with
default-mdb-instance-poolfor Message-Driven Beans ordefault-slsb-instance-poolfor stateless session beans. - Replace BEANPOOL with the name of the bean pool to assign.
- Use the
read-resourceoperation to confirm the changes./subsystem=ejb3:read-resource
Example 23.5. Assign a Bean Pool for Session Beans using the CLI
[standalone@localhost:9999 /] /subsystem=ejb3:write-attribute(name="default-slsb-instance-pool", value="LV_SLSB_POOL")
{"outcome" => "success"}
[standalone@localhost:9999 /]Example 23.6. XML Configuration Sample
<subsystem xmlns="urn:jboss:domain:ejb3:1.2">
<session-bean>
<stateless>
<bean-instance-pool-ref pool-name="slsb-strict-max-pool"/>
</stateless>
<stateful default-access-timeout="5000" cache-ref="simple"/>
<singleton default-access-timeout="5000"/>
</session-bean>
<mdb>
<resource-adapter-ref resource-adapter-name="hornetq-ra"/>
<bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>
</mdb>
</subsystem>
Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.