Skip to content

Commit

Permalink
Merge pull request #1 from iotmodels/math-server
Browse files Browse the repository at this point in the history
math server
  • Loading branch information
rido-min authored Jul 1, 2023
2 parents 8c22450 + df7d736 commit 21b766f
Showing 1 changed file with 80 additions and 0 deletions.
80 changes: 80 additions & 0 deletions dtmi/rpc/example/mathserver-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"@context": [
"dtmi:dtdl:context;2",
"dtmi:dtdl:bindings:mqtt;1"
],
"@id": "dtmi:rpc:example:mathServer;1",
"@type": "Interface",
"displayName": "mqtt_commands",
"contents": [
{
"@type": [ "Command", "mqtt" ],
"name": "isPrime",
"mqttContentType": "json",
"mqttRequestTopic": "math/service/isPrime",
"request": {
"name": "isPrimeRequest",
"schema": {
"@type": "Object",
"fields": [
{

"name": "number",
"schema": "integer"
},
{

"name": "invokerStartTime",
"schema": "integer"
},
{
"name": "invokerId",
"schema": "string"
}
]
}
},
"response": {
"name": "isPrimeResponse",
"schema": {
"@type": "Object",
"fields": [
{

"name": "number",
"schema": "integer"
},
{
"name": "isPrime",
"schema": "boolean"
},
{
"name": "ops",
"schema": {
"@type": "Array",
"elementSchema": "string"
}
},
{
"name": "invokerId",
"schema": "string"
},
{
"name": "executorId",
"schema": "string"
},
{
"name": "computeMS",
"schema": "long"
},
{
"name": "threadId",
"schema": "integer"
}
]
}

}
}
]
}

0 comments on commit 21b766f

Please sign in to comment.