Consider ClassFile API for reading class metadata from bytecode #33616
Labels
in: core
Issues in core modules (aop, beans, core, context, expression)
type: enhancement
A general enhancement
Milestone
Spring Framework currently shades ASM for several features:
Our usage of ASM is not a problem these days and we tend to allow use of up-to-date JDK versions in Spring apps thanks to swift upgrades of our shaded version. Still, we should consider our options with the new ClassFile API.
Spring Framework maintains two implementations of metadata reading: one based on
Class
reflection (org.springframework.core.type.StandardClassMetadata
) and another one based on bytecode reading with ASM (org.springframework.core.type.classreading.SimpleMetadataReaderFactory
). This API does not expose any ASM type and is a good use case for the ClassFile API.The ClassFile API JEP 457 is currently in preview mode but should be out of preview for JDK 24.
With this issue, we should:
SimpleMetadataReaderFactory
based on ClassFileThe text was updated successfully, but these errors were encountered: