File sets
You can use various HTTP methods to load, create, update, and delete file sets.
Return file sets (GET
method)
To
return all the file sets, use a
GET
method and the
following URL:https://<server>:<port>/Unity/FileSets
To
return a specific file set, use a
GET
method and
the following request:https://<server>:<port>/Unity/FileSets?id=<fileset_id>
where <fileset_id>
is the ID of the file set that you want to retrieve.The
operation returns the following values from the requested file sets
in the simple JSON format:
Returned value | Description |
---|---|
className |
The name of the Java™ class that is used by the file set. |
fileType |
This parameter value can be either 0 or 1 . 0 means that the file set is Java-based. 1 indicates that
the file set is Python-based. |
fileName |
The name of the file that contains the code that does the splitting or annotating. |
type |
This parameter value can be either 0 or 1 . 0 means
that the file is used to split log files. 1 indicates
that the file set is used to annotate log files. |
name |
The name of the file set. |
id |
The file set identifier. |
For example, the operation returns the following values
in the JSON format for a file set:
{
"className": "com.ibm.tivoli..annotator.JavacoreAnnotator",
"fileType": 0, (- 0 for Java 1 for Script)
"fileName": "JavacoreExtractor_v1.1.0.1.jar",
"type": 1, (- 0 for Split 1 for Annotate)
"name": "Javacore-Annotate",
"id": 2
}
Create (POST
method)
To
create a file set, use a
POST
method and the following
URL:https://<server>:<port>/Unity/FileSets
You
define the parameter values in the JSON format in the HTTP message
body. For example:
{
"name": "Test",
"type": 0, (- 0 for Split 1 for Annotate)
"fileType": 0, (- 0 Java 1 for Script)
"fileName": "db2-content.jar", (- Jar file name
"className": "TestClass" (- Java Class name)
}
The input values are the same as the ones that are specified
in table 1 except for id
. This value is generated
when the file set is created.Update (PUT
method)
To
update a file set, use a
PUT
method and the following
URL:https://<server>:<port>/Unity/FileSets
You
define the parameter values in the JSON format in the HTTP message
body. The input values are the same as the ones that are specified
in table 1 except for id
. This value is generated
when the file set is created.
Delete (DELETE
method)
To
delete a file set, use a
DELETE
method and the following
URL:https://<server>:<port>/Unity/FileSets?id=<fileset_id>
where <fileset_id>
is
the ID of the file set that you want to delete.