Skip to content

IntrospectionException: type mismatch between indexed and non-indexed methods [SPR-9943] #14576

Closed

Description

@spring-projects-issues

Mattias Severson opened SPR-9943 and commented

The application fails to create beans of type com.amazonaws.ClientConfiguration due to

[...]
Caused by: org.springframework.beans.FatalBeanException: Failed to obtain BeanInfo for class [com.amazonaws.ClientConfiguration]; nested exception is java.beans.IntrospectionException: type mismatch between indexed and non-indexed methods: socketBufferSizeHints
	at org.springframework.beans.CachedIntrospectionResults.<init>(CachedIntrospectionResults.java:262)
	at org.springframework.beans.CachedIntrospectionResults.forClass(CachedIntrospectionResults.java:149)
	at org.springframework.beans.BeanWrapperImpl.getCachedIntrospectionResults(BeanWrapperImpl.java:324)
	at org.springframework.beans.BeanWrapperImpl.getPropertyDescriptors(BeanWrapperImpl.java:331)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.filterPropertyDescriptorsForDependencyCheck(AbstractAutowireCapableBeanFactory.java:1242)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1101)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:517)
	... 43 more
Caused by: java.beans.IntrospectionException: type mismatch between indexed and non-indexed methods: socketBufferSizeHints
	at java.beans.IndexedPropertyDescriptor.findIndexedPropertyType(IndexedPropertyDescriptor.java:395)
	at java.beans.IndexedPropertyDescriptor.setIndexedWriteMethod(IndexedPropertyDescriptor.java:292)
	at org.springframework.beans.ExtendedBeanInfo.addOrUpdatePropertyDescriptor(ExtendedBeanInfo.java:314)
	at org.springframework.beans.ExtendedBeanInfo.<init>(ExtendedBeanInfo.java:170)
	at org.springframework.beans.CachedIntrospectionResults.<init>(CachedIntrospectionResults.java:224)

The error does not occur in release 3.1.2 or earlier versions.


Affects: 3.1.3

Attachments:

Issue Links:

Referenced from: commits spring-attic/spring-framework-issues@8c7a4ad, spring-attic/spring-framework-issues@792ed0e

Activity

  1. spring-projects-issues commented on Nov 2, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Chris Beams commented

    Matthias, this issue is already resolved in 3.2.0.BUILD-SNAPSHOT, i.e. in the upcoming 3.2 RC1. Is it an option for you to upgrade to that? That particular fix cannot be backported to 3.1.x in a straightforward fashion; this bug can be fixed in any case, but thought I'd mention that 3.2 will "just work" already.

  2. spring-projects-issues commented on Nov 2, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Mattias Severson commented

    The problem is that we are not allowed to go to production without a final release. However, looking at the road map, the 3.2 GA is not far away so we may just as well use the RC builds in our dev environment for now.

    You mention that the bug can be fixed, is that something that you will do, or is it a workaround to our code? If it is fix on our side, can you point us in the right direction?

  3. spring-projects-issues commented on Nov 2, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Chris Beams commented

    It's something on our side; there have been a number of similar bugs with an internal component called ExtendedBeanInfo. This class has been removed from the code path for the vast majority of use cases in 3.2, but the change is too significant to backport to 3.1.x for various reasons.

    This just needs to be tracked down in ExtendedBeanInfo and fixed. Phil Webb, perhaps you'd like to take a look as you're now familiar with this code. In any case, we'll fix it up for 3.1.4, but it's likely that we'll ship 3.2 GA even before 3.1.4 at this point, so to your comment above, if you're good with using 3.1 RC1 in your dev builds, you're probably even better off (plus you'll have access to everything in 3.2 going forward!)

  4. spring-projects-issues commented on Nov 25, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Chris Beams commented

    Matthias, this issue is resolved based on the changes in #14663. These changes have been backported to 3.1.4 as well. Please give 3.1.4.BUILD-SNAPSHOT a try and let us know how it goes. Thanks!

  5. spring-projects-issues commented on Nov 25, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Mattias Severson commented

    My test passes after I updated the dependency in my sample project as suggested. Well done!

  6. spring-projects-issues commented on Nov 25, 2012

    @spring-projects-issues
    CollaboratorAuthor

    Chris Beams commented

    Great, Mattias—thanks for the quick feedback!

  7. added
    type: bug
    in: core
    on Jan 11, 2019
  8. added this to the 3.1.4 milestone on Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: coretype: bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions