9.1 Configuring the Create Reservation Form |
You can customize the user interface and Create Reservation logic by configuring the Create Reservation form:
Modifying the reservations.xml file that is located in the VIEWPOINT_HOME directory allows you to configure the Create Reservation page content, rules, and logic. CSS and images, which may also be customized, are located in the .war file that is distributed with Viewpoint.
Building the Create Reservation form is similar to building all other Viewpoint forms, all sharing the common requirement of modification to the <pages
>, <components
>, and <queue
> elements; use the following links and explanations to guide your efforts in configuring these elements:
Viewpoint allows you to customize and configure the mrsvctl -c command to match the needs and requirements specific to your site. The rules for creating the mrsvctl -c command are specified in the <request
> element of reservations.xml.
Every reservation requires a set of resources for consumption throughout the duration of the reservation. Therefore, a valid create reservation request must specify either a host list, a task definition, or both. The default configuration included with an initial Viewpoint installation allows users to specify a host list or a task definition, but not both. Viewpoint can only modify reservations where either the host list is specified or a task definition has been set, but not both. An administrator can modify the reservations.xml configuration to use both types of resource definitions, but keep in mind that reservations created this way cannot be modified later. For this reason it is recommended to only allow for specifying the host list or specifying a task definition, as set up in the default configuration.
To specify a task definition, set any of the following fields to a non-zero value:
proc-count
> - The number of processors per task. Accepts any Integer Value Decider.memory
> - The amount of memory per task. Accepts any Integer Value Decider.disk
> - The disk to be reserved per task. Accepts any Integer Value Decider.swap
> - The swap space to be reserved per task. Accepts any Integer Value Decider.generic-resources
> - The generic resources per task. Only works with the table-map component. Example:
<generic-resource> <component id="generic_resource_table_map" /> </generic-resource>
In the preceding example, generic_resource_table_map corresponds to a component in the form. |
task-count
> - The number of tasks to be reserved. Accepts any Integer Value Decider.More information about task definitions is available in the Moab Workload Manager documentation on the mrsvctl command.
To specify a host list, set the host-list
attribute to a list of nodes that should make up the host list. See the Moab Workload Manager documentation on the mrsvctl command for more details.
Viewpoint only supports a list of nodes, not a regular expression. Thus, use a component that contains a list of strings, or use the string-to-list operation decider. |
The following optional fields can be set regardless of the resources requested. For additional information pertaining to the respective fields, see the Moab Workload Manager documentation for the mrsvctl command and associated options.
acl
> - This field corresponds to the access control list (ACL) attribute. The ACL can only be set using an acl-editor component. This component is specifically designed to modify and create the access control list.description
> - The user-specified description or purpose of the reservation. Accepts any string value decider.end-time
> - The reservation's end time. Accepts any date value decider. See Moab documentation for more details.exclusive
> States if the reservation should be exclusive. Accepts any Boolean value decider.group
> - The name of the reservation group. Accepts any string value decider.name
> - The name of the reservation. Accepts any string value decider.node-features
> - A list of node features. Accepts any string list value decider.owner
> - The name of the reservation's owner. This user must already exist in Moab. Accepts any string value decider.partition
> - The name of a partition. Accepts any string value decider.profile
> - The name of the reservation profile to load. Accepts any string value decider.start-time
> - The reservation's start time. Accepts any date value decider.subtype
> - A node category as defined here. Accepts any string value decider.variables
> - A collection of variables to be set on the reservation. This can have one or more <variable
> child elements. Each child <variable
> element has the following three parts:
key
> (required) - The name of the variable and accepts any string decider.
value
> (required) - The value of the variable and accepts any string decider.
rule
> (optional) - Accepts any boolean decider. If this is specified, Viewpoint includes the variable only if the rule evaluates to true.