'dmsbatch' capability for WebSocket Token API
Overview
Provides an interface for group CRUD operations on dynamic class entities.
It provides noticeable time savings on request and response transfers between different machines along the path from the connection client to the DMS server during sequential synchronous operation execution.
[
"dmsbatch",
{
"qid": 0.1234,
"classpath": "/rest/v1/model/SomeClass",
"sync": true,
"timeout": 20000,
"batches": [
{
"operation": "update",
"id": ...,
"content": {"someProperty1": ..., "someProperty2": ...}
},
{
"operation": "read",
"filter": ["==",["property","someProperty1"],...]
},
...
]
}
]
[
"dmsbatch_result",
{
"qid": 0.1234,
"result": ok,
"batches": [
{
"result": "ok",
"content": ...
},
{
"result": "ok",
"content": ...
},
...
]
}
]
Each request and its corresponding response are packed into an element of the batches array. The response sequence strictly corresponds to the request sequence. If a request fails, the error is also placed in the corresponding position of the batches array in the response. The overall result is always "ok".
On timeout (default 60000 = 60 seconds), requests that failed to complete receive an error with a timeout code.
Each request is subject to the same conditions, capabilities, and restrictions as when executing a separate rest request to dynamic classes.
-
Request construction is similar to WebSocket User API.