Skip to content

Commit b91d3bb

Browse files
committed
Move warning to where users will see it
1 parent 22e857d commit b91d3bb

2 files changed

Lines changed: 12 additions & 11 deletions

File tree

api/incubator/src/main/java/io/opentelemetry/api/incubator/common/ExtendedAttributeKey.java

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,18 @@ static ExtendedAttributeKey<ExtendedAttributes> extendedAttributesKey(String key
106106
return InternalExtendedAttributeKeyImpl.create(key, ExtendedAttributeType.EXTENDED_ATTRIBUTES);
107107
}
108108

109-
/** Returns a new ExtendedAttributeKey for {@link Value} valued attributes. */
109+
/**
110+
* Returns a new ExtendedAttributeKey for {@link Value} valued attributes.
111+
*
112+
* <p>Simple attributes ({@link ExtendedAttributeType#STRING}, {@link ExtendedAttributeType#LONG},
113+
* {@link ExtendedAttributeType#DOUBLE}, {@link ExtendedAttributeType#BOOLEAN}, {@link
114+
* ExtendedAttributeType#STRING_ARRAY}, {@link ExtendedAttributeType#LONG_ARRAY}, {@link
115+
* ExtendedAttributeType#DOUBLE_ARRAY}, {@link ExtendedAttributeType#BOOLEAN_ARRAY}) SHOULD be
116+
* used whenever possible. Instrumentations SHOULD assume that backends do not index individual
117+
* properties of complex attributes, that querying or aggregating on such properties is
118+
* inefficient and complicated, and that reporting complex attributes carries higher performance
119+
* overhead.
120+
*/
110121
static ExtendedAttributeKey<Value<?>> valueKey(String key) {
111122
return InternalExtendedAttributeKeyImpl.create(key, ExtendedAttributeType.VALUE);
112123
}

api/incubator/src/main/java/io/opentelemetry/api/incubator/common/ExtendedAttributeType.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,5 @@ public enum ExtendedAttributeType {
3030
*/
3131
@Deprecated
3232
EXTENDED_ATTRIBUTES,
33-
/**
34-
* Simple attributes ({@link ExtendedAttributeType#STRING}, {@link ExtendedAttributeType#LONG},
35-
* {@link ExtendedAttributeType#DOUBLE}, {@link ExtendedAttributeType#BOOLEAN}, {@link
36-
* ExtendedAttributeType#STRING_ARRAY}, {@link ExtendedAttributeType#LONG_ARRAY}, {@link
37-
* ExtendedAttributeType#DOUBLE_ARRAY}, {@link ExtendedAttributeType#BOOLEAN_ARRAY}) SHOULD be
38-
* used whenever possible. Instrumentations SHOULD assume that backends do not index individual
39-
* properties of complex attributes, that querying or aggregating on such properties is
40-
* inefficient and complicated, and that reporting complex attributes carries higher performance
41-
* overhead.
42-
*/
4333
VALUE;
4434
}

0 commit comments

Comments
 (0)