serviceStatus


URI

<service_uri>/status[.<format>]

Supported methods

GET, PUT, HEAD

Parent resource

service

Introduction

View the service status information according to the service ID.

Supported Methods:

Supported output formats: RJSON, JSON, HTML, XML.

Resource hierarchy

HTTP request methods

Implement the HTTP request on the following URI, where supermapiportal is the server name, with rjson being the output format.

http://supermapiportal:8090/iportal/web/services/{id}/status.rjson

GET request

Check the service is available or not according to the specified service ID.

Response example

Execute GET request for serviceStatus resource: http://localhost:8090/iportal/web/services/1/status.rjson, and check the service is available or not. The response result in rjson format returned is as follows:

true

PUT request

The service update is available or not according to the service ID.

Response structure

The structure of the response resource representation is as follows:

Field Type Description
succeed boolean Whether new service is updated successfully or not.
error Httperror Error information. This field will not be displayed if it is updated successfully.

Response example

Execute PUT request for serviceStatus resource: http://localhost:8090/iportal/web/services/1/status.rjson, and update the service as disabled. The request body is as follows:

false

The response result in rjson format returned is as follows:

{ "succeed": true}

Execute PUT request for serviceStatus resource: http://localhost:8090/iportal/web/services/1/status.rjson, and update the service as enabled. The request body is as follows:

true

The response result in rjson format returned is as follows:

{ "succeed": true}

HEAD request

Asks for the response identical to the one that would correspond to a GET request, but without the response body. This is useful for retrieving meta-information written in response headers, without having to transport the entire content. The meta-information includes the media-type, content-encoding, transfer-encoding, content-length, etc.

HEAD request can be used to check if the serviceStatus resource exists, or if the serviceStatus resource can be accessed by clients. It can also determine if the serviceStatus resource supports an output format <format> if performed on a URI with .<format> included.

See