Admin reports

You can generate an admin report to collect system usage data, such as the number of active and inactive projects and size of repositories and database.

What an admin report includes

An admin report contains the following sections:

Section Includes
projects-ping-result

Lists the projects that have been pinged and the ping status of each project.

The information in this section is regenerated every 2 hours.

projects-last-login-activity

Lists the last login time of each project.

The information in this section is re-generated every 5 minutes.

active-sessions

Lists the amount of active sessions in each project.

The information in this section is re-generated every 5 minutes.

projects-repository-size

Lists the repository size and recyclable size of each project.

Recyclable size is the physical files in the repository whose logical files were deleted so they can be cleaned by promoting the GC process manually.

The information in this section is re-generated every 2 hours.

projects-db-space-used

The size of used database space of each project (SQL server or Oracle server).

The information in this section is re-generated every 2 hours.

Back to top

How to generate admin reports

It requires the site administrators permissions to generate an admin report.

To generate an admin report:

  1. Make the following POST call to trigger an action to generate the admin report and obtain the action ID.

    Copy code
    /qcbin/v2/sa/api/collectors/report-collector/execute

     

    Request example
    Copy code

        "project-request-option": { 
            "project-ping": { 
                "fetch-or-not":"true", 
                "is-file-latest": "false" 
            }, 
            "project-last-login-activity": { 
                "fetch-or-not": "true", 
                "is-file-latest": "false" 
            }, 
            "project-session-connection": { 
                "fetch-or-not": "true", 
                "is-file-latest": "false" 
            }, 
            "project-repository-used-size": { 
                "fetch-or-not": "true", 
                "is-file-latest": "false" 
            }, 
            "project-db-space-used": { 
                "fetch-or-not": "true", 
                "is-file-latest": "false" 
            } 
        } 

     

    Flags:

    • fetch-or-not. Whether or not to include the corresponding module data in the admin report.

      Example: If you set fetch-or-not to true for project-ping, the admin report includes the project ping data. If you set fetch-or-not to false, the admin report does not include the project ping data.

    • is-file-latest. Works only when fetch-or-not is set to true. It controls whether or not to get the latest JSON file data of the corresponding API for the admin report.

      Example: If you set is-file-latest of project-ping to true, the admin report includes the latest JSON file data of the project ping API. It could be another site admin user who called the API most recently.

      If you set is-file-latest of project-ping to false, the admin report includes the JSON file data of the project ping API that is triggered when you set fetch-or-not to true.

    Response example
    Copy code
    {
      "report-parameters": {
        "report-parameter": "string"
      }
    }

     

    The report parameter (action ID) is an encoded string that contains when the admin report was triggered and how the flags were set.

  2. Make the following GET call to fetch the admin report with the action ID (report parameter) you obtained in step 1.

    Copy code
    /qcbin/v2/sa/api/admin-reports/{action-id}

     

    Request header:

    You can fetch an admin report in either JSON or CSV format. Specify the format in the Content-Type header: application/json or text/csv.

    Response example:

    Copy code

        "admin-reports": { 
            "projects-ping-result": { 
                "total-count": "16", 
                "created-time": "1656309069018", 
                "project-ping-result": [ 
                    { 
                        "id": 1, 
                        "project-name": "p1", 
                        "domain-name": "DEFAULT", 
                        "status": "Inactive", 
                        "ping-result": "SUCCEEDED" 
                    }, 
                    … 
                    { 
                        "id": 24, 
                        "project-name": "new_p2", 
                        "domain-name": "A", 
                        "status": "Active", 
                        "ping-result": "SUCCEEDED" 
                    } 
                ] 
            }, 
            "projects-last-login-activity": { 
                "total-count": "9", 
                "created-time": "1656309066384", 
                "project-last-login-activity": [ 
                    { 
                        "id": 23, 
                        "project-name": "new_p", 
                        "domain-name": "A", 
                        "last-login-time": 1656298885000 
                    }, 
               … 
                    { 
                        "id": 24, 
                        "project-name": "new_p2", 
                        "domain-name": "A", 
                        "last-login-time": 1656145476000 
                    } 
                ] 
            }, 
            "active-sessions": { 
                "total-count": "1", 
                "created-time": "1656309066371", 
                "active-session": [ 
                    { 
                        "project-id": 23, 
                        "project-name": "new_p", 
                        "domain-name": "A", 
                        "session-info": [ 
                            { 
                                "client-type": "Application Lifecycle Management Client UI", 
                                "session-count": 1 
                            } 
                        ] 
                    } 
                ] 
            }, 
            "projects-repository-size": { 
                "total-results": "8", 
                "created-time": "1656309110153", 
                "project-repository-size": [ 
                    { 
                        "id": 1, 
                        "project-name": "p1", 
                        "domain-name": "DEFAULT", 
                        "repository-size": 1509338, 
                        "recyclable-size": 22248 
                    }, 
                   … 
                    { 
                        "id": 24, 
                        "project-name": "new_p2", 
                        "domain-name": "A", 
                        "repository-size": 1531586, 
                        "recyclable-size": 22248 
                    } 
                ] 
            }, 
            "projects-db-space-used": { 
                "total-count": "16", 
                "created-time": "1656309068342", 
                "project-db-space-used": [ 
                    { 
                        "id": 1, 
                        "project-name": "p1", 
                        "domain-name": "DEFAULT", 
                        "db-server-name": "127.0.0.1", 
                        "db-server-type": "ORACLE", 
                        "actual-space-used": 4388683776 
                    }, 
                   … 
                    { 
                        "id": 24, 
                        "project-name": "new_p2", 
                        "domain-name": "A", 
                        "db-server-name": "127.0.0.1", 
                        "db-server-type": "ORACLE", 
                        "actual-space-used": 4388683776 
                    } 
                ] 
            } 
        } 

Back to top

See also: