4.4.4 List of methods
The table below lists and describes the methods to be implemented in the user-created plug-in.
You do not have to implement all the methods. Choose the methods you need for each product and implement them. For details about the plug-in methods provided by different products, see the respective manuals supplied with the products.
|
No. |
Category |
Method name |
Description |
Number in 4.1#2 |
|---|---|---|---|---|
|
1 |
Get configuration information |
The method to collect the configuration information |
1 |
|
|
2 |
Method to retrieve configuration information (when the adapter command has not been set up) |
|||
|
3 |
The method to collect tree information |
|||
|
4 |
Event |
The method to process JP1 events |
5 |
|
|
5 |
This method converts event data (generated by an external system) to JP1 events. |
|||
|
6 |
Get relation information |
The method to generate a relation between collected configurations. |
2 |
|
|
7 |
The method to collect the details of link information |
|||
|
8 |
A method that collects related information needed when IM management node is loaded. |
|||
|
9 |
Get trend information |
The method to get the list of metrics for time-series data that can be collected |
3 |
|
|
10 |
The method to collect time-series data |
|||
|
11 |
Get url information |
The method to get the URL for starting a monitor |
6 |
|
|
12 |
Any method created by the user#1 |
Any method created by the user#1 |
An arbitrary method created by the user. Avoid the method name starting with an underscore (_). |
3 |
- #1
-
The arbitrary method created by the user is executed via the plug-in processing execution API (im_api_v1_actions). For details on the plug-in processing execution API (im_api_v1_actions), see 5.7.1 Plug-in processing execution.
- #2
-
The numbers in this column correspond to the numbers in 4.1 What a user can do with the user-created plug-in.
- Organization of this subsection
-
(1) __configurationGet method
- Description
-
The method returns the configuration information of each product in JSON format. When host name is written to target host definition file for configuration collection (imdd_target_host.conf), in the Intelligent Integrated Management Base, call this method only when checking the return value of the adapter command after it is called and finding the value is 0.
-
If the configuration information is collected successfully
In the __configurationGet method, call the args.setResult (configuration information in JSON format) method.
-
If the method fails to collect the configuration information
Call the args.setError (error message) method, instead of the args.setResult method.
In the __configurationGet method, either the args.setResult or args.setError method must be called if the __configurationGet method can process the component.
The __configurationGet method is called within the jddcreatetree command that creates the system management tree of the Intelligent Integrated Management Base.
Each user-created plug-in should refer to the value of args.component to determine if the plug-in can deal with the component.
-
- Parameters
-
The following table lists and describes the parameters of the __configurationGet method.
Table 4‒7: Parameters of the __configurationGet method No.
Member
Description
Remarks
1
hostname
Name of the host from which the configuration information is collected
None
2
component
Name of the component managing the configuration information
"/HITACHI/JP1/PFM/CONFINFO"
3
data
Execution result of the adapter command.
It is a string converted into UTF-8 format, based on the character code in the header information.
The header information is not included.
None
4
jp1UserName
JP1 user name
The user has the administrator permissions for each product.
5
jp1Token
JP1 token for jp1UserName
The JP1 token is BASE64 encoded.
6
protocolName
Protocol name
The header information contained in the execution result of the adapter command
7
protocolVersion
Protocol version
The header information contained in the execution result of the adapter command
8
codeset
Character code
The header information contained in the execution result of the adapter command
9
productName
Product name
The header information contained in the execution result of the adapter command
10
setResult(String json)
The method to set the configuration information in JSON format
None
11
setError(String message)
The method for error notification.
It sets an error message.
12
stderr
It stores the value output by the adapter command to the standard error output.
- Note
-
You need to assign an SID with the value information added for each component to the configuration information that is set for setResult. For details on the SID, see 7.1 SID.
- List of configuration information to be returned
-
The following describes the list of configuration information returned by the __configurationGet method.
- Formats
{ "meta":{ "timestamp":"created-time(ISO8601-formatted-UTC-time)", "objectRoot":[ { "type":"object-root-node-type", "defaultSystem": { "name":"name-of-the-structured-identifier-of-the-default-system-node", "label":"display-name-of-the-default-system-node" } },... ] }, "simtData":[ {"sid":"<SID>","value":{structured identifier}}, ... ] }- Describe
-
The following table lists and describes what is contained in the list of obtained infrastructures.
Table 4‒8: Description in the list of obtained infrastructures No.
Item
Data types
Description
1
meta
Object
An object that stores file information
2
timestamp
string
Returns the date and time of file creation as the UTC time in ISO8601 format.
This attribute cannot be omitted.
The time is the server time of JP1/IM - Manager.
3
objectRoot
array
An array that stores the object root node type and the default system node information.
This attribute can be omitted.
4
type
string
Indicates the object root node type (such as a network device (NETWORKDEVICE) or storage (STORAGE)) placed under the root node of the tree and under the system node.
The host (HOST) does not have to be specified. Make sure that it is placed under the root node of the tree and under the system node.
This attribute can be omitted. If it is omitted, only the host is placed under the root node of the tree and under the system node.
5
defaultSystem
Object
Specify the attribute if you create a default system node whose parent node is the object root node.
If this attribute is omitted, the default tree node of the object root node specified in type is placed directly under AllSystems.
6
name
string
Specifies the name of the configuration information SID for the default system node.
If this attribute is omitted, the object root node type is set as the SID name of configuration information.
7
label
string
Specifies the label of the default system node.
If this attribute is omitted, the label attribute is not set for the additional information of the default system node.
8
simtData
array
An array of configuration information
9
sid
string
Indicates the configuration information SID.
10
value
Object
Indicates a structured identifier
- Example
-
For details on the information the __configurationGet method retrieves from each product, see 7.1.4 Information retrieved from each product.
- Impact of configuration information set by setResult
-
The following table lists and describes the functions that are affected by the configuration information set by setResult and its impact.
Table 4‒9: List of affected functions No.
Function
Impact
1
System status monitoring
-
The IM management node acquisition function outputs the set configuration information as an IM management node file.
-
The IM management node tree generation function# uses the configuration information to generate a tree and outputs it as an IM management node tree file.
-
The __eventGet method uses the SID of the configuration information. With the __eventGet method, a JP1 event is mapped with an IM management node.
2
Integrated monitoring of systems by IM management nodes
__createLink or the IM management node link definition file (imdd_nodeLink_def.conf) uses the SID of the configuration information.
Workflows are displayed according to IM management node links with type of rootJobnetExecutionOrder (root jobnet execution order).
3
Custom UI display
A custom UI window is displayed according to the SID of the configuration information.
4
Related node display
__createLink or the IM management node link definition file (imdd_nodeLink_def.conf) uses the SID of the configuration information. Related nodes are displayed according to IM management node links.
5
IM management node property display
The information specified in property of the additional information (value) of the configuration information is displayed.
6
Startup of a linked product window
The window of a linked product is opened for the IM management node in which __urlGet is specified in methods of the additional information (value) of the configuration information.
7
Trend information display
Trend information on the specified metric is displayed for the IM management node in which __metricListGet and __timeSeriesDataGet are specified in methods of the additional information (value) of the configuration information.
8
Managing Trend Data by IM management node
Refer to the jp1im_TrendData_labels of the configuration information grant information (value), and specify the value of replacement string "$jp1im_TrendData_labels" specified in PromQL expression in the argument promQLQuery of jp1TrendDataService.getTrendData method.
If the jp1im_TrendData_labels of the configuration information is not specified, trend data related to the applicable managed node cannot be acquired.
For details of jp1TrendDataService.getTrendData method, see 4.5.17 jp1TrendDataService.getTrendData.
- #
-
For details on the IM management node tree generation function, see 7.4 IM management node tree generation function.
-
(2) __configurationGetAdapterless method
- Description
-
Similar to the __configurationGetAdapterless method, this method returns the configuration of the application in JSON format. Implement and use this method if you cannot implement adapter commands, such as monitoring SaaS. Intelligent Integrated Management Base invokes this method if you do not write host name in target host definition file for configuration collection (imdd_target_host.conf) only.
If you want to implement this method on each user-created plug-in, refer to value of args.component to determine if it can be processed.
The specific environment information required to implement this method (for example, information related to authentication when monitoring SaaS) is described in file defined in user-created plug-in. For details, see 4.6.1 Definition files used by user-created plug-ins.
- Parameters
-
The following table lists and describes the parameters of the __configurationGetAdapterless method.
Table 4‒10: Parameters of the __configurationGetAdapterless method No.
Member
Description
Remarks
1
component
Component name from which the configuration information is managed
"/HITACHI/JP1/PFM/" + Product name specified in product of the configuration target definition file (imm_target_host.comf)
2
jp1UserName
JP1 user name
User with administrator privileges for each product
3
jp1Token
jp1UserName JP1 token
JP1 tokens are BASE64 encoded
4
setResult(String json)
Method that sets JSON form of the configuration
None
5
setError(String message)
Methods for Error Notifications
Sets an error message.
- Note
-
For the configuration information to be specified to setResult, SID must be added with value information for each component. For details of SID, see 7.1 SID.
-
When acquisition of configuration information ends normally
Invoke the args.setResult in __configurationGetAdapterless method (JSON format configuration information).
-
When acquisition of configuration information fails
Call args.setError (error message) method instead of args.setResult method.
In the __configurationGetAdapterless method, if the component can be processed by itself, be sure to call either args.setResult method or args.setError method.
The __configurationGetAdapterless method is called in jddcreatetree command that creates Intelligent Integrated Management Base system-managed tree.
- List of configuration information to be returned
-
The format of retrieving the list of configuration information returned by the __configurationGetAdapterless method, the description, and the effect of the configuration information set by setResult are the same as those of the __configurationGet method.
- When to use the __configurationGet method properly
-
The main differences between the __configurationGet and __configurationGetAdapterless methods are listed below.
Table 4‒11: __configurationGet and __configurationGetAdapterless methods compared Method name
Configuration acquisition target definition
Description in file
Method for obtaining unique environment information
Remarks
__configurationGet
Products and host name
Adapter command or user-created plug-in definition file
JP1/Base is required
__configurationGetAdapterless
Product only
User-created plug-in definition file
None
Therefore, the __configurationGet method and the __configurationGetAdapterless method are used differently as shown in the tables below.
Table 4‒12: Use of the __configurationGet and __configurationGetAdapterless methods Usage method name
Use case
__configurationGet
-
If you do not want to include environmental data in product plugin definition file (for security or other reasons)
__configurationGetAdapterless
-
If you cannot install JP1/Base
-
When it is difficult to implement adapter commands (when you do not need to use adapter commands)
-
(3) __createTreeNode method
- Description
-
The method collects the tree SID that corresponds to simtData in the input information together with additional information, and returns them in JSON format.
If a user-created plug-in implements the __createTreeNode method, the default tree of JP1/IM can be customized. For details on the default tree, see 7.4.2 Node generation function.
The user-created plug-in generates a tree node object and sets it with setResult if the tree SID of simtData is the target of the tree node to be customized. If simtData objects have identical values in both the object type and name of the target, they will be the same node in the tree. Therefore, configure simtData objects that have identical values in both the object type and name to return the same tree SID.
If you do not customize the parent node of the tree node to be customized, use the treeNodeCreator object to get the tree SID of the parent node portion and use it as a part of the tree SID.
-
If the tree SID and additional information can be retrieved successfully
Call the args.setResult (tree SID in JSON format) method within the __createTreeNode method.
-
If the tree SID and additional information cannot be retrieved
Call the args.setError (error message) method, not the args.setResult method.
If the __createTreeNode method itself can process SimtData, make sure to call either the args.setResult method or artgs.setError method within the __createTreeNode method.
The __createTreeNode method is called in the jddcreatetree command that creates a system management tree for the Intelligent Integrated Management Base.
-
- Parameters
-
The following table lists and describes the parameters of the __createTreeNode method.
Table 4‒13: Parameters of the __createTreeNode method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
simtData
SimtData of which you want to get the tree SID
4
treeNodeCreator
An object that provides the functions to manage information of created nodes and create a default tree.
For details, see 4.4.4(3)(a) treeNodeCreator object.
5
setResult (String json)
The method to set the retrieved tree SID and additional information in JSON format
6
setError (String message)
The method for error notification.
It sets an error message.
- Format of the tree SID and additional information to be returned
-
The following describes the format of the tree SID and additional information returned by the __createTreeNode method.
- Formats
{ "meta":{ "componentName":"name-of-the-component-from-which-tree-information-is-retrieved" }, "simtData":[ {"sid":"tree-SID","value":{structured-identifier}}, ... ] }- Describe
-
The following table lists and describes the items of the retrieved tree SID and additional information.
Table 4‒14: Items of the retrieved tree SID and additional information No.
Item
Data types
Description
1
meta
Object
Indicates meta information.
2
componentName
string
Indicates the name of the component from which the tree information is retrieved.
3
simtData
Object
Indicates a simtData
4
sid
string
Indicates a tree SID
5
value
Object
Indicates a structured identifier
- Example
-
The following shows an example of retrieving information with the __createTreeNode method.
{ "meta":{ "componentName":"/HITACbHI/JP1/OA/CONFINFO" }, "simtData":[ { "sid":"_ROOT_AllSystems/_HOST_host1/_CATEGORY_job /_SUBCATEGORY_JP1%2FAJS3%20-%20Manager/_OBJECT_AJSROOT1", "value": { "target":["_JP1AJS-M_host1/_HOST_host1/_JP1SCHE_AJSROOT1"], "label":"AJSROOT1"}} } } ] } - Impact of IM management node tree information set by setResult
-
The following table lists and describes the function that is affected by the IM management node tree information set by setResult and its impact.
Table 4‒15: List of affected functions No.
Function
Impact
1
System status monitoring
IM management node information is merged with tree information generated by the IM management node tree generation function# and output as an IM management node tree file.
- #
-
For details on the IM management node tree generation function, see 7.4 IM management node tree generation function.
(a) treeNodeCreator object
The treeNodeCreator object provides the getObjectRootTreeSID, getHostNameDef, and getCategoryName methods.
(b) getObjectRootTreeSID method
The getObjectRootTreeSID method returns the tree SID that corresponds to target (SID) specified in the parameter. Use this method when you do not customize the parent node of an object node, and then use the return value as a part of the tree SID of the object node.
- Parameters
-
The following table lists and describes the parameters of the getObjectRootTreeSID method.
Table 4‒16: Parameters of the getObjectRootTreeSID method No.
Item
Data types
Description
1
target
string
Configuration information SID for the object root node corresponding to the parent node of the tree node to be customized
2
objectRoot
Object[]
Object root node information
Use the format below.
[{"type":"object-root-node-type"},,,},#...]
- #
-
You can specify information in the object in the same format as meta.objectRoot of configuration information that is retrieved by the __configurationGet method. For details, see 4.4.4(1) __configurationGet method.
- Return values
-
The method returns the tree SID that corresponds to target. The return values vary depending on how the tree node is generated when the getObjectRootTreeSID method is called.
Table 4‒17: Return values of the getObjectRootTreeSID method No.
How the tree node is generated
Return values
1
If the tree node has already been generated
The method returns the generated tree SID that corresponds to target.
2
If the tree node has not been generated
The method analyzes the content of target and generates the tree SID that is based on the definitions in the system node definition file (imdd_systemnode.conf) and the host name definition file (imdd_host_name.conf).
If the content does not match the definition in the system node definition file (imdd_systemnode.conf), the method returns the default tree SID.
For details about the system node definition file, see System node definition file (imdd_systemnode.conf) in Chapter 2. Definition Files.
(c) getHostNameDef method
The getHostNameDef method returns the host name definition that corresponds to hostName specified in the parameter, according to the host name definition file (imdd_host_name.conf). Use this method if you customize the tree for the HOST node, and then use the return values as a name and label of the tree SID of the HOST node.
- Parameters
-
The following table lists and describes the parameters of the getHostNameDef method.
Table 4‒18: Parameters of the getHostNameDef method No.
Item
Data types
Description
1
hostName
string
Specifies the host name (alias name).
- Return values
-
The getHostNameDef method returns the following value according to the definition in the host name definition file (imdd_host_name.conf):
{"hostName":"value-in-the-definition-file","label":"value-in-the-definition-file"}The method returns null if there is no corresponding host name definition.
For details about the host name definition file, see Host name definition file (imdd_host_name.conf) in Chapter 2. Definition Files.
(d) getCategoryName method
The getCategoryName method returns the category name that corresponds to category (ID) specified in the parameter. Use this method if the tree to be customized contains a CATEGORY node, and then use the return value as a label of the tree SID.
- Parameters
-
The following table lists and describes the parameters of the getCategoryName method.
Table 4‒19: Parameters of the getCategoryName method No.
Item
Data types
Description
1
category
string
ID of category
- Return values
-
The getCategoryName method returns the category name that corresponds to category, according to the category name definition file for IM management nodes (imdd_category_name.conf).
The method returns null if there is no corresponding category name definition.
For details about the category name definition file for IM management nodes, see Category name definition file for IM management nodes (imdd_category_name.conf) in Chapter 2. Definition Files.
(4) __eventGet method
- Description
-
This method returns the configuration information SIDs corresponding to all JP1 events issued by each product. Each user-created plug-in must return the configuration information SID to the individual JP1 events issued by the corresponding product. Each user-created plug-in refers to the value, such as args.productName, and determines that the plug-in itself can deal with the event.
-
If a configuration information SID has been successfully generated for each one of the issued JP1 events:
Call the args.setTargetSid (configuration information SID) method in the __eventGet method.
-
If an attempt to generate a configuration information SID corresponding to an issued JP1 event fails due to missing data in the JP1 event:
Without calling the args.setError (error message) method, return from the method and exit the process.
The __eventGet method is called when the Intelligent Integrated Management Base gets the JP1 event.
-
- Parameters
-
The following table lists and describes the parameters of the __eventGet method.
Table 4‒20: Parameters of the __eventGet method No.
Member
Description
Remarks
1
productName
Product name
None
2
idBase
Event ID
Decimal number
3
event
JP1 event information
event.sid: SID of the JP1 event
event.value: Data labeled value of the JP1 event#
4
setTargetSid(String sid)
Method that sets a configuration information SID corresponding to each JP1 event
None
5
setError(String message)
The method for error notification.
It sets an error notification.
- #
-
The data labeled value contains various attribute names and attribute values of the event. You can use the following format to retrieve the attribute value for an attribute name:
value['property-name']
Put B. for a basic attribute or E. for an extended attribute in front of the attribute name.
Example: value['E.JPC_MGR']
- Impact of SID information with setTargetSid set for it
-
The following table lists and describes the function that is affected by the SID information with setTargetSid set for it and its impact.
Table 4‒21: List of affected functions No.
Function
Impact
1
System status monitoring
The JP1 event is mapped to the IM management node whose configuration information SID is target.
If you execute the jddupdatetree command in configuration change mode, the host name information provided in the configuration information SID returned with this method is used to determine the host to which to remap the JP1 event that has a configuration information SID that has been deleted from the configuration.
(5) __transformEvent method
- Description
-
This method converts JSON format data to JP1 events.
The __transformEvent method, which is implemented in user-created plug-in, or product plugin, can convert an external system-generated event received in JP1 event transformation API into a JP1 event.
- Parameters
-
The following table lists and describes the parameters of the __ transformEvent method.
Table 4‒22: Parameters of the __transformEvent No.
Member
Description
1
eventData
Event information received from the linked product (JSON format)
2
jp1eventmax
Maximum number of JP1 events that can be issued
3
setResult(String json)
Method for setting JP1 events (JSON format) converted from event information received from linked products
4
setError(String message)
Methods for error notification
Set the error code and message.
When using __transformEvent method in a plug-in, it is necessary to implement it so that the __transformEvent method determines whether the data of the input event information is data to be processed by the plug-in.
In addition, depending on the judgment result, it is necessary to implement the JP1 event to be returned to be set to setResult only when the data should be processed by the plug-in. If the data is not to be processed by your plug-in, return it without setting anything.
The JP1 event to be set to setResult returned by the __transformEvent method is set in the following format.
The format of the returned JP1 event is checked by the caller's JP1 event conversion API. If malformed, the JP1 event conversion API outputs a KAJY67000-W message in the response body.
In addition, JP1 events exceeding 100 cannot be issued. If more than 100 JP1 events are set in setResult, JP1/IM - Manager issues up to 100 events from the beginning of the JP1 event sequence and does not issue subsequent events. In the plug-in, please be able to determine the details of events that were not issued by outputting them to a log.
Note that __transformEvent method does not check whether the value of the attribute for the JP1 event to be created is invalid or not. If the value of the attribute is invalid, JP1/IM - Manager's JP1 event conversion API will fail, and the JP1 event with the error will not be issued.
- Format of JP1 event to be returned
-
Format
{ "pluginName":Plug-in name, "exceedJp1eventMaxDetected":Detection of exceeding the upper limit of the number of converted JP1 events "events":[ { "eventId":Event ID, "message":Message, "attrs":{Extended attribute name: Extended attribute value, ...} }, ... ] }Parameters
No
Item name
Data type
Description
1
pluginName
String
Sets a string that represents the plug-in.
Used to generate error messages in JP1 event conversion API#.
This field cannot be omitted.
2
exceedJp1eventMaxDetected
boolean
Set whether or not to detect that the number of converted JP1 events exceeds the upper limit.
-
If the limit is exceeded: true
-
Otherwise: false
This field cannot be omitted.
If this item is true, the JP1 event conversion API# sets KAJY67003-W in the response body.
3
events
Array
Set the JP1 event to be issued in an array.
The maximum number of events you can set is 100.
The plug-in using this method determines whether the upper limit has been exceeded, and if the upper limit is exceeded, set the item exceedJp1eventMaxDetected to true and return it to the caller.
4
eventId
Array
Set the basic event ID to be issued within the following range.
-
0 - 1FFFF
-
7FFF8000 - 7FFFFFFF
This field cannot be omitted.
If a value outside the range is specified, JP1 Event Conversion API# sets KAJY67000-W in the response body and The eventId specification is out of range. Set the specified value to a value in the range of 0 - 1FFF, 7FFF8000 - 7FFFFFFF. as the factor.
5
message
Array
Set the message text that represents the contents of the JP1 event.
This field cannot be omitted.
The character encoding of the message to be registered depends on the character encoding of the OS environment where JP1/IM - Manager is located.
Set as a string of up to 1,023 bytes. If a character string of 1,024 bytes or more is specified, a character string of up to 1,023 bytes is set to the message of the JP1 event.
6
attrs
String
Specify an array of extended attribute names.
This field is optional.
If the same extended attribute name is specified more than once, it is overwritten by the value of the last extended attribute specified.
Extended attribute names can be names that begin with uppercase letters and contain up to 32 bytes of uppercase letters, numbers, and underscore (_) lines.
If the character string to be constructed is invalid, set KAJY67000-W in the response body of JP1 Event Conversion API* and set The extended attribute name of attrs is invalid. Please specify uppercase letters and first letters. as the factor.
When a character string exceeding 32 bytes is specified, the JP1 event conversion API# sets KAJY67000-W as the response body and sets The extended attribute name of attrs must be a string of 32 bytes or less. as the factor.
Also, do not specify the prefix E. for extended attribute names.
When E. is specified, the JP1 event conversion API# sets KAJY67000-W as the response body and The extended attribute name of attrs is invalid. Please specify uppercase letters and first letters. as the factor.
The total length of all extended attribute values can be up to 10,000 bytes.
If the total length limit is exceeded, the JP1 event conversion API# sets KAJY67000-W as the response body and The upper limit of the extended attribute value of attrs is 10000 bytes. Specify a string of 10000 bytes or less. as the factor.
For details on JP1 event attributes, see 3.1 Attributes of JP1 events.
- #
-
For details of JP1 event conversion API, see 5.6.5 JP1 Event converter.
Example
{ "pluginName":"PFMCS", "exceedJp1eventMaxDetected":false "events":[ { "eventId":"2FFF", "message":"xxxxx", "attrs":{"SEVERITY":"Error","JP1_SOURCEHOST":"HOSTB"} }, ... ] } -
(6) __createLink method
- Description
-
The method generates a relation between retrieved configurations and returns it in JSON format.
-
If the relation between retrieved configurations is generated successfully
In the __createLink method, call the addResult (relation information between the retrieved configurations in JSON format) method.
-
If the configuration information could not be retrieved
Call the args.setError (error message) method, instead of the addResult method.
Make sure you call either the addResult or args.setError method.
The __createLink method is called within the jddcreatetree command that creates the system management tree of the Intelligent Integrated Management Base.
-
- Parameters
-
The following table lists and describes the parameters of the __createLink method.
Table 4‒23: Parameters of the __createLink method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
simtFileList
List-formatted data of all configuration information
It contains multiple IM management node objects as its data structure.
4
addResult(String json)
The method to set the relation information between the retrieved configurations in JSON format
None
5
setError(String message)
The method for error notification.
It sets an error code and a message.
- Format of relation information to be returned
-
The following describes the format of relation information between retrieved configurations returned by the __createLink method.
- Formats
-
Format of the configuration information set for setResult:
{ "meta":{ "format":"file-type", "componentName":"name-of-the-component-whose-relation-information-is-to-be-retrieved", "timestamp":"generation-time-of-relation-information" }, "links":[ { "from":"SID-of-the-preceding-node", "to":"SID-of-the-succeeding-node", "type":"type-of-operation-target", "value":structured-identifier }, ... ], } - Describe
-
The following table lists and describes the items of relation information between the retrieved configurations.
Table 4‒24: Items to describe the relation information between the retrieved configurations No.
Item
Data type
Description
1
meta
array
Array that stores the data of the file
2
format
string
The file format
Always set this to conf. This attribute cannot be omitted.
3
componentName
string
Name of the component whose relation information is to be retrieved
This attribute cannot be omitted.
4
timestamp
string
Returns the date and time of file creation as the UTC time in ISO8601 format.
This attribute cannot be omitted.
The time is the server time of JP1/IM - Manager that generated the relation information.
5
links
array
Array for relation information between configurations.
The order of the array is irrelevant.
If multiple pieces of relation information with the same from, to, and type values are found, these values are output with the jddcreatetree command, but the last relation information that appeared takes effect if the jddupdatetree is used to apply the information to the system.
However, if the configuration information is from a JP1/AJS plug-in (componentName is /HITACHI/JP1/AJS3/CONFINFO) and type is rootJobnetExecutionOrder (root jobnet execution order) and from and to have the same value, the Intelligent Integrated Management Base merges objects stored in the value.unit array into a single link object and outputs it as an IM management node link file.
6
from
string
Preceding node.
It specifies the SID of the preceding node.
- Example
-
_ToolA-M_hostA/_HOST_hostA
If the to attribute is specified, this attribute can be omitted. It cannot accept any control character.
7
to
string
Succeeding node.
It specifies the SID of the succeeding node.
- Example
-
_ToolA-M_hostA/_ToolA-A_hostB/_HOST_hostB
If the from attribute is specified, this attribute can be omitted. It cannot accept any control character.
8
type
string
Specifies the type of relation information.
It cannot accept a string starting with an underscore (_) or any control characters. Alphanumeric characters are available. The maximum number of characters is 255 bytes.
type describes a grouping of relations that have the same meaning. On the Related node tab in the Integrated Operation Viewer window, you can filter relations to display only those belonging to a specific type.
For relations within a JP1/IM product or between a JP1/IM product and another product, the following types are used. In addition to these types, the use of user-specified types is also allowed.
-
rootJobnetExecutionOrder: Relation of the execution order of root jobnets
-
rootJobnetAgent: Relation between a root jobnet and an AJS agent
-
managerAgent: Relation between the manager and agent of a JP1 product
-
sameNode: Relation between nodes with the same name
-
L2Connection: Relation between layer-2 connection lines managed by JP1/NNMi
-
Infrastructure: Relation between infrastructure resources managed by JP1/OA
-
monitoringConfiguration: Relation between a product and a monitoring target in a monitoring product configuration
The user can also specify any type in addition to this type.
9
value
Object
Specifies additional information for relation information between configurations.
The following shows parameters supported by default when type is rootJobnetAgent:
-
precedingJob: Specifies the preceding job of a linked job by its full name.
-
succeedingJob: Specifies the succeeding job of a linked job by its full name.
This attribute can be omitted.
- Example
-
The following shows an example of retrieving information with the __createLink method.
{ "meta":{ "format":"conf" "componentName":"/HITACHI/JP1/AJS3/CONFINFO" "timestamp":"2018-11-11T00:00:00Z" }, "links":[ { "from":"JP1AJS-M_AJSM1/_HOST_AJShost1/_JP1SCHE_S1/_JP1JOBG_JG1/_JP1ROOTJOBNET_root1", "to":"JP1AJS-M_AJSM2/_HOST_AJShost2/_JP1SCHE_S2/_JP1JOBG_JG2/_JP1ROOTJOBNET_root2", "type":"rootJobnetExecutionOrder", "value": { "precedingJob":"root1/job1", "succeedingJob":"root2/job2", } }, ... ], } - Impact of relation information set by addResult
-
The following table lists and describes the functions that are affected by the relation information set by addResult and its impact.
Table 4‒25: List of affected functions No.
Function
Impact
1
System status monitoring
The IM management node acquisition function outputs the IM management node link object as an IM management node link file.
2
Integrated monitoring of systems by IM management nodes
Relations are displayed in the Workflow tab according to IM management node links with type of rootJobnetExecutionOrder (root jobnet execution order).
3
Related node display
Relations are displayed in the Related node tab according to IM management node links.
4
Linked unit display
If an IM management node link has a type of rootJobnetExecutionOrder (root jobnet execution order), the unit information (including the result of __linkValueGet) specified for unit of the link's additional information (value) is displayed.
5
Display of impact on following root jobnets
If an IM management node link has a type of rootJobnetExecutionOrder (root jobnet execution order), the impact (result of __linkValueGet) of the unit (latest generation) specified for unit of the link's additional information (value) on following units is displayed.
(7) __linkValueGet method
- Description
-
A method that adds dynamic grant information to the value parameter and returns an array of link information in the given JSON format.
If the plugin contains link information that cannot be processed, the link information will be returned as is.
- Parameters
-
The following table lists and describes the parameters of the __linkValueGet method.
Table 4‒26: Parameters of the __linkValueGet method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
linksData
An object for a link information object array
4
links
An array of link information objects
It cannot be omitted. An empty array cannot be specified.
5
from
SID of the preceding node
None
6
to
SID of the succeeding node
7
type
Type of the target
8
value
structured identifier
9
select
An array of value parameters to be retrieved.
If you want to further specify an object or a member of an object array, specify object-name.member-name.
If you want to specify only "impact" in the following example, specify "unit.impact" in select:
"value":{ "unit": [ { "precedingJob":"job1", "succeedingJob":"job2" "impact":true } ] }It can be omitted.
If omitted, it retrieves all the parameters.
10
setResult(String json)
The method to set link information in JSON format
None
11
setError(String message)
The method for error notification.
It sets an error message.
- Format of link information to be returned
-
The following describes the format of link information returned by the __linkValueGet method.
- Formats
{ "links": [ { "from": "the-preceding-node-SID", "to": "the-succeeding-node-SID", "type": "type-of-the-target", "value": structured-identifier }, ... ] }- Describe
-
The following table lists and describes the items of retrieved link information.
Table 4‒27: Items of the retrieved link information No.
Item
Data types
Description
1
links
array
An array of link information
2
from
string
SID of the preceding node
3
to
string
SID of the succeeding node
4
type
string
Type of the target
5
value
Object
Specifies additional information of relation information between configurations.
- Example
-
The following shows an example of retrieving information with the __linkValueGet method.
{ "links": [ { "from":"_JP1AJS-M_HOST1/_HOST_HOST1/_JP1SCHE_schedulerserv/_JP1JOBG_jobgroup/_JP1ROOTJOBNET_jobnet1", "to":"_JP1AJS-M_HOST1/_HOST_HOST1/_JP1SCHE_schedulerserv/_JP1JOBG_jobgroup/_JP1ROOTJOBNET_jobnet2", "type":"rootJobnetExecutionOrder", "value":{ "unit": [ { "precedingJob":"job1", "succeedingJob":"job2" "succeedingJobStartTime":"2019-05-14T00:00:00Z", "precedingJobURL":"http://10.220.196.82:22252/ajs/...", "succeedingJobURL":"http://10.220.196.82:22252/ajs/...", "impact":"error" } ... ], "msg":"KAJY04254-E The collecting information process could not be generated." } }, ... ] } - Impact of additional information (value) of a link set by setResult
-
The following table lists and describes the functions that are affected by the additional information (value) of a link set by setResult and its impact.
Table 4‒28: List of affected functions No.
Function
Impact
1
Linked unit display
If an IM management node link has a type of rootJobnetExecutionOrder (root jobnet execution order), the information specified for unit of the link's additional information (value) is displayed.
In addition, the URL parameter is used to start the WWW browser on which the URL is specified.
2
Display of impact on following root jobnets
If an IM management node link has a type of rootJobnetExecutionOrder (root jobnet execution order), the impact of the unit (latest generation) specified for unit of the link's additional information (value) on following units is displayed.
(8) __simtLoad method
- Description
-
This method is called to collect the required related information when IM management node is loaded. Called from simt service when the managed node is updated with the following actions:
-
When simtData loading is completed at service startup
-
When simtData loading is completed when the jddupdatetree command is executed
Collected information can be provided to other methods, for example, by setting the information to a global variable. For example, if the __simtLoad method collects AJS manager host name and AJS Agent host and set it global variable, you can refer to it in other methods (__eventGet method).
-
When related information retrieval is completed normally
You can provide information about other methods, for example by setting the global variable.
-
Failed to get related information
Ensure that you call args.setError (error message) method.
-
- Parameters
-
The following table lists and describes the parameters of the __simtLoad method.
No.
Member
Description
Remarks
1
simtDataList
All itemized lists of configuration simtData
All simtData in the master information of the managed node
2
setError(String message)
Methods for error notifications
Set the error code and Message.
None
(9) __metricListGet method
- Description
-
The method retrieves the list of metrics that can be displayed for time-series data and returns it in JSON format.
- Parameters
-
The following table lists and describes the parameters of the __metricListGet method.
Table 4‒29: Parameters of the __metricListGet method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
sid
A configuration information SID whose list of metrics you want to retrieve
4
lang
Language for the list of metrics to be retrieved
5
setResult (String json)
The method to set the list of metrics retrieved in JSON format
6
setError (String message)
The method for error notification.
It sets an error message.
- Format of the list of metrics to be returned
-
The following shows the list of metrics returned by the __metricListGet method.
- Formats
{ "metrics":[ { "name":"metric", "label":"metric-display-name", "category":"category-of-the-metric", "description":"description-of-the-metric", "default":default-setting } ... ]- Describe
-
The following table lists and describes the items of the retrieved list of metrics.
Table 4‒30: Items of the retrieved list of metrics No.
Item
Data types
Description
1
metrics
array
An array of metric information.
You can specify up to 100 elements. An empty array cannot be specified. This item cannot be omitted.
2
name
string
The name of the metric.
It can be specified with half-width alphanumeric characters and the following symbols:
- (hyphen), _ (underscore)
It must be specified between 1 and 255 characters.
An empty string cannot be specified. This item cannot be omitted.
3
label
string
The display name of the metric.
It can be specified between 1 and 255 characters, excluding control characters. An empty string cannot be specified. This item can be omitted.
4
category
string
The category of the metric.
It can be specified between 1 and 255 characters, excluding control characters. An empty string cannot be specified. This item can be omitted.
5
description
string
The description of the metric.
It can be specified between 1 and 1023 characters, excluding control characters. An empty string cannot be specified. This item can be omitted.
If a long string is specified in this item, when you use the Integrated Operation Viewer window of JP1/IM - Manager (Intelligent Integrated Management Base), a string displayed as a tooltip for the metric display name in the Trends tab might be truncated by WWW browser limitations (maximum number of characters that can be displayed as the title attribute).
6
default
boolean
Specifies whether the metric is a default metric.
-
true: It is a default metric.
-
false: It is not a default metric.
You can specify up to 10 metrics as the default metrics. This item cannot be omitted.
-
- Example
-
The following shows an example of retrieving information with the __metricListGet method.
{ "metrics":[ { "name":"CPU-Usage", "label":"CPU-used-rate", "category":"CPU", "description":"Show the CPU usage on a core basis. (Units: %)", "default":true } ... ] } - Impact of the list of metrics set by setResult
-
The following table lists and describes the function that is affected by the list of metrics set by setResult and its impact.
Table 4‒31: List of affected functions No.
Function
Impact
1
Trend information display
In the trend graph settings area of the Trends tab, the metrics are displayed as candidates of metrics to be displayed in a chart.
(10) __timeSeriesDataGet method
- Description
-
The method retrieves time-series data and returns it in JSON format.
If the number of time-series data sets retrieved and the number of instances exceed the limits specified by countPerInstance and instanceCount respectively, the applicable member of the exceedCountDetected object in the response is set to true and the data is selected so that the numbers of data sets are below the limits of countPerInstance and instanceCount, and then the data is returned.
- Parameters
-
The following table lists and describes the parameters of the __timeSeriesDataGet method.
Table 4‒32: Parameters of the __timeSeriesDataGet method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
sid
A configuration information SID whose time-series data you want to retrieve
4
lang
Language for time-series data to be retrieved
5
metric
The name of the metric.
It must be specified between 1 and 255 characters.
An empty array cannot be specified. This item cannot be omitted.
6
startTime
Specifies the start date and time of the time-series data as the UTC time in ISO8601 format. Do not specify seconds after the decimal point.
7
endTime
Specifies the end date and time of the time-series data as the UTC time in ISO8601 format. Do not specify seconds after the decimal point.
8
countPerInstance
The upper limit of the number of data sets per instance in those to be retrieved
It is ensured that a value obtained by multiplying the countPerInstance value by the instanceCount value is less than or equal to 30,000.
9
instanceCount
The upper limit of instances
10
setResult (String json)
The method to set time-series data in JSON format
None
11
setError (String message)
The method for error notification.
It sets an error message.
- Format of time-series data to be returned
-
The following shows the time-series data returned by the __timeSeriesDataGet method.
- Formats
{ "metric":"metric", "timeSeriesData":[ { "instance":"instance-name" "unit":"unit", "data":[ {"time":"time","value":value}, ... ] }, ... ], "exceedCountDetected": { countPerInstance:whether-an-excess-of-the-upper-limit-for-the-number-of-data-sets-per-instance-is-detected, instanceCount: whether-an-excess-of-the-upper-limit-for-the-number-of-instances-is-detected } }- Describe
-
The following table lists and describes the items of the retrieved time-series data.
Table 4‒33: Items of the retrieved time-series data No.
Item
Data types
Description
1
timeSeriesData
array
An array of time-series data.
An empty array cannot be specified. This item cannot be omitted.
2
metric
string
The name of the metric.
It can be specified with half-width alphanumeric characters and the following symbols:
- (hyphen), _ (underscore)
It must be specified between 1 and 255 characters.
An empty string cannot be specified. This item cannot be omitted.
3
instance
string
The name of the instance.
It can be specified between 1 and 255 characters, excluding control characters. An empty string cannot be specified. This item can be omitted.
4
unit
string
The unit for the metric.
It can be specified between 1 and 255 characters, excluding control characters. An empty string cannot be specified. This item cannot be omitted.
5
data
array
An array of two-dimensional data consisting of the time and value.
If no time-series data exists in the specified period, specify an empty array.
This item cannot be omitted.
6
time
string
The time of data.
It is the UTC time in ISO8601 format. The number of seconds after the decimal point cannot be specified.
-
If data is empty: This item can be omitted.
-
If data is not empty: This item cannot be omitted. An empty string cannot be specified.
7
value
number
A value of data.
It should be the same as the accuracy of number in JavaScript.
-
If data is empty: This item can be omitted.
-
If data is not empty: This item cannot be omitted.
8
exceedCountDetected
Object
The object to detect the upper limit.
This item cannot be omitted.
9
countPerInstance
boolean
Whether an excess of the upper limit for the number of data sets per instance is detected.
-
If the upper limit is exceeded: true
-
Otherwise: false
This item cannot be omitted.
10
instanceCount
boolean
Whether an excess of the upper limit for the number of instances is detected.
-
If the upper limit is exceeded: true
-
Otherwise: false
This item cannot be omitted.
-
- Example
-
The following shows an example of retrieving information with the __timeSeriesDataGet method.
{ "metric":"CPU Usage", "timeSeriesData":[ { "instance":"CPU_1" "unit":"%", "data":[ {"time":"2019-05-22T00:00:00Z","value":14.04}, ... ] }, { "instance":"CPU_2" "unit":"%", "data":[ {"time":"2019-05-22T00:00:00Z","value":09.24}, ... ] }, ... ], "exceedCountDetected": { "countPerInstance": true, "instanceCount": false } }If no data exists for the specified metric and in the specified period
{ "metric":"CPU Usage", "timeSeriesData":[ { "unit":"%", "data":[ ] } ], "exceedCountDetected": { "countPerInstance": false, "instanceCount": false } } - Impact of the time-series data set by setResult
-
The following table lists and describes the function that is affected by the time-series data set by setResult and its impact.
Table 4‒34: List of affected functions No.
Function
Impact
1
Trend information display
The trend of time-series data is displayed.
(11) __urlGet method
- Description
-
The method retrieves the URL for starting a monitor associated with the specified SID and returns it in JSON format.
- Parameters
-
The following table lists and describes the parameters of the __urlGet method.
Table 4‒35: Parameters of the __urlGet method No.
Member
Description
Remarks
1
jp1UserName
The JP1 user name
None
2
jp1Token
A JP1 authentication token that corresponds to jp1UserName
3
sid
A configuration information SID whose URL for starting the associated monitor you want to retrieve
4
setResult (String json)
The method to set the URL information in JSON format
5
setError (String message)
The method for error notification.
It sets an error message.
- Format of the URL for starting the monitor to be returned
-
The following shows the URL for starting the monitor returned by the __urlGet method.
- Formats
{ urlList:[ { "url":"URL-for-starting-the-monitor", "name":"name-of-the-URL" }, ... ] }- Describe
-
The following table lists and describes the items of the retrieved URL for starting the monitor.
Table 4‒36: The items of the retrieved URL for starting the monitor No.
Item
Data types
Description
1
urlList
array
An array of URL information objects
2
url
string
The URL string
3
name
string
The name of the URL
- Example
-
The following shows an example of retrieving information with the __urlGet method.
{ urlList:[ { "url":"http://10.220.196.82:22252/ajs/login.html?manager=10.220.196.82&type=monitor...", "name":"monitor-startup-window-for-rootJobNet1" } ] } - Impact of the URL information set by setResult
-
The following table lists and describes the function that is affected by the URL information for starting the monitor set by setResult and its impact.
Table 4‒37: List of affected functions No.
Function
Impact
1
Opening a window of a linked product
A window of a linked product is opened for the IM management node with __urlGet specified for methods of additional information (value) in the configuration information.