Protocol Documentation
Table of Contents
Top
onos/topo/topo.proto
CreateRequest
| Field | Type | Label | Description |
| object | Object | | |
CreateResponse
| Field | Type | Label | Description |
| object | Object | | |
DeleteRequest
DeleteResponse
Entity
Entity represents any "thing" that is represented in the topology
| Field | Type | Label | Description |
| kind_id | string | | user-defined entity kind |
| src_relation_ids | string | repeated | these lists are maintained by the system and are provided as read-only values for clients |
| tgt_relation_ids | string | repeated | |
EqualFilter
| Field | Type | Label | Description |
| value | string | | |
Event
Event is a topo operation event
Filter
Filters
GetRequest
| Field | Type | Label | Description |
| id | string | | |
GetResponse
| Field | Type | Label | Description |
| object | Object | | |
InFilter
| Field | Type | Label | Description |
| values | string | repeated | |
Kind
Kind represents an archetype of an object, i.e. entity or relation
| Field | Type | Label | Description |
| name | string | | Friendly name of the kind |
ListRequest
DEPRECATED
ListResponse
DEPRECATED
| Field | Type | Label | Description |
| objects | Object | repeated | |
NotFilter
| Field | Type | Label | Description |
| inner | Filter | | |
Object
Object is an one of the following: a kind (archetype of entity or relation), an entity, a relation
Object.AspectsEntry
Object.LabelsEntry
QueryRequest
| Field | Type | Label | Description |
| filters | Filters | | |
QueryResponse
| Field | Type | Label | Description |
| object | Object | | |
Relation
Relation represents any "relation" between two entitites in the topology.
| Field | Type | Label | Description |
| kind_id | string | | user defined relation kind |
| src_entity_id | string | | |
| tgt_entity_id | string | | |
RelationFilter
Filter for targets of given relation kinds and given source ids; optionally, filters by specified target kind
UpdateRequest
| Field | Type | Label | Description |
| object | Object | | |
UpdateResponse
| Field | Type | Label | Description |
| object | Object | | |
WatchRequest
| Field | Type | Label | Description |
| filters | Filters | | |
| noreplay | bool | | |
WatchResponse
| Field | Type | Label | Description |
| event | Event | | |
EventType
EventType is a topo operation event type
| Name | Number | Description |
| NONE | 0 | |
| ADDED | 1 | |
| UPDATED | 2 | |
| REMOVED | 3 | |
Object.Type
| Name | Number | Description |
| UNSPECIFIED | 0 | |
| ENTITY | 1 | |
| RELATION | 2 | |
| KIND | 3 | |
RelationFilterScope
| Name | Number | Description |
| TARGETS_ONLY | 0 | Indicates only the target entities are desired when searching by src_id, or source entities when searching by target_id |
| ALL | 1 | Indicated source, target entities and all relations are desired |
| SOURCE_AND_TARGETS | 2 | Indicates only source and target entities are desired, regardless of search criteria |
| RELATIONS_ONLY | 3 | Indicates only relations are desired; no entities |
| RELATIONS_AND_TARGETS | 4 | Indicates only relations and target entities desired when searching by src_id, or relations and source entities when searching by target_id |
SortOrder
| Name | Number | Description |
| UNORDERED | 0 | |
| ASCENDING | 1 | |
| DESCENDING | 2 | |
Topo
EntityService provides an API for managing entities.
Scalar Value Types
| .proto Type | Notes | C++ | Java | Python | Go | C# | PHP | Ruby |
| double | | double | double | float | float64 | double | float | Float |
| float | | float | float | float | float32 | float | float | Float |
| int32 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| int64 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| uint32 | Uses variable-length encoding. | uint32 | int | int/long | uint32 | uint | integer | Bignum or Fixnum (as required) |
| uint64 | Uses variable-length encoding. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum or Fixnum (as required) |
| sint32 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| sint64 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| fixed32 | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | int | uint32 | uint | integer | Bignum or Fixnum (as required) |
| fixed64 | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum |
| sfixed32 | Always four bytes. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| sfixed64 | Always eight bytes. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| bool | | bool | boolean | boolean | bool | bool | boolean | TrueClass/FalseClass |
| string | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | str/unicode | string | string | string | String (UTF-8) |
| bytes | May contain any arbitrary sequence of bytes. | string | ByteString | str | []byte | ByteString | string | String (ASCII-8BIT) |