REST API plug-in status
Overview
This page documents how to know the status of the RESTAPI Plug-in and its components, if it is operational, or partially operational, if errors or faults have been detected that prevent the operation of certain services, partially or completely. Apart from very particular errors at startup, which make the API non-operational at startup, it is possible that the status changes in the course of time, if another component on which the API depends changes its status.
API Status Page
Overview
This page displays the list of the different main components of the RESTAPI plugin, their state and some information for some components. The state of a component may depend on the state of subcomponents or dependencies, in synthesis, or in exception, or on an event at startup. The state of a component can also change if the states on which it depends change.
Show API Status Page
Go to the REST API administration, then click on the following selector, or press key “:” :
Or use the URI /_plugins/WXM_RESTAPI/page/admin/pluginstatus/admin.jspz
Access
The roles that have access to this page are:
Administrators
Developer
Watchers
ApiOperators
ApiWatchers
ApiTesters
API Global status
2021.3
The global status is a summary of the status of the main API components and is displayed as an icon in the header area of the REST API administration, for example :
You can click on the icon to get a more detailed view.
There is also a service that allows to know the status (see below).
Java-coded extension components status
This page displays the status of extension, contribution, or customization components written in Java, and the JARs containing them and their respective plugins.
A synthesis of these states is present in the status page
Services
Get global API status
URI: /api/rest/status
Content-Type: text/plain
This endpoint allows you to obtain the global status.
Verbose mode
URI: /api/rest/status?verbose
Content-Type: application/json
This endpoint allows to obtain the global state, with the global state of each component. This endpoint is secured and accessible to these roles:
Administrators
Developer
Watchers
TestOperators
ApiOperators
ApiWatchers
ApiTesters
Logs
The logs remain the most complete way to determine the state of the API and the reasons for that state. In particular, exceptions detected during configuration loading that lead to default component selections are not taken into account when establishing the API state.
Monotoring and engine status
2021.4.0
The status of the WXM_RESTAPI plug-in goes up in the general status of the engine (retrievable via API services /api/wedia/admin/monitoring) and is displayed in the plugins administration page:
You can see it also in the WXM_RESTAPI plugin configuration page:
For some services with dependencies on a third party service, it is not always possible to detect state changes synchronously. The only way to be sure that the state of the plugin is up to date is to force the analysis of the states of third party components by invoking the /api/rest/status service. At startup, the plugin state at least accurately reflects the startup errors of the plugin or subcomponents. Most of the state changes that occur afterwards involve degradations instead, with the exception of extension and contribution components, in case of contribution plugin reload. It is anyway advisable to restart the WXM_RESTAPI plugin in this case.
Tips
The extension components (Business Services) are loaded when the RESTAPI plugin is started. If a contribution plug-in is restarted in isolation, it is essential to restart the RESTAPI plug-in afterwards to take into account the new components provided by the contribution plug-in.