Skip to content

Commit 951511b

Browse files
authored
Update to weaver 0.13.2 and enable javadoc validation(!) (#174)
* Update weaver to 0.13.2 * Validate javadoc
1 parent 5890c81 commit 951511b

34 files changed

+5
-309
lines changed

build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ fun generateTask(taskName: String, incubating: Boolean) {
108108
"--mount", "type=bind,source=${modelPath},target=/home/weaver/source,readonly",
109109
"--mount", "type=bind,source=$projectDir/buildscripts/templates,target=/home/weaver/templates,readonly",
110110
"--mount", "type=bind,source=$projectDir/$outputDir,target=/home/weaver/target",
111-
"otel/weaver:v0.12.0",
111+
"otel/weaver:v0.13.2",
112112
"registry", "generate",
113113
"--registry=/home/weaver/source",
114114
"--templates=/home/weaver/templates",

buildSrc/src/main/kotlin/otel.java-conventions.gradle.kts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,7 @@ tasks {
7676
breakIterator(true)
7777

7878
addBooleanOption("html5", true)
79-
// TODO (trask) need to disable html validation until next semconv release
80-
// see https://github.com/open-telemetry/semantic-conventions/pull/1664
81-
addBooleanOption("Xdoclint:all,-missing,-html", true)
79+
addBooleanOption("Xdoclint:all,-missing", true)
8280
// non-standard option to fail on warnings, see https://bugs.openjdk.java.net/browse/JDK-8200363
8381
addStringOption("Xwerror", "-quiet")
8482
}

buildscripts/templates/registry/incubating_java/IncubatingSemanticAttributes.java.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ import java.util.List;
3737
@SuppressWarnings("unused")
3838
public final class {{ my_class_name }} {
3939
{% for attribute in ctx.attributes | rejectattr("name", "in", ctx.excluded_attributes) %}{% if attribute is experimental %}
40-
{%- if attribute is deprecated %}{%- set deprecated_javadoc = "@deprecated " ~ attribute.deprecated -%}
40+
{%- if attribute is deprecated %}{%- set deprecated_javadoc = "@deprecated " ~ attribute.deprecated.note -%}
4141
{%- else -%}{%- set deprecated_javadoc = "" -%}
4242
{%- endif -%}
4343
{{ [attribute.brief, concat_if("\n\nNotes:\n\n", attribute.note), deprecated_javadoc] | comment(indent=4) }}
@@ -58,7 +58,7 @@ public final class {{ my_class_name }} {
5858
* @deprecated deprecated in favor of stable {@link {{stable_class_link}}}.
5959
*/
6060
{%- elif attribute is deprecated -%}
61-
{{ ["Values for {@link #" ~ attribute.name | screaming_snake_case ~ "}", "@deprecated " ~ attribute.deprecated ] | comment }}
61+
{{ ["Values for {@link #" ~ attribute.name | screaming_snake_case ~ "}", "@deprecated " ~ attribute.deprecated.note ] | comment }}
6262
{%- else -%}
6363
/** Values for {@link #{{ attribute.name | screaming_snake_case }}}. */
6464
{%- endif -%}

buildscripts/templates/registry/java/SemanticAttributes.java.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ import java.util.List;
3838
public final class {{ my_class_name }} {
3939
{% for attribute in ctx.attributes | rejectattr("name", "in", ctx.excluded_attributes) %}{% if attribute is stable %}
4040
{%- if attribute is deprecated %}
41-
{%- set deprecated_javadoc = "@deprecated " ~ attribute.deprecated -%}
41+
{%- set deprecated_javadoc = "@deprecated " ~ attribute.deprecated.note -%}
4242
{%- endif -%}
4343
{{ [attribute.brief, concat_if("\n\nNotes:\n\n", attribute.note), deprecated_javadoc] | comment(indent=4) }}
4444
{% if attribute is deprecated %}@Deprecated{% endif %} public static final {{ to_java_key_type(attribute) | trim }} {{ attribute.name | screaming_snake_case }} = {{ to_java_key_factory(attribute) | trim }}("{{ attribute.name }}");

semconv-incubating/src/main/java/io/opentelemetry/semconv/incubating/AndroidIncubatingAttributes.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ public final class AndroidIncubatingAttributes {
3030
* href="https://developer.android.com/guide/components/activities/activity-lifecycle#lc">Activity
3131
* lifecycle callbacks</a>, and from which the {@code OS identifiers} are derived.
3232
*
33-
* <p>
34-
*
3533
* @deprecated Replaced by {@code device.app.lifecycle}.
3634
*/
3735
@Deprecated public static final AttributeKey<String> ANDROID_STATE = stringKey("android.state");

semconv-incubating/src/main/java/io/opentelemetry/semconv/incubating/ClientIncubatingAttributes.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ public final class ClientIncubatingAttributes {
2424
* client.address} SHOULD represent the client address behind any intermediaries, for example
2525
* proxies, if it's available.
2626
*
27-
* <p>
28-
*
2927
* @deprecated deprecated in favor of stable {@link
3028
* io.opentelemetry.semconv.ClientAttributes#CLIENT_ADDRESS} attribute.
3129
*/
@@ -40,8 +38,6 @@ public final class ClientIncubatingAttributes {
4038
* client.port} SHOULD represent the client port behind any intermediaries, for example proxies,
4139
* if it's available.
4240
*
43-
* <p>
44-
*
4541
* @deprecated deprecated in favor of stable {@link
4642
* io.opentelemetry.semconv.ClientAttributes#CLIENT_PORT} attribute.
4743
*/

semconv-incubating/src/main/java/io/opentelemetry/semconv/incubating/CodeIncubatingAttributes.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ public final class CodeIncubatingAttributes {
1717
/**
1818
* Deprecated, use {@code code.column.number}
1919
*
20-
* <p>
21-
*
2220
* @deprecated Replaced by {@code code.column.number}
2321
*/
2422
@Deprecated public static final AttributeKey<Long> CODE_COLUMN = longKey("code.column");
@@ -41,8 +39,6 @@ public final class CodeIncubatingAttributes {
4139
/**
4240
* Deprecated, use {@code code.function.name} instead
4341
*
44-
* <p>
45-
*
4642
* @deprecated Replaced by {@code code.function.name}
4743
*/
4844
@Deprecated public static final AttributeKey<String> CODE_FUNCTION = stringKey("code.function");
@@ -61,8 +57,6 @@ public final class CodeIncubatingAttributes {
6157
/**
6258
* Deprecated, use {@code code.line.number} instead
6359
*
64-
* <p>
65-
*
6660
* @deprecated Replaced by {@code code.line.number}
6761
*/
6862
@Deprecated public static final AttributeKey<Long> CODE_LINENO = longKey("code.lineno");

semconv-incubating/src/main/java/io/opentelemetry/semconv/incubating/ContainerIncubatingAttributes.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,6 @@ public final class ContainerIncubatingAttributes {
3838
/**
3939
* Deprecated, use {@code cpu.mode} instead.
4040
*
41-
* <p>
42-
*
4341
* @deprecated Replaced by {@code cpu.mode}
4442
*/
4543
@Deprecated
@@ -127,8 +125,6 @@ public final class ContainerIncubatingAttributes {
127125
/**
128126
* Deprecated, use {@code container.label} instead.
129127
*
130-
* <p>
131-
*
132128
* @deprecated Replaced by {@code container.label}.
133129
*/
134130
@Deprecated

0 commit comments

Comments
 (0)