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
{{ message }}
Repository navigation
[validation] @Value annotations with classpath should be of type Resource or similar #1581
a validation could run to make sure that - if the @Value annotation points to a resource (e.g. classpath: in this case), that the type if the annotated element (field, parameter) is of type Resource. Otherwise, this might lead to unwanted behavior. E.g. if the type if the field is String, the name of the resource is being injected instead of the content of the file.
Activity
martinlippert commentedon Jun 16, 2025
The corresponding quick fix to change the type of the annotated element could also be offered here.
martinlippert commentedon Jun 24, 2025
Actually, the field should be of type.
ResourceorFile, both works just fine.GH-1581: added new validation for types of classpath resource injections