Red Hat Training

A Red Hat training course is available for Red Hat JBoss Operations Network

33.4. Creating JBoss EAP 7 Resources

33.4.1. Tracking the Child History

Every Inventory tab has a Child History subtab. The history lists when child resources have been added or deleted, along with the date when the action occurred and which JBoss ON user initiated it.

Figure 33.10. Child History

Child History
Adding or removing resources through JBoss ON helps maintain that trail of inventory changes.

33.4.2. Creating Server Groups

Server groups are created as part of the domain setup to help manage configuration and content for managed servers.
  1. Click the Inventory tab in the top menu.
  2. Select Servers - Top Level Imports in the Resources menu table on the left.
  3. Select the resource entry for the EAP 7 server.
  4. Expand the EAP7 Host Controllers section of the menu on the left.
  5. Right-click the domain controller entry.
  6. In the Create Child menu, select the item for Server Group.
  7. Enter the name for the new server group.
  8. Enter the settings for the server group: the profile to use, the socket bindings group to use, and any system properties to set.
  9. Click Finish.

33.4.3. Creating Managed Servers

Managed servers are the functional servers in a domain; they perform the actual client interactions. The managed servers are children of the domain controller; the configuration and content for the managed servers is located in the domain controller configuration and is assigned by server group.
Note
Because of the way that domain components can be arranged on physical systems (Section 33.1.2, “Separating Configuration and Real-Time Operations: Domains”), the managed server may not show up in the same configuration entry as the domain controller which is its parent. The new managed server is listed as a child of the host controller it is created on. The new managed server will show up in the platform (agent) inventory of that host controller.
Note
The creation process must be performed on the host controller after the job is submitted, and then the local agent must discover the new instances. Depending on where in the schedule the job runs and is completed, it can take several minutes for the new managed server to show up in the agent's discovery queue.
  1. Click the Inventory tab in the top menu.
  2. Select Servers - Top Level Imports in the Resources menu table on the left.
  3. Select the resource entry for the EAP 7 server.
  4. Expand the EAP7 Host Controllers section of the menu on the left.
  5. Right-click the domain controller entry.
  6. In the Create Child menu, select the item for Managed Server.
  7. Enter the name for the new server.
  8. Enter the settings for the server:
    • The EAP 6 domain host to create the server on.
    • The server group to add the server to.
    • The socket binding group to use. This gives the base port numbers for the server instance to use.
    • The port offset. This is the number to add to the socket bindings settings to determine the actual port numbers for the server instance. If the socket binding port is 1000, and the offset is 150, then the port number used for that interface on the managed server is 1150.
    • Whether the server starts automatically when the EAP 6 host starts.
    • Any system properties for the server.
  9. Click Finish.

33.4.4. Changing JVM Definitions

Managing the JVM settings for instances can help improve performance and better allocate system resources. Because of the nature of the EAP 7 domain structure, JVM settings work in a kind of cascade: the host controller JVM settings apply to the server group and all servers; any server group JVM settings override the host controller settings and apply to all their managed servers. Then, a JVM definition can be created for a managed resource, and that definition trumps any higher-level JVM settings.

33.4.4.1. JVM Definitions as Resources

In the EAP 7 management console, the JVM settings are treated as configuration options for server entries. Each server has a configuration tab for JVM configuration, and then there is a separate JVM Configurations under the Server page for the host controller.
As with the managed server configuration, the server group configuration has a tab for JVM settings.
In JBoss ON , JVMs have historically been separate resource types, with their own configuration and monitoring. For EAP 7, JVM definitions are also treated as separate resource types, children of the server or server group they apply to, even though in a structure sense the JVM definition is a collection of configuration properties; the JVM itself is the parent resource.

33.4.4.2. Creating a JVM Definition

A default JVM definition is already defined for the host controller, and that JVM definition is applied to every server group and, subsequently, every managed server associated with that group.
New JVM definitions can be created for server groups or managed servers to override those default settings. The managed server and server group definitions are based on the host controller JVM definition. Additional JVMs can be added to the host controller to provide a different base to use for new server group and server JVMs.
Important
A host controller can have multiple JVM definitions; the default one is used for all managed servers and server groups, while any additional JVM definitions are available as the base definition for custom JVM definitions at the managed server and server group levels.
However, a managed server and a server group can have only one JVM definition. The UI will allow multiple JVM definitions to be created for a managed server and a server group, but the final creation step fails if a JVM definition already exists.
  1. Click the Inventory tab in the top menu.
  2. Select Servers - Top Level Imports in the Resources menu table on the left.
  3. Right-click the entry to which to add the JVM definition.
  4. In the Create New menu, select the item for JVM Definition.
  5. Enter the name for the definition.
    Note
    The name of JVM definition can be anything for a host controller. For a managed server or server group, the name of the JVM definition must be the same as the host controller JVM definition which is the base of the definition.
  6. Enter the settings for the JVM. Any settings which are left blank use the values defined in the parent JVM definition.
    Most of the configuration for the JVM relates to memory and resource usage, along with options to pass environment variables or other settings to the JVM. The values of these settings can have a positive impact on both the resource performance and the overall system performance.
    The configuration settings are listed in Table 33.2, “JVM Definition Properties”.
  7. Click Finish.

Table 33.2. JVM Definition Properties

Property Description
JVM Options Sets any other Java option. Many of these are documented with the Java provider, such as Sun's documentation at http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html.
Environment variables Sets environments variables to use with the JVM.
Heap Size Sets the initial heap size for the JVM.
Max Heap Size Sets the maximum allowed heap size for the JVM. Setting this too low can cause out of memory errors.
Permgen Size Sets the initial size of the permanent generation.
Max Permgen Size Sets the maximum size of the permanent generation.
Type The type of JVM. This can be Sun or IBM, the two supported Java types for JBoss ON.

33.4.4.3. Editing a JVM Definition

The JVM definition is edited by editing the configuration properties for the JVM definition resource.
  1. Click the Inventory tab in the top menu.
  2. Select Servers - Top Level Imports in the Resources menu table on the left.
  3. Select the EAP server and navigate to the appropriate JVM definition entry.
  4. Open the Configuration tab.
  5. Change any of the JVM settings. These are listed in Section 33.4.4.2, “Creating a JVM Definition”.
  6. Click the Save button at the top of the page.

33.4.5. A Short List of Parent-Child Resources

There are hundreds of resource types defined in the JBoss EAP 7 agent plug-in, covering all major servers, subsystem types, and services. The Resource Reference covers all of the different resource types and lists child types for each.
Table 33.3, “A Short List of Parent-Child Resources” lists some common JBoss EAP 7 resource types and what children resource can be created for them through the JBoss ON UI.
Note
Creating a child resource must be performed on the parent resource after the job is submitted. Then the local agent must discover the new instances.
Depending on where in the schedule the job runs and is completed, it can take several minutes for the new managed server to show up in the agent's discovery queue.

Table 33.3. A Short List of Parent-Child Resources

Resource Child Resource Types
Standalone server
  • Deployment
Domain Controller
  • Domain deployment
  • Managed servers
  • Server groups
Host
  • JVM definition
Server Groups
  • Deployment
  • JVM definition
Datasources (under Profiles)
  • Datasource
  • XA Datasource
Infinispan > Hibernate
  • Cache
Logging
  • Async handler
  • Console handler
  • Custom handler
  • File handler
  • Logger
  • Periodic Rotating File handler
  • Size Rotating File handler
Undertow
  • Buffer Cache
  • Servlet Container
  • Server
  • Filter configurations
  • Handler configuration