@@ -97,12 +97,29 @@ option go_package = "go.opentelemetry.io/proto/otlp/profiles/v1development";
9797//
9898
9999// ProfilesDictionary represents the profiles data shared across the
100- // entire message being sent.
100+ // entire message being sent. The following applies to all fields in this
101+ // message:
102+ //
103+ // - A dictionary is an array of dictionary items. Users of the dictionary
104+ // compactly reference the items using the index within the array.
105+ //
106+ // - A dictionary MUST have a zero value encoded as the first element. This
107+ // allows for _index fields pointing into the dictionary to use a 0 pointer
108+ // value to indicate 'null' / 'not set'. Unless otherwise defined, a 'zero
109+ // value' message value is one with all default field values, so as to
110+ // minimize wire encoded size.
111+ //
112+ // - There SHOULD NOT be dupes in a dictionary. The identity of dictionary
113+ // items is based on their value, recursively as needed. If a particular
114+ // implementation does emit duplicated items, it MUST NOT attempt to give them
115+ // meaning based on the index or order. A profile processor may remove
116+ // duplicate items and this MUST NOT have any observable effects for
117+ // consumers.
118+ //
119+ // - There SHOULD NOT be orphaned (unreferenced) items in a dictionary. A
120+ // profile processor may remove ("garbage-collect") orphaned items and this
121+ // MUST NOT have any observable effects for consumers.
101122//
102- // Note that all fields in this message MUST have a zero value encoded as the first element.
103- // This allows for _index fields pointing into the dictionary to use a 0 pointer value
104- // to indicate 'null' / 'not set'. Unless otherwise defined, a 'zero value' message value
105- // is one with all default field values, so as to minimize wire encoded size.
106123message ProfilesDictionary {
107124 // Mappings from address ranges to the image/binary/library mapped
108125 // into that address range referenced by locations via Location.mapping_index.
0 commit comments