Skip to content

Commit 8ffd623

Browse files
authored
fix: ROS 2 operation binding
1 parent 03507d8 commit 8ffd623

File tree

1 file changed

+61
-55
lines changed

1 file changed

+61
-55
lines changed

bindings/ros2/0.1.0/operation.json

Lines changed: 61 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1,82 +1,88 @@
11
{
2-
"type": "object",
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"$id": "http://asyncapi.com/bindings/ros2/0.1.0/operation.json",
34
"description": "This object contains information about the operation representation in ROS 2.",
4-
"additionalProperties": false,
5-
"patternProperties": {
6-
"^x-[\\w\\d\\.\\x2d_]+$": {
7-
"$ref": "http://asyncapi.com/definitions/3.0.0/specificationExtension.json"
8-
}
9-
},
10-
"required": [
11-
"role",
12-
"node"
5+
"examples": [
6+
{
7+
"node": "/turtlesim",
8+
"qosPolicies": {
9+
"deadline": "-1",
10+
"durability": "volatile",
11+
"history": "unknown",
12+
"leaseDuration": "-1",
13+
"lifespan": "-1",
14+
"liveliness": "automatic",
15+
"reliability": "reliable"
16+
},
17+
"role": "subscriber"
18+
}
1319
],
20+
"type": "object",
21+
"required": [ "role", "node" ],
1422
"properties": {
15-
"role": {
23+
"bindingVersion": {
24+
"description": "The version of this binding. If omitted, 'latest' MUST be assumed.",
1625
"type": "string",
17-
"description": "Specifies the ROS 2 type of the node for this operation.",
18-
"enum": ["publisher", "action_client", "service_client", "subscriber", "action_server", "service_server"]
26+
"enum": [ "0.1.0" ]
1927
},
2028
"node": {
21-
"type": "string",
22-
"description": "The name of the ROS 2 node that implements this operation."
29+
"description": "The name of the ROS 2 node that implements this operation.",
30+
"type": "string"
2331
},
2432
"qosPolicies": {
2533
"type": "object",
2634
"properties": {
27-
"reliability": {
28-
"type": "string",
29-
"description": "Specifies the communication guarantee model that determines whether message delivery confirmation between publisher and subscriber is required.",
30-
"enum": ["best_effort", "realiable"]
35+
"deadline": {
36+
"description": "The expected maximum amount of time between subsequent messages being published to a topic. -1 means infinite.",
37+
"type": "integer"
38+
},
39+
"durability": {
40+
"description": "Persistence specification that determines message availability for late-joining subscribers",
41+
"type": "string",
42+
"enum": [ "transient_local", "volatile" ]
3143
},
3244
"history": {
33-
"type": "string",
34-
"description": "Policy parameter that defines the maximum number of samples maintained in the middleware queue",
35-
"enum": ["keep_last", "keep_all", "unknown"]
45+
"description": "Policy parameter that defines the maximum number of samples maintained in the middleware queue",
46+
"type": "string",
47+
"enum": [ "keep_last", "keep_all", "unknown" ]
3648
},
37-
"durability": {
38-
"type": "string",
39-
"description": "Persistence specification that determines message availability for late-joining subscribers",
40-
"enum": ["transient_local", "volatile"]
49+
"leaseDuration": {
50+
"description": "The maximum period of time a publisher has to indicate that it is alive before the system considers it to have lost liveliness. -1 means infinite.",
51+
"type": "integer"
4152
},
4253
"lifespan": {
43-
"type": "integer",
44-
"description": "The maximum amount of time between the publishing and the reception of a message without the message being considered stale or expired. -1 means infinite."
45-
},
46-
"deadline": {
47-
"type": "integer",
48-
"description": "The expected maximum amount of time between subsequent messages being published to a topic. -1 means infinite."
54+
"description": "The maximum amount of time between the publishing and the reception of a message without the message being considered stale or expired. -1 means infinite.",
55+
"type": "integer"
4956
},
5057
"liveliness": {
51-
"type": "string",
52-
"description": "Defines the mechanism by which the system monitors and determines the operational status of communication entities within the network.",
53-
"enum": ["automatic", "manual"]
58+
"description": "Defines the mechanism by which the system monitors and determines the operational status of communication entities within the network.",
59+
"type": "string",
60+
"enum": [ "automatic", "manual" ]
5461
},
55-
"leaseDuration": {
56-
"type": "integer",
57-
"description": "The maximum period of time a publisher has to indicate that it is alive before the system considers it to have lost liveliness. -1 means infinite."
62+
"reliability": {
63+
"description": "Specifies the communication guarantee model that determines whether message delivery confirmation between publisher and subscriber is required.",
64+
"type": "string",
65+
"enum": [ "best_effort", "realiable" ]
5866
}
5967
}
6068
},
61-
"bindingVersion": {
69+
"role": {
70+
"description": "Specifies the ROS 2 type of the node for this operation.",
6271
"type": "string",
6372
"enum": [
64-
"0.1.0"
65-
],
66-
"description": "The version of this binding. If omitted, 'latest' MUST be assumed."
73+
"publisher",
74+
"action_client",
75+
"service_client",
76+
"subscriber",
77+
"action_server",
78+
"service_server"
79+
]
6780
}
6881
},
69-
"examples": {
70-
"role": "subscriber",
71-
"node": "/turtlesim",
72-
"qosPolicies": {
73-
"history": "unknown",
74-
"reliability": "reliable",
75-
"durability": "volatile",
76-
"lifespan": "-1",
77-
"deadline": "-1",
78-
"liveliness": "automatic",
79-
"leaseDuration": "-1"
82+
"patternProperties": {
83+
"^x-[\\w\\d\\.\\x2d_]+$": {
84+
"$ref": "http://asyncapi.com/definitions/3.0.0/specificationExtension.json"
8085
}
81-
}
82-
}
86+
},
87+
"additionalProperties": false
88+
}

0 commit comments

Comments
 (0)