GoogleCloudPlatform / GoogleCloudPlatform/cloud-opensource-java

Check validity of the errors from latest zipkin

未關閉
#849 0 則留言 0 個 reaction 已指派 1 人 已被 @suztomo 認領 在 GitHub 檢視
Dependency Fix p3
主要語言
Java
星號
163
分支
80
PR 合併指標
30 天內沒有已合併 PR

描述

Check the validity of the enforcer rule when it's applied to [zipkin](https://github.com/openzipkin/zipkin).

The maven-shade-plugin may be missing JsonTreeReader.

# zipkin

```
[ERROR] Linkage Checker rule found 1 error. Linkage error report:
Class zipkin2.internal.gson.internal.bind.JsonTreeReader is not found;
referenced by 1 class file
zipkin2.internal.gson.stream.JsonReader (zipkin-2.16.2-SNAPSHOT.jar)
```

Does this produce a new linkage error? (But the package name indicate `zipkin2.internal.gson.stream.JsonReader` is only for internal use. Identify which public class touches the class.

```
static {
JsonReaderInternalAccess.INSTANCE = new JsonReaderInternalAccess() {
@Override public void promoteNameToValue(JsonReader reader) throws IOException {
if (reader instanceof JsonTreeReader) {
((JsonTreeReader)reader).promoteNameToValue();
return;
}
int p = reader.peeked;
if (p == PEEKED_NONE) {
p = reader.doPeek();
}
if (p == PEEKED_DOUBLE_QUOTED_NAME) {
reader.peeked = PEEKED_DOUBLE_QUOTED;
} else if (p == PEEKED_SINGLE_QUOTED_NAME) {
reader.peeked = PEEKED_SINGLE_QUOTED;
} else if (p == PEEKED_UNQUOTED_NAME) {
reader.peeked = PEEKED_UNQUOTED;
} else {
throw new IllegalStateException(
"Expected a name but was " + reader.peek() + reader.locationString());
}
}
};
}
```

# zipkin-tests

```
[INFO] --- maven-enforcer-plugin:3.0.0-M2:enforce (enforce) @ zipkin-tests ---
[WARNING] Linkage Checker rule found 6 errors. Linkage error report:
Class zipkin2.internal.gson.internal.bind.JsonTreeReader is not found;
referenced by 1 class file
zipkin2.internal.gson.stream.JsonReader (zipkin-2.16.2-SNAPSHOT.jar)
Class kotlin.jvm.functions.Function0 is not found;
referenced by 1 class file
org.junit.jupiter.api.AssertionsKt (junit-jupiter-api-5.5.1.jar)
Class kotlin.jvm.internal.Intrinsics is not found;
referenced by 2 class files
org.junit.jupiter.api.AssertionsKt (junit-jupiter-api-5.5.1.jar)
org.junit.jupiter.params.aggregator.ArgumentsAccessorKt (junit-jupiter-params-5.5.1.jar)
Class kotlin.jvm.internal.Lambda is not found;
referenced by 1 class file
org.junit.jupiter.api.AssertionsKt (junit-jupiter-api-5.5.1.jar)
Class kotlin.collections.CollectionsKt is not found;
referenced by 1 class file
org.junit.jupiter.api.AssertionsKt (junit-jupiter-api-5.5.1.jar)
Class kotlin.collections.ArraysKt is not found;
referenced by 1 class file
org.junit.jupiter.api.AssertionsKt (junit-jupiter-api-5.5.1.jar)
```

They are Kotlin-related classes. JUnit Jupiter is the combination of the new programming model and extension model for writing tests and extensions in JUnit 5.

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。