Skip to content

Commit 4dc5b59

Browse files
authored
[GenAI] Add support for io.sundr:sundr-adapter-reflect:0.230.1 using gpt-5.6-terra (#9020)
* Scaffold io.sundr:sundr-adapter-reflect:0.230.1 * Partial dynamic-access coverage for io.sundr.adapter.reflect.ClassToTypeDef (5/6) * Dynamic-access coverage for io.sundr.adapter.reflect.ClassToTypeDef (6/12) * Dynamic-access coverage for io.sundr.reflect.ClassTo (11/12) * Dynamic-access coverage for io.sundr.adapter.reflect.ClassLookup (12/12) * Native metadata for io.sundr.adapter.reflect.ClassLookup__native_batch_4 * Update generated library support for io.sundr:sundr-adapter-reflect:0.230.1 * Add support for io.sundr:sundr-adapter-reflect:0.230.1
1 parent a11b5b9 commit 4dc5b59

13 files changed

Lines changed: 550 additions & 0 deletions

File tree

Lines changed: 136 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,136 @@
1+
{
2+
"reflection" : [
3+
{
4+
"condition" : {
5+
"typeReached" : "io.sundr.adapter.reflect.ClassToTypeDef"
6+
},
7+
"type" : "io.sundr.model.ClassRefBuilder",
8+
"methods" : [
9+
{
10+
"name" : "<init>",
11+
"parameterTypes" : [
12+
"io.sundr.model.ClassRef"
13+
]
14+
}
15+
]
16+
},
17+
{
18+
"condition" : {
19+
"typeReached" : "io.sundr.reflect.ClassTo"
20+
},
21+
"type" : "io.sundr.model.ClassRefBuilder",
22+
"methods" : [
23+
{
24+
"name" : "<init>",
25+
"parameterTypes" : [
26+
"io.sundr.model.ClassRef"
27+
]
28+
}
29+
]
30+
},
31+
{
32+
"condition" : {
33+
"typeReached" : "io.sundr.reflect.ClassTo$3"
34+
},
35+
"type" : "io.sundr.model.ClassRefBuilder",
36+
"methods" : [
37+
{
38+
"name" : "<init>",
39+
"parameterTypes" : [
40+
"io.sundr.model.ClassRef"
41+
]
42+
}
43+
]
44+
},
45+
{
46+
"condition" : {
47+
"typeReached" : "io.sundr.adapter.reflect.ClassToTypeDef"
48+
},
49+
"type" : "io.sundr.model.PrimitiveRefBuilder",
50+
"methods" : [
51+
{
52+
"name" : "<init>",
53+
"parameterTypes" : [
54+
"io.sundr.model.PrimitiveRef"
55+
]
56+
}
57+
]
58+
},
59+
{
60+
"condition" : {
61+
"typeReached" : "io.sundr.reflect.ClassTo"
62+
},
63+
"type" : "io.sundr.model.PrimitiveRefBuilder",
64+
"methods" : [
65+
{
66+
"name" : "<init>",
67+
"parameterTypes" : [
68+
"io.sundr.model.PrimitiveRef"
69+
]
70+
}
71+
]
72+
},
73+
{
74+
"condition" : {
75+
"typeReached" : "io.sundr.reflect.ClassTo$3"
76+
},
77+
"type" : "io.sundr.model.PrimitiveRefBuilder",
78+
"methods" : [
79+
{
80+
"name" : "<init>",
81+
"parameterTypes" : [
82+
"io.sundr.model.PrimitiveRef"
83+
]
84+
}
85+
]
86+
},
87+
{
88+
"condition" : {
89+
"typeReached" : "io.sundr.adapter.reflect.ClassToTypeDef"
90+
},
91+
"type" : "io.sundr.model.TypeParamRefBuilder",
92+
"methods" : [
93+
{
94+
"name" : "<init>",
95+
"parameterTypes" : [
96+
"io.sundr.model.TypeParamRef"
97+
]
98+
}
99+
]
100+
},
101+
{
102+
"condition" : {
103+
"typeReached" : "io.sundr.reflect.ClassTo"
104+
},
105+
"type" : "io.sundr.model.TypeParamRefBuilder",
106+
"methods" : [
107+
{
108+
"name" : "<init>",
109+
"parameterTypes" : [
110+
"io.sundr.model.TypeParamRef"
111+
]
112+
}
113+
]
114+
},
115+
{
116+
"condition" : {
117+
"typeReached" : "io.sundr.reflect.ClassTo$3"
118+
},
119+
"type" : "io.sundr.model.TypeParamRefBuilder",
120+
"methods" : [
121+
{
122+
"name" : "<init>",
123+
"parameterTypes" : [
124+
"io.sundr.model.TypeParamRef"
125+
]
126+
}
127+
]
128+
},
129+
{
130+
"condition" : {
131+
"typeReached" : "io.sundr.adapter.reflect.ClassLookup"
132+
},
133+
"type" : "java.lang.String"
134+
}
135+
]
136+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
[
2+
{
3+
"latest" : true,
4+
"metadata-version" : "0.230.1",
5+
"source-code-url" : "https://repo.maven.apache.org/maven2/io/sundr/sundr-adapter-reflect/$version$/sundr-adapter-reflect-$version$-sources.jar",
6+
"repository-url" : "https://github.com/sundrio/sundrio",
7+
"test-code-url" : "https://github.com/sundrio/sundrio/tree/$version$/adapters/reflect/src/test",
8+
"documentation-url" : "https://repo.maven.apache.org/maven2/io/sundr/sundr-adapter-reflect/$version$/sundr-adapter-reflect-$version$-javadoc.jar",
9+
"description" : "Sundr Adapter Reflect converts Java reflection Class instances into Sundr TypeDef models. It provides reflection-based adapters and type lookups for code-generation tools that consume the Sundr model.",
10+
"tested-versions" : [
11+
"0.230.1"
12+
],
13+
"allowed-packages" : [
14+
"io.sundr.adapter.reflect",
15+
"io.sundr.reflect"
16+
]
17+
}
18+
]
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
{
2+
"add_new_library_support:2026-07-09": {
3+
"timestamp": "2026-07-09T02:43:57.871981Z",
4+
"library": "io.sundr:sundr-adapter-reflect:0.230.1",
5+
"starting_commit": "67c8e3c25c8cf170bf393e04d077cf0c7b44a24e",
6+
"ending_commit": "31922153e3a305e2a13e9f438446990745d3557e",
7+
"strategy_name": "dynamic_access_main_sources_pi_gpt-5.6-terra",
8+
"agent": "pi",
9+
"model": "gpt-5.6-terra",
10+
"status": "success",
11+
"stats": {
12+
"version": "0.230.1",
13+
"dynamicAccess": {
14+
"breakdown": {
15+
"reflection": {
16+
"coverageRatio": 1.0,
17+
"coveredCalls": 12,
18+
"totalCalls": 12
19+
}
20+
},
21+
"coverageRatio": 1.0,
22+
"coveredCalls": 12,
23+
"totalCalls": 12
24+
},
25+
"libraryCoverage": {
26+
"instruction": {
27+
"covered": 1788,
28+
"missed": 759,
29+
"ratio": 0.702002,
30+
"total": 2547
31+
},
32+
"line": {
33+
"covered": 366,
34+
"missed": 135,
35+
"ratio": 0.730539,
36+
"total": 501
37+
},
38+
"method": {
39+
"covered": 44,
40+
"missed": 20,
41+
"ratio": 0.6875,
42+
"total": 64
43+
}
44+
}
45+
},
46+
"library_preparation_preflight": {
47+
"status": "completed",
48+
"action": "no_action",
49+
"issue_number": 7796,
50+
"issue_label": "library-new-request",
51+
"library": "io.sundr:sundr-adapter-reflect:0.230.1",
52+
"summary": "The reflection adapter is self-contained: its runtime dependencies (`sundr-model` and `sundr-adapter-api`) are transitive, and it adapts ordinary Java `Class` objects via reflection.",
53+
"deterministic_setup": [],
54+
"agent_guidance": "",
55+
"risks": [],
56+
"applied_setup": [],
57+
"input_evidence": [
58+
{
59+
"name": "issue",
60+
"summary": "#7796 Support for io.sundr:sundr-adapter-reflect:0.230.1; label=library-new-request; body_chars=39"
61+
},
62+
{
63+
"name": "existing_tests",
64+
"summary": "0 existing test file path(s) included"
65+
}
66+
],
67+
"model": "gpt-5.6-terra",
68+
"input_tokens_used": 42483,
69+
"output_tokens_used": 2453,
70+
"prompt_path": "library-preflight-prompt.txt",
71+
"raw_response_path": "library-preflight-response.txt",
72+
"session_log_path": "/home/mihailo/git/graalvm-reachability-metadata-copy/forge/logs/io.sundr:sundr-adapter-reflect:0.230.1/library-preparation-preflight/pi-generation-2026-07-09T02-02-34-416901Z.log"
73+
},
74+
"metrics": {
75+
"input_tokens_used": 82450,
76+
"cached_input_tokens_used": 879616,
77+
"output_tokens_used": 12498,
78+
"iterations": 5,
79+
"cost_usd": 0.6135,
80+
"generated_loc": 125,
81+
"tested_library_loc": 366,
82+
"metadata_entries": 19,
83+
"test_only_metadata_entries": 7,
84+
"code_coverage_percent": 73.05
85+
},
86+
"artifacts": {
87+
"metadata_file": "metadata/io.sundr/sundr-adapter-reflect/0.230.1/reachability-metadata.json"
88+
}
89+
}
90+
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"versions" : [ {
3+
"version" : "0.230.1",
4+
"dynamicAccess" : {
5+
"breakdown" : {
6+
"reflection" : {
7+
"coverageRatio" : 1.0,
8+
"coveredCalls" : 12,
9+
"totalCalls" : 12
10+
}
11+
},
12+
"coverageRatio" : 1.0,
13+
"coveredCalls" : 12,
14+
"totalCalls" : 12
15+
},
16+
"libraryCoverage" : {
17+
"instruction" : {
18+
"covered" : 1788,
19+
"missed" : 759,
20+
"ratio" : 0.702002,
21+
"total" : 2547
22+
},
23+
"line" : {
24+
"covered" : 366,
25+
"missed" : 135,
26+
"ratio" : 0.730539,
27+
"total" : 501
28+
},
29+
"method" : {
30+
"covered" : 44,
31+
"missed" : 20,
32+
"ratio" : 0.6875,
33+
"total" : 64
34+
}
35+
}
36+
} ]
37+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
gradlew.bat
2+
gradlew
3+
gradle/
4+
build/
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/*
2+
* Copyright and related rights waived via CC0
3+
*
4+
* You should have received a copy of the CC0 legalcode along with this
5+
* work. If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
6+
*/
7+
plugins {
8+
id "org.graalvm.internal.tck"
9+
}
10+
11+
String libraryVersion = tck.testedLibraryVersion.get()
12+
13+
dependencies {
14+
testImplementation "io.sundr:sundr-adapter-reflect:$libraryVersion"
15+
testImplementation 'org.assertj:assertj-core:3.22.0'
16+
}
17+
18+
graalvmNative {
19+
agent {
20+
defaultMode = "conditional"
21+
modes {
22+
conditional {
23+
userCodeFilterPath = "user-code-filter.json"
24+
}
25+
}
26+
}
27+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Optional explicit tested library coordinates (format: group:artifact:version).
2+
# If omitted, fallback resolution in org.graalvm.internal.tck.gradle still uses
3+
# environment variable GVM_TCK_LC and then this property.
4+
library.coordinates = io.sundr:sundr-adapter-reflect:0.230.1
5+
library.version = 0.230.1
6+
metadata.dir = io.sundr/sundr-adapter-reflect/0.230.1/
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* Copyright and related rights waived via CC0
3+
*
4+
* You should have received a copy of the CC0 legalcode along with this
5+
* work. If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
6+
*/
7+
pluginManagement {
8+
def tckPath = Objects.requireNonNullElse(
9+
System.getenv("GVM_TCK_TCKDIR"),
10+
"../../../../tck-build-logic"
11+
)
12+
includeBuild(tckPath)
13+
repositories { mavenLocal(); gradlePluginPortal() }
14+
}
15+
16+
plugins {
17+
id "org.graalvm.internal.tck-settings" version "1.0.0-SNAPSHOT"
18+
}
19+
20+
rootProject.name = 'io.sundr.sundr-adapter-reflect_tests'
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/*
2+
* Copyright and related rights waived via CC0
3+
*
4+
* You should have received a copy of the CC0 legalcode along with this
5+
* work. If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
6+
*/
7+
package io_sundr.sundr_adapter_reflect;
8+
9+
import static org.assertj.core.api.Assertions.assertThat;
10+
11+
import io.sundr.adapter.reflect.ClassLookup;
12+
import org.junit.jupiter.api.Test;
13+
14+
public class ClassLookupTest {
15+
16+
@Test
17+
void resolvesAnAvailableClassByFullyQualifiedName() {
18+
ClassLookup lookup = new ClassLookup();
19+
20+
assertThat(lookup.forName(String.class.getName())).containsSame(String.class);
21+
}
22+
}

0 commit comments

Comments
 (0)