diff --git a/basics/permissions.adoc b/basics/permissions.adoc index adbe4de..ccd125a 100644 --- a/basics/permissions.adoc +++ b/basics/permissions.adoc @@ -78,7 +78,7 @@ While inspired by Android’s permission, CAPs under the current proposal are di === Service Declaration of uPLs -Services declare their uPLs as google.protobuf CustomOptions within their protos. The options are declared in link:../../up-core-api/uprotocol/uprotocol_options.proto[uprotocol_options.proto] and their purpose is defined in <> below. +Services declare their uPLs as google.protobuf CustomOptions within their protos. The options are declared in link:../up-core-api/uprotocol/uoptions.proto[uoptions.proto] and their purpose is defined in <> below. * uPL value *MUST* be an integer, 0 to N, where N is the most permissive level. The default value is 0. diff --git a/up-core-api/uprotocol/core/udiscovery/v3/udiscovery.proto b/up-core-api/uprotocol/core/udiscovery/v3/udiscovery.proto index 247a985..0a55366 100644 --- a/up-core-api/uprotocol/core/udiscovery/v3/udiscovery.proto +++ b/up-core-api/uprotocol/core/udiscovery/v3/udiscovery.proto @@ -15,9 +15,9 @@ syntax = "proto3"; package uprotocol.core.udiscovery.v3; import "google/protobuf/timestamp.proto"; -import "uprotocol_options.proto"; -import "uri.proto"; -import "ustatus.proto"; +import "uoptions.proto"; +import "v1/uri.proto"; +import "v1/ustatus.proto"; option java_package = "org.eclipse.uprotocol.core.udiscovery.v3"; option java_outer_classname = "UDiscoveryProto"; @@ -25,13 +25,13 @@ option java_multiple_files = true; // Platform USE Discovery Service Interface service uDiscovery { - option (name) = "core.udiscovery"; // Service name - option (version_major) = 3; - option (version_minor) = 0; - option (id) = 1; + option (uprotocol.service_name) = "core.udiscovery"; // Service name + option (uprotocol.service_version_major) = 3; + option (uprotocol.service_version_minor) = 0; + option (uprotocol.service_id) = 1; // uDiscovery Node Change Notification that sends the Update message - option (notification_topic) = { + option (uprotocol.notification_topic) = { id: 0x8000, name: "NodeChange", message: "Notification" @@ -48,14 +48,14 @@ service uDiscovery { // 3. code.INVALID_ARGUMENT: The passed UUri is invalid // 4. code.PERMISSION_DENIED: The caller does not have permission to perform the query rpc LookupUri(v1.UUri) returns (LookupUriResponse) { - option (method_id) = 1; + option (uprotocol.method_id) = 1; } // Update a node in the database. // What is returned is the status of the API request as uprotocol.v1.UStatus. // **NOTE:** You MUST have write permission to the node in the database rpc UpdateNode(UpdateNodeRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 2; + option (uprotocol.method_id) = 2; } // Query the database to find Node(s). What is passed is the search criterial in @@ -68,12 +68,12 @@ service uDiscovery { // 4. uResource: `//device.domain/body.access//door.door_front_left` // **NOTE:** You MUST have read permission to the node in the database rpc FindNodes(FindNodesRequest) returns (FindNodesResponse) { - option (method_id) = 3; + option (uprotocol.method_id) = 3; } // Query the database to fetch a list of 1 or more properties for a given node. rpc FindNodeProperties(FindNodePropertiesRequest) returns (FindNodePropertiesResponse) { - option (method_id) = 4; + option (uprotocol.method_id) = 4; } // Remove one or more nodes (and all its children nodes) in the database. @@ -82,7 +82,7 @@ service uDiscovery { // all the children nodes, as well as write permission to the parent otherwise // you will get PERMISSION_DENIED and no nodes will be deleted. rpc DeleteNodes(DeleteNodesRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 5; + option (uprotocol.method_id) = 5; } @@ -90,7 +90,7 @@ service uDiscovery { // ALREADY_EXISTS and none of the nodes shall be added to the parent. // **NOTE:** You MUST have write permission to the parent node rpc AddNodes(AddNodesRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 6; + option (uprotocol.method_id) = 6; } @@ -98,20 +98,20 @@ service uDiscovery { // **NOTE:** You MUST have write permission to the node who's property you // are updating rpc UpdateProperty(UpdatePropertyRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 7; + option (uprotocol.method_id) = 7; } // Register to receive Notifications to changes to one of more Nodes. The changes // are published on the notification topic: '/core.udiscovery/3/nodes#Notification' rpc RegisterForNotifications(NotificationsRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 8; + option (uprotocol.method_id) = 8; } // Unregister for Node change notifications rpc UnregisterForNotifications(NotificationsRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 9; + option (uprotocol.method_id) = 9; } @@ -123,7 +123,7 @@ service uDiscovery { // - code.INVALID_ARGUMENT: The passed UUri is invalid (missing names or numbers) // - code.PERMISSION_DENIED: The caller does not have permission to perform the resolution rpc ResolveUri(ResolveUriRequest) returns (ResolveUriResponse) { - option (method_id) = 10; + option (uprotocol.method_id) = 10; } } @@ -344,17 +344,3 @@ message LookupUriResponse { v1.UUriBatch uris = 1; // Batch of Uris uprotocol.v1.UStatus status = 2; // Return code for the rpc call } - - -// Node Notification Topic -// Service Meta-data structure used to build the notification topic when there are -// changes to a Node in the database. This message build the topic: -// '/core.udiscovery/3/nodes#Notification'. -// **NODE:** This message definition is ONLY used to autogenerate the Node Change Notification topic. -message NodeNotificationTopic { - // Service meta-data option definition - Topic identity - option (base_topic_id) = 1000; - - // Meta flags for generating the YAML - Notification.Resources resource_name = 1 [(resource_name_mask) = "*"]; -} \ No newline at end of file diff --git a/up-core-api/uprotocol/core/usubscription/v3/usubscription.proto b/up-core-api/uprotocol/core/usubscription/v3/usubscription.proto index fd0d421..4192960 100644 --- a/up-core-api/uprotocol/core/usubscription/v3/usubscription.proto +++ b/up-core-api/uprotocol/core/usubscription/v3/usubscription.proto @@ -17,9 +17,9 @@ package uprotocol.core.usubscription.v3; import "google/protobuf/any.proto"; import "google/protobuf/timestamp.proto"; -import "ustatus.proto"; -import "uri.proto"; -import "uprotocol_options.proto"; +import "v1/ustatus.proto"; +import "v1/uri.proto"; +import "uoptions.proto"; option java_package = "org.eclipse.uprotocol.core.usubscription.v3"; option java_outer_classname = "USubscriptionProto"; @@ -27,13 +27,13 @@ option java_multiple_files = true; // Subscription Service Interface definition service uSubscription { - option (name) = "core.usubscription"; // Service name - option (version_major) = 3; - option (version_minor) = 0; - option (id) = 0; + option (uprotocol.service_name) = "core.usubscription"; // Service name + option (uprotocol.service_version_major) = 3; + option (uprotocol.service_version_minor) = 0; + option (uprotocol.service_id) = 0; // uSubscription change Notification topic that sends the Update message - option (notification_topic) = { + option (uprotocol.notification_topic) = { id: 0x8000, name: "SubscriptionChange", message: "Update" @@ -49,35 +49,35 @@ service uSubscription { // to received subscription change notifications if ever the subscription state // changes. rpc Subscribe(SubscriptionRequest) returns (SubscriptionResponse) { - option (method_id) = 1; + option (uprotocol.method_id) = 1; } // The consumer no longer wishes to subscribe to a topic so it issues an // explicit unsubscribe request. rpc Unsubscribe(UnsubscribeRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 2; + option (uprotocol.method_id) = 2; } // Fetch a list of subscriptions rpc FetchSubscriptions(FetchSubscriptionsRequest) returns (FetchSubscriptionsResponse) { - option (method_id) = 3; + option (uprotocol.method_id) = 3; } // Register to receive subscription change notifications that are published on the // 'up:/core.usubscription/3/subscriptions#Update' rpc RegisterForNotifications(NotificationsRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 6; + option (uprotocol.method_id) = 6; } // Unregister for subscription change events rpc UnregisterForNotifications(NotificationsRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 7; + option (uprotocol.method_id) = 7; } // Fetch a list of subscribers that are currently subscribed to a given topic. rpc FetchSubscribers(FetchSubscribersRequest) returns (FetchSubscribersResponse) { - option (method_id) = 8; + option (uprotocol.method_id) = 8; } // Reset subscriptions to and from the uSubscription Service. @@ -88,7 +88,7 @@ service uSubscription { // **__NOTE:__** This is a private API only for uSubscription services, // uEs can call Unsubscribe() to flush their own subscriptions. rpc Reset(ResetRequest) returns (uprotocol.v1.UStatus) { - option (method_id) = 9; + option (uprotocol.method_id) = 9; } } diff --git a/up-core-api/uprotocol/core/utwin/v2/utwin.proto b/up-core-api/uprotocol/core/utwin/v2/utwin.proto index facc176..46b5b0b 100644 --- a/up-core-api/uprotocol/core/utwin/v2/utwin.proto +++ b/up-core-api/uprotocol/core/utwin/v2/utwin.proto @@ -15,10 +15,10 @@ syntax = "proto3"; package uprotocol.core.utwin.v2; -import "uprotocol_options.proto"; -import "ustatus.proto"; -import "uri.proto"; -import "umessage.proto"; +import "uoptions.proto"; +import "v1/ustatus.proto"; +import "v1/uri.proto"; +import "v1/umessage.proto"; option java_package = "org.eclipse.uprotocol.core.utwin.v2"; option java_outer_classname = "UTwinProto"; @@ -26,10 +26,10 @@ option java_multiple_files = true; // uTwin Service interface definition service uTwin { - option (name) = "core.utwin"; // Service name - option (version_major) = 2; - option (version_minor) = 0; - option (id) = 26; + option (uprotocol.service_name) = "core.utwin"; // Service name + option (uprotocol.service_version_major) = 2; + option (uprotocol.service_version_minor) = 0; + option (uprotocol.service_id) = 26; // A uE calls this API to retrieve the last uMessages for a given set of topics.
// What is returned is a list of MessageResponse with the status for message retreival @@ -37,7 +37,7 @@ service uTwin { // status for those messages that it was unable to fetch (i.e. due to NOT_FOUND // or PERMISSION_DENIED.
rpc GetLastMessages(uprotocol.v1.UUriBatch) returns (GetLastMessagesResponse) { - option (method_id) = 1; + option (uprotocol.method_id) = 1; } // A call to SetLasMessage (typically from uBus) to update the uTwin internal cache @@ -48,7 +48,7 @@ service uTwin { // - PERMISSION_DENIED if requesting uE does not have permission to access the Topic // - RESOURCE_EXHAUSTED if uTwin has no more memory available to store new UMessages rpc SetLastMessage(uprotocol.v1.UMessage) returns (uprotocol.v1.UStatus) { - option (method_id) = 2; + option (uprotocol.method_id) = 2; } } diff --git a/up-core-api/uprotocol/uoptions.proto b/up-core-api/uprotocol/uoptions.proto new file mode 100644 index 0000000..bd49700 --- /dev/null +++ b/up-core-api/uprotocol/uoptions.proto @@ -0,0 +1,288 @@ +/* + * SPDX-FileCopyrightText: 2023 Contributors to the Eclipse Foundation + * + * See the NOTICE file(s) distributed with this work for additional + * information regarding copyright ownership. + * + * This program and the accompanying materials are made available under + * the terms of the Apache License Version 2.0 which is available at + * https://www.apache.org/licenses/LICENSE-2.0 + * + * SPDX-FileType: SOURCE + * SPDX-License-Identifier: Apache-2.0 + */ + +syntax = "proto3"; + +package uprotocol; + +import "google/protobuf/descriptor.proto"; + +option java_package = "org.eclipse.uprotocol"; +option java_multiple_files = true; + + +///////////////////////////////////////////////////////// +// RESERVED UPROTOCOL OPTION IDS +// +// File 51000 - 51099 +// Service 51100 - 51199 +// Method 51200 - 51299 +// Message 51300 - 51399 +// Field 51400 - 51499 +// Enum 51500 - 51599 +// EnumValue 51600 - 51699 +// + +// uProtocol options for a proto File +extend google.protobuf.FileOptions { + + // Specifies whether this file is SOME/IP compatible. + // Enabling this option ensures that all messages defined + // in this file conform strictly to the SOME/IP fixed-size + // serialization format, which requires all fields to have + // predetermined and constant sizes. + optional bool file_someip = 51000; + +} + +// uProtocol options for a service definition +extend google.protobuf.ServiceOptions { + + // Service id (0x0000 - 0xFFFF). + // The service id must be globally unique. + uint32 service_id = 51100; + + // Service name (e.g., "MyService"). + // The service name must be globally unique. + string service_name = 51101; + + // Semantic 2.0 major versioning + uint32 service_version_major = 51102; + + // Semantic 2.0 minor versioning + optional uint32 service_version_minor = 51103; + + // Code Access Permission (CAP) Level for the uE + optional uint32 service_permission_level = 51104; + + // Service declared published topics + repeated UServiceTopic publish_topic = 51105; + + // Service declaired notification topics + repeated UServiceTopic notification_topic = 51106; + + // Specifies whether this service is SOME/IP compatible. + // Overrides the corresponding *file_someip* option on the file level. + // Enabling this option ensures that all messages used in this service + // conform strictly to the SOME/IP fixed-size serialization format. + optional bool service_someip = 51107; + +} + + +// uProtocol options for a method definition +extend google.protobuf.MethodOptions { + + // Method id (0x0000 - 0x7FFF). + // The method id must be unique within containing service scope. + uint32 method_id = 51200; + + // Code Access Permission (CAP) Level for the method + optional uint32 method_permission_level = 51201; + +} + + +// uProtocol options for a message definition +extend google.protobuf.MessageOptions { + + // Specifies whether this message is SOME/IP compatible. + // Overrides the corresponding *file_someip* option on the file level. + // Enabling this option ensures that the message conforms strictly to the + // SOME/IP fixed-size serialization format. + optional bool message_someip = 51300; + + // Fixed message size in bytes. This constraint is mainly intended for + // fixed-size encodings (e.g., SOME/IP) and is ignored by the standard + // protobuf encoding. + // + // - When omitted, the message size is automatically computed from the + // aggregate sum of all its member field sizes, including the sizes of + // nested messages to any depth level. + // + // - If the specified size is larger than the computed message size, the + // excess size is reseved as unused space at the end of the message. This + // allows for future extension and addition of new fields to the message + // without breaking compatibility. + // + // - Conversely, if the specified size is smaller than the computed message + // size, a compile-time error will be raised. + optional uint32 message_size = 51301; + +} + + +// uProtocol options for a field definition +extend google.protobuf.FieldOptions { + + // Field value size constraint. + // + // This constraint is mainly intended for fixed-size encodings (e.g., + // SOME/IP) and is ignored by the standard protobuf encoding. + // Applicable for the following field types: + // + // - **Integer fields**: Fixed integer size in bytes (1, 2, 4, or 8). + // For example, setting size=1 on a uint32 field (4 bytes) effectively + // reduces it to a uint8 field (1 byte). Integer field size can only be + // reduced, and cannot be made larger than the field's base size. The + // field's min/max/default values, if defined, must fit within the reduced + // field size. + // + // - **Enum fields**: Fixed enum size in bytes (1, 2, or, 4). If present, + // overrides the enum size defined on the enum declaration (see + // EnumOptions for details). If the enum size is left unspecified on both + // the field and the enum levels, then the enum size will default to 4 + // bytes. The enum size can be reduced only to the smallest size that + // still fits all its defined enum values. + // + // - **String fields**: Fixed string size in bytes. Note that the string + // size is measured in bytes and not in characters, and so the maximal + // string length depends on its character contents and on the text + // encoding used (utf-8, utf-16, etc). The string byte order mark (BOM) + // and null terminator (\0) are included in the allocated string size. + // + // - **Byte fields**: Fixed number of bytes. + // + // - **Repeated fields**: Fixed size of the array items (not the array + // itself). The number of items in the array can be specified using + // *field_count*. + // + // - **Map fields**: Fixed size of the map values. The fixed size of the map + // keys can be specified using *field_key_size*. The number of entries in + // the map can be specified using *field_count*. + // + optional uint32 field_size = 51400; + + // Field key size constraint. + // + // This constraint is mainly intended for fixed-size encodings (e.g., + // SOME/IP) and is ignored by the standard protobuf encoding. Applicable for + // the following field types: + // + // - **Map fields**: Fixed size of the map keys. The fixed size of the map + // values can be specified using *field_size*. + // + optional uint32 field_key_size = 51401; + + // Field items count constraint. + // + // This constraint is mainly intended for fixed-size encodings (e.g., + // SOME/IP) and is ignored by the standard protobuf encoding. Applicable for + // the following field types: + // + // - **Repeated fields**: Fixed number of items in the array. + // + // - **Map fields**: Fixed number of key/value entries in the map. + // + optional uint32 field_count = 51402; + +} + + +// uProtocol options for an enum definition +extend google.protobuf.EnumOptions { + + // Maximum enum size in bytes (if not specified, default is 4 bytes) + optional uint32 enum_size = 51500; + + // Specifies whether this enum is SOME/IP compatible. + // Overrides the corresponding *file_someip* option on the file level. + optional bool enum_someip = 51501; + +} + +// uProtocol options for an enum value definition +extend google.protobuf.EnumValueOptions { + + // MIME type mapping + optional string mime_type = 51600; + + // CloudEvent String representation of the uProtocol enum value + optional string ce_name = 51601; +} + + +// Service topic definition +message UServiceTopic { + + // Topic id (0x8000 - 0xFFFF). + // The topic id **MUST** be unique within the containing service scope. + uint32 id = 1; + + // Topic name. + // The topic name **MUST** be unique within the containing service scope. + string name = 2; + + // The topic message (defines the data passed in the topic). + // + // Both absolute and relative message names can be used, following the + // [Protobuf type name resolution rules](https://protobuf.dev/programming-guides/proto3/#name-resolution): + // + // 1. **Relative name:** partially-qualified name, resolved starting from the + // innermost scope to the outermost scope. + // 2. **Absolute name:** fully-qualified name with a leading `'.'`, resolved + // starting from the outermost scope instead. + // + // For example, with respect to a concrete service *foo.bar.Service*, the + // following topic message references are all equivalent: + // + // - *foo.bar.Topic* + // - *bar.Topic* + // - *Topic* + //
+ // + // **_NOTE:_** If the topic message is defined in a separate proto file, then + // this proto file must be explicitly imported into the proto file in which + // it is referenced, otherwise the message reference will not be resolved. + // + string message = 3; + + // One or more enumerated resource values that can be used to generate + // corresponding list of topics: + //

   [* resource_enum *] : [* resource_value *]

+ // + // Both absolute and relative resource enum names can be used, following the + // [Protobuf type name resolution rules](https://protobuf.dev/programming-guides/proto3/#name-resolution). + // If the resource name is relative, it will be resolved relative to the + // topic message. The *resource_enum* part is optional, and if omitted will + // default to "Resources". + // + // For example, with respect to a concrete topic message *foo.bar.Topic*, the + // following topic resource references are all equivalent: + // + // - *foo.bar.Topic.Resources* : \* + // - *bar.Topic.Resources* : \* + // - *Topic.Resources* : \* + // - *Resources* : \* + // - \* + //
+ // + // Topics can be defined automatically using the `"\*"` wildcard (e.g., + // `"Resources:*"`). This will create a separate topic per each resource + // instance, using the resource code/value to generate the topic id/uri. + // + // Topics with multiple resources can be defined using an array (e.g., + // `["front_left", "front_right"]`). The `"\*"` wildcard can also be used in + // this context (e.g., `["*"]`). This can be used to define a single topic + // that is triggered by a combination of multiple resources. + // + // **_NOTE:_** If a topic resource is defined in a separate proto file, then + // this proto file must be explicitly imported into the proto file in which + // it is referenced, otherwise the resource reference will not be resolved. + // + repeated string resources = 4; + + // Code Access Permission (CAP) Level for the topic + optional uint32 permission_level = 5; +} diff --git a/up-core-api/uprotocol/uprotocol_options.proto b/up-core-api/uprotocol/uprotocol_options.proto deleted file mode 100644 index 21a213f..0000000 --- a/up-core-api/uprotocol/uprotocol_options.proto +++ /dev/null @@ -1,92 +0,0 @@ -/* - * SPDX-FileCopyrightText: 2023 Contributors to the Eclipse Foundation - * - * See the NOTICE file(s) distributed with this work for additional - * information regarding copyright ownership. - * - * This program and the accompanying materials are made available under - * the terms of the Apache License Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0 - * - * SPDX-FileType: SOURCE - * SPDX-License-Identifier: Apache-2.0 - */ -syntax = "proto3"; - -package uprotocol; - -import "google/protobuf/descriptor.proto"; - -option java_package = "org.eclipse.uprotocol"; -option java_multiple_files = true; - -// Service Options & Attributes -extend google.protobuf.ServiceOptions { - // Name of the service that can be used in uri - string name = 51100; - - // Semantic 2.0 major versioning - uint32 version_major = 51101; - - // Semantic 2.0 minor versioning - uint32 version_minor = 51102; - - // Globally unique service id - uint32 id = 51103; - - // Code Access Permission (CAP) Level for the uE - uint32 permission_level = 51104; - - // Service declared published topics - repeated UServiceTopic publish_topic = 51105; - - // uService declaired notification topics - repeated UServiceTopic notification_topic = 51106; -} - - -extend google.protobuf.MethodOptions { - // RPC method id (unique within containing service) - optional uint32 method_id = 51200; - // Code Access Permission (CAP) Level for the method - uint32 method_permission_level = 51201; -} - - -extend google.protobuf.MessageOptions { - // Topic base id (unique within containing service) - // The topic base id is added to a resource id to form a specific topic id. - optional uint32 base_topic_id = 51300; - // Code Access Permission (CAP) Level for the topic - uint32 topic_permission_level = 51301; -} - - -extend google.protobuf.FieldOptions { - // Name mask for exported resources - optional string resource_name_mask = 51400; - -} - -extend google.protobuf.EnumValueOptions { - // MIME type mapping - optional string mime_type = 51500; - - // CloudEvent String representation of the uProtocol enum value - optional string ce_name = 51501; -} - - -// the following is used to declare service level topics, what a service publishes -message UServiceTopic { - // The topic id.
- // * *MUST* be unique within the uService scope - // * *MUST* start at 0x8000h - uint32 id = 1; - - // Topic name represented as a string - string name = 2; - - // Name of the protobuf.Message - string message = 3; -} \ No newline at end of file diff --git a/up-core-api/uprotocol/file.proto b/up-core-api/uprotocol/v1/file.proto similarity index 100% rename from up-core-api/uprotocol/file.proto rename to up-core-api/uprotocol/v1/file.proto diff --git a/up-core-api/uprotocol/uattributes.proto b/up-core-api/uprotocol/v1/uattributes.proto similarity index 98% rename from up-core-api/uprotocol/uattributes.proto rename to up-core-api/uprotocol/v1/uattributes.proto index b6ed431..ef52889 100644 --- a/up-core-api/uprotocol/uattributes.proto +++ b/up-core-api/uprotocol/v1/uattributes.proto @@ -15,10 +15,10 @@ syntax = "proto3"; package uprotocol.v1; -import "uri.proto"; -import "uuid.proto"; -import "ustatus.proto"; -import "uprotocol_options.proto"; +import "v1/uri.proto"; +import "v1/uuid.proto"; +import "v1/ustatus.proto"; +import "uoptions.proto"; option java_package = "org.eclipse.uprotocol.v1"; option java_outer_classname = "UAttributesProto"; diff --git a/up-core-api/uprotocol/umessage.proto b/up-core-api/uprotocol/v1/umessage.proto similarity index 96% rename from up-core-api/uprotocol/umessage.proto rename to up-core-api/uprotocol/v1/umessage.proto index 151bd9a..439f75e 100644 --- a/up-core-api/uprotocol/umessage.proto +++ b/up-core-api/uprotocol/v1/umessage.proto @@ -15,7 +15,7 @@ syntax = "proto3"; package uprotocol.v1; -import "uattributes.proto"; +import "v1/uattributes.proto"; option java_package = "org.eclipse.uprotocol.v1"; option java_outer_classname = "UMessageProto"; diff --git a/up-core-api/uprotocol/uri.proto b/up-core-api/uprotocol/v1/uri.proto similarity index 100% rename from up-core-api/uprotocol/uri.proto rename to up-core-api/uprotocol/v1/uri.proto diff --git a/up-core-api/uprotocol/ustatus.proto b/up-core-api/uprotocol/v1/ustatus.proto similarity index 100% rename from up-core-api/uprotocol/ustatus.proto rename to up-core-api/uprotocol/v1/ustatus.proto diff --git a/up-core-api/uprotocol/uuid.proto b/up-core-api/uprotocol/v1/uuid.proto similarity index 100% rename from up-core-api/uprotocol/uuid.proto rename to up-core-api/uprotocol/v1/uuid.proto diff --git a/up-l3/udiscovery/v3/README.adoc b/up-l3/udiscovery/v3/README.adoc index 202867d..f78d278 100644 --- a/up-l3/udiscovery/v3/README.adoc +++ b/up-l3/udiscovery/v3/README.adoc @@ -185,7 +185,7 @@ NOTE: Please see https://protobuf.dev/programming-guides/style/[Protobuf Style G A property is a name-value pair of information that is declared using Protobuf Options. There are two types of properties: -1. *uProtocol Properties:* Required properties that all services must set, these are defined https://github.com/eclipse-uprotocol/up-core-api/blob/main/uprotocol/uprotocol_options.proto[uprotocol-options.proto] +1. *uProtocol Properties:* Required properties that all services must set, these are defined in link:../up-core-api/uprotocol/v1/uoptions.proto[uoptions.proto] 2. *uService Specific Properties:* Properties that are declared in their respective service proto. Services can declare any non-reserved identifier in their own proto files.