queryJob


URI

<query_uri>/{JobID}[.<format>]

Supported methods

GET, HEAD

Parent resource

query

Introduction

queryJob resource indicates a query job of single object. Gets the detail configuration information of single object query job by ID through sending GET request to queryJob resource.

Supported Methods:

Supported output formats: rjson, json, html, xml.

Resource hierarchy

HTTP request methods

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

http://supermapiserver:8090/iserver/services/distributedanalyst/rest/v1/jobs/spatialanalyst/query/{jobID}.rjson

GET request

Gets the detail configuration information of single object query job

Response structure

Execute a GET request on the queryJob resource. The representation structure for the returned resource is like this:  

Field Type Description
id String Application ID.
state Jobstate The task status. Including execution status, start time, time consuming, and so on.
setting JobSetting Lists the detail information of current task.

Response example

Sending GET request to queryJob resource http://supermapiserver:8090/iserver/services/distributedanalyst/rest/v1/jobs/spatialanalyst/query/b604dfb0_fa16_44ff_b79f_426638ce34ca.rjson, the description for the returned rjson is:

{

  "id": "b604dfb0_fa16_44ff_b79f_426638ce34ca",

  "setting": {

    "DEFAULT_MASTER_ADRESS": "local[*] ",

    "analyst": {

      "datasetQuery": "Line",

      "inputQuery": "F:\\20170527_bsp.jar\\test\\data_toIserver.udb",

      "mode": "CONTAIN",

      "numSlices": "20"

    },

    "appName": "query",

    "args": [

      "--inputSource",

      "F:\\20170527_bsp.jar\\test\\data_toIserver.udb",

      "--datasetSource",

      "Region",

      "--numSlices",

      "20",

      "--inputQuery",

      "F:\\20170527_bsp.jar\\test\\data_toIserver.udb",

      "--datasetQuery",

      "Line",

      "--mode",

      "CONTAIN",

      "--outputResult",

      "F:\\20170621\\supermapiserver\\webapps\\iserver\\processingResultData\\Analyst\\udbs\\213b0cd1-a7db-474f-afe3-242787c31c05",

      "--datasetResult",

      "analystResult"

    ],

    "contextSetting": null,

    "input": {

      "datasetSource": "Region",

      "inputSource": "F:\\20170527_bsp.jar\\test\\data_toIserver.udb"

    },

    "mainClass": "com.supermap.bsp.main.SpatialQueryGeoMain",

    "output": {

      "cacheName": null,

      "cacheType": null,

      "datasetResult": "analystResult",

      "outputResult": "F:\\20170621\\supermapiserver\\webapps\\iserver\\processingResultData\\Analyst\\udbs\\213b0cd1-a7db-474f-afe3-242787c31c05"

    },

    "serviceInfo": {

      "targetDataPath": "F:\\20170621\\supermapiserver\\webapps\\iserver\\processingResultData\\Analyst\\b604dfb0_fa16_44ff_b79f_426638ce34ca",

      "targetServiceInfos": [

        {

          "serviceAddress": "http://supermapiserver:8090/iserver/services/data-spatialQueryGeo5/rest",

          "serviceType": "RESTDATA"

        },

        {

          "serviceAddress": "http://supermapiserver:8090/iserver/services/map-spatialQueryGeo5/rest",

          "serviceType": "RESTMAP"

        }

      ]

    },

    "serviceRoot": "http://supermapiserver:8090/iserver/services/"

  },

  "state": {

    "elapsedTime": 7373,

    "endState": true,

    "endTime": 1498027044443,

    "errorMsg": null,

    "errorStackTrace": null,

    "publisherelapsedTime": 2148,

    "runState": "FINISHED",

    "startTime": 1498027034501

  }

}

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 queryJob resource exists, or if the queryJob resource can be accessed by clients. It can also determine if the queryJob resource supports an output format <format> if performed on a URI with .<format> included.

See