Issue 1:
Steven Warren opened SPR-688 and commented

Proxy receives a Class[] that contains the interfaces to be supported by the proxy. The order of classes in the array are significant to Proxy as it uses that ordering to resolve method signature conflicts.

AdvisedSupport returns an Array of interfaces supported, but the ordering is undefined. This can lead to unpredictable behaviour of the proxy class.

Affects: 1.1.4

Issue 2:
G opened SPR-4367 and commented

Autowiring failed when one of the bean contains factory-method (Static setter). Even we don't apply autowire in that bean, it will also crash the whole framework.

Reference: http://forum.springframework.org/showthread.php?t=48399

Partial XML:

<?xml version="1.0" encoding="UTF-8"?>

<beans xmlns="http://www.springframework.org/schema/beans"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

xmlns:context="http://www.springframework.org/schema/context"

xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd

http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">

<context:annotation-config />

<bean id="hibernateUtil" class="com.foo.hibernate.HibernateUtil"

factory-method="setSessionFactory">

<constructor-arg ref="sessionFactory" />

</bean>

</beans>

Java:

package com.foo.hibernate;

import org.hibernate.SessionFactory;

public class HibernateUtil {

private static SessionFactory sessionFactory_;

public static SessionFactory getSessionFactory() { return sessionFactory_; }
public static void setSessionFactory(SessionFactory sessionFactory) { sessionFactory_ = sessionFactory; }

}

Error:

ERROR|14:45:57,234| ContextLoader:215 - Context initialization failed

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateUtil' defined in ServletContext resource [/WEB-INF/conf/applicationContext-hibernate.xml]: Initialization of bean failed; nested exception is java.lang.NullPointerException

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:445)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:383)

at java.security.AccessController.doPrivileged(Native Method)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:353)

at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)

at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:169)

at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)

at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)

at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:400)

at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:736)

at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:369)

at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:261)

at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)

at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)

at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3830)

at org.apache.catalina.core.StandardContext.start(StandardContext.java:4337)

at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)

at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)

at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)

at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)

at org.apache.catalina.core.StandardService.start(StandardService.java:516)

at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)

at org.apache.catalina.startup.Catalina.start(Catalina.java:566)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.lang.reflect.Method.invoke(Unknown Source)

at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)

at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)

Caused by: java.lang.NullPointerException

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:876)

at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:437)

... 28 more

Affects: 2.5.1

Issue Links:

#9024 NPE in AbstractAutowireCapableBeanFactory#populateBean() if bean wrapper is null and InstantiationAwareBeanPostProcessor are registered ("duplicates")

#9075 CLONE -Autowiring failed when one of the bean contains factory-method ("is duplicated by")