Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
COSMOS UG How to use the COSMOS UI
COSMOS Wiki > COSMOS Document Plan > COSMOS Manual Guide
Contents
COSMOS Widget Library
Category: User's Guide
Owner | Sheldon Lee-Loy |
Bug #218838 | 218838 |
Due dates | Schedule |
Outline
COSMOS defines a set of web-based components that provides access to the underlying COSMOS services. These web-based components can be configured and integrated with each other to create a very dynamic web based application.
Each component carries out one of the following basic action.
- Navigate - components that help the end user locate a data manager within the COSMOS system
- Query - components that builds and submits queries to a data manager
- View - components that visualizes information from a data manager
- Manage - components that manages a data manager
Purpose: The Data Manager Navigator displays a list of data managers that are registered with a broker. The user would use this UI component to submit queries to a particular data manager.
This web component is composed of a tree widget that contains the list of registered data managers that are the top level nodes. Icons can be be associated with each node to visually distinguish between data managers.
Two types of actions can be initiated on a node.
- Expanding a node
- Opening a pop-up menu on a node
- Selecting a node
Expanding a node
Expanding a node will initiate a query to the data manager that the node represents. This query is configurable by the application. For example, consider a "CBE" data manager. This data manager contains a repository of log files that have been collected from various applications. Expanding the node of the "CBE" data manager will submit a query to get the list of log files that the this data manager is aware of. As a result the user will see a list children nodes under the "CBE" data manager node.
Note that expanding a node may result in different queries for different data managers. These queries are configurable at the application level.
Right clicking a node will bring up a pop-up menu with a set of options. These options may vary from one data manager to the next. The types of options that are displayed in the pop-up menu are configured at the application level.
There are however some basic menu options that are available to data managers that are MDRs.
- Submit A Query
The user can select the Submit Query option to bring up a web component that will allow the user to construct a CMDBf query and submit this query to the MDR. These web components are further explained under the [Query] section.
Selecting a node
Selecting a node may cause a section within the application console to refresh. The section that is refreshed within the application as a result of selecting a particular node is configured at the application level. For example, an application console may be made up of this navigator component and the [properties] component. When the user selects a node in the navigator component the properties component is refreshed and shows the list of properties of the selected node in a table. This is illustrated in the following screen shot.
Query
Basic CMDBf Query Dialog
Purpose: This dialog provides a simple text input box to submit a CMDBf query document to a MDR.
Application can configure the [navigator] component to show this dialog box by selecting the "Submit a Query" menu option. Typically, the user would right-click the MDR he/she wants to submit a query to. This would bring up a pop-up menu with an option to "Submit a Query".
The user would then type in the CMDBf query document they would like to send. Once the user is done creating the query document they would click on the "Submit" button to send the document to the MDR.
Once the user submits the a node is added under the selected MDR that represents the query.
CMDBf Query Builder Dialog
Purpose: This web based component provides a dialog box to construct a CMDBf query document and submit the constructed document to a MDR. Users familiar with the CMDBf query document structure can use this dialog box to construct a CMDBf query document instead of hand typing the document. The query builder processes the service meta data from an MDR to determine what kind of query capabilities the user is allowed to specify.
Application can configure the [navigator] component to show this dialog box by selecting the "Submit a Query" menu option. Typically, the user would right-click the MDR he/she wants to submit a query to. This would bring up a pop-up menu with an option to "Submit a Query".
The query builder is composed of three panes. The top level pane manages the <itemTemplate> and <relationshipTemplate> nodes of a CMDBf query document. Users can add and remove itemTemplate and relationshipTemplate nodes within this pane. The top level nodes in the tree shows the list of itemTemplates defined in the query. <relationshipTemplate> nodes are defined as children nodes of an <itemTemplate>. Adding a <relationshipTemplate> underneath an <itemTemplate> node indicates that the parent node of the <relationshipTemplate> is the source template and the child node of the <relationshipTemplate> is the target template. Consider the following screen capture.
The above picture illustrates a query that has two <itemTemplate> nodes. The first <itemTemplate> has an id set to "user" while the second <itemTemplate> has an id set to "computer". The pane further shows that a <relationshipTemplate> is defined where the source template node is the "user" and the target template node is the "computer". Furthremore, the name of the "relationsihpTemplate" is set to "usage".
To add an <itemTemplate> the user can right click the "query" node in the top pane and select 'Add Item'. A dialog box will prompt the user to enter the id of the <itemTemplate>. To add a <relationshipTemplate> the user can right click an <itemTemplate> node and select 'Add Relationship'. This will prompt the user with a dialog box that will allow the user to enter the id of the <relationshipTemplate> and the id of the target template. Note that a drop down box is provided that lists existing 'itemTemplates'. The user should note that if the MDR does not support queries that include <relationshipTemplate> nodes the user will not have the ability to add <relationshipTemplate> nodes.
The bottom left pane manages the structure of an <itemTemplate> or <relationshipTemplate> element that is selected in the top pane. The user can add query capabilities to these elements. The types of capabilities that the user can add is dictated by what is supported in the service meta data provided by the MDR. The user can right click the top level node to add a particular query capability as shown below:
The user can add or remove capabilities within this pane. As the user adds capabilities under either an <itemTemplate> or <relationshipTemplate> they are building the XML structure of the <itemTemplate> or <relationshipTemplate> element. Consider the following illustration.
The above tree structure would produce the following XML structure under the <itemTemplate> element.
<s:itemTemplate id="user" suppressFromResult="false" > <s:recordConstraint > <s:recordType namespace="" localName="" > </s:recordType> </s:recordConstraint>
Once the user is done creating the query document they would click on the "Submit" button to send the document to the MDR.
Once the user submits the a node is added under the selected MDR that represents the query.