Skip to content

Regression - Introspection with BeanUtils started failing for java.awt.Component derived classes [SPR-8491] #13137

Closed
@spring-projects-issues

Description

@spring-projects-issues

Tuomas Kiviaho opened SPR-8491 and commented

java.awt.Component has both

public void setSize(int width, int height)
and
public void setSize(Dimension d)

introspection of classes derived from this base class (using BeanUtils.getPropertyDescriptor) now crashes with following exception

...
Caused by: java.beans.IntrospectionException: type mismatch between indexed and non-indexed methods: size
at java.beans.IndexedPropertyDescriptor.findIndexedPropertyType(IndexedPropertyDescriptor.java:341)
at java.beans.IndexedPropertyDescriptor.setIndexedWriteMethod(IndexedPropertyDescriptor.java:248)
at org.springframework.beans.ExtendedBeanInfo.addOrUpdatePropertyDescriptor(ExtendedBeanInfo.java:233)
at org.springframework.beans.ExtendedBeanInfo.addOrUpdatePropertyDescriptor(ExtendedBeanInfo.java:178)
at org.springframework.beans.ExtendedBeanInfo.<init>(ExtendedBeanInfo.java:108)
at org.springframework.beans.CachedIntrospectionResults.<init>(CachedIntrospectionResults.java:224)
... 92 more

I guess that this can be omitted by first checking whether or not index method really has to be updated or not (it seems to be already null)


Affects: 3.1 M2

Attachments:

Issue Links:

3 votes, 5 watchers

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: coreIssues in core modules (aop, beans, core, context, expression)status: duplicateA duplicate of another issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions