You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The schema also includes further details and explanations how this configuration works. Here is the example of the proxy-config.json:
326
+
Dynamic proxy metadata should be specified as part of a _reflect-config.json_ file by adding `"proxy"`-type entries, conforming to the JSON schema defined in [config-type-schema-v1.1.0.json](https://github.com/oracle/graal/blob/master/docs/reference-manual/native-image/assets/config-type-schema-v1.0.0.json).
327
+
It enables you to register members of a proxy class for reflection the same way as it would be done for a named class.
328
+
The order in which interfaces are given matters and the interfaces will be passed in the same order to generate the proxy class.
329
+
The schema also includes further details and explanations how this configuration works.
330
+
Here is an example of dynamic proxy metadata in reflect-config.json:
329
331
```json
330
332
[
331
333
{
332
334
"condition": {
333
335
"typeReachable": "<condition-class>"
334
336
},
335
-
"interfaces": [
336
-
"IA",
337
-
"IB"
338
-
]
337
+
"type": { "proxy": [
338
+
"IA",
339
+
"IB"
340
+
]}
339
341
}
340
342
]
341
343
```
344
+
Contents of _proxy-config.json_ files will still be parsed and honored by Native Image, but this file is now deprecated
345
+
and the [Native Image agent](AutomaticMetadataCollection.md) outputs proxy metadata to reflect-config.json.
342
346
343
347
## Serialization
344
348
Java can serialize any class that implements the `Serializable` interface.
@@ -388,6 +392,14 @@ The schema also includes further details and explanations how this configuration
Copy file name to clipboardExpand all lines: substratevm/CHANGELOG.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,6 +22,7 @@ This changelog summarizes major changes to GraalVM Native Image.
22
22
* (GR-51172) Add support to catch OutOfMemoryError exceptions on native image if there is no memory left.
23
23
* (GR-43837) `--report-unsupported-elements-at-runtime` is now enabled by default and the option is deprecated.
24
24
* (GR-53359) Provide the `.debug_gdb_scripts` section that triggers auto-loading of `svmhelpers.py` in GDB. Remove single and double quotes from `ClassLoader.nameAndId` in the debuginfo.
25
+
* (GR-47365) Include dynamic proxy metadata in the reflection metadata with the syntax `"type": { "proxy": [<interface list>] }`. This allows members of proxy classes to be accessed reflectively. `proxy-config.json` is now deprecated but will still be honored.
25
26
26
27
## GraalVM for JDK 22 (Internal Version 24.0.0)
27
28
* (GR-48304) Red Hat added support for the JFR event ThreadAllocationStatistics.
Copy file name to clipboardExpand all lines: substratevm/src/com.oracle.svm.configure.test/src/com/oracle/svm/configure/test/config/OmitPreviousConfigTests.java
Copy file name to clipboardExpand all lines: substratevm/src/com.oracle.svm.configure/src/com/oracle/svm/configure/config/ParserConfigurationAdapter.java
0 commit comments