23.3.4. Edit a Thread Pool
Procedure 23.13. Edit a Thread Pool 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.
- Select the thread pool you want to edit.
- Click .
- Edit the details you want to change. Only the
Thread Factory,Max Threads,Keepalive Timeout, andKeepalive Timeout Unitvalues can be edited. - Click to finish.
Procedure 23.14. Edit a thread pool 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 for each attribute of the thread pool to be changed./subsystem=ejb3/thread-pool=THREADPOOLNAME:write-attribute(name="ATTRIBUTE", value="VALUE")
- Replace THREADPOOLNAME with the name of the thread pool.
- Replace ATTRIBUTE with the name of the attribute to be edited. The attributes that can be edited in this way are
keepalive-time,max-threads, andthread-factory. - Replace VALUE with the required value of the attribute.
- Use the
read-resourceoperation to confirm the changes to the thread pool./subsystem=ejb3/thread-pool=THREADPOOLNAME:read-resource
Important
keepalive-time attribute with the CLI the required value is an object representation. It has the following syntax.
/subsystem=ejb3/thread-pool=THREADPOOLNAME:write-attribute(name="keepalive-time", value={"time" => "VALUE","unit" => "UNIT"}Example 23.10. Set the Maxsize Value of a Thread Pool using the CLI
[standalone@localhost:9999 /] /subsystem=ejb3/thread-pool=HSThreads:write-attribute(name="max-threads", value="50")
{"outcome" => "success"}
[standalone@localhost:9999 /]Example 23.11. Set the keepalive-time Time Value of a Thread Pool using the CLI
[standalone@localhost:9999 /] /subsystem=ejb3/thread-pool=HSThreads:write-attribute(name="keepalive-time", value={"time"=>"150"})
{"outcome" => "success"}
[standalone@localhost:9999 /]
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.