创建RmiRegistryFactoryBean时,FactoryBean类型上的Bean创建异常检查

时间:2015-12-03 15:15:55

标签: rmi spring-remoting

我得到以下异常8次:

WARN  DefaultListableBeanFactor - Bean creation exception on FactoryBean type check: org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'rmiRegistryFactoryBean': Requested bean is currently in creation: Is there an unresolvable circular reference?

当我在上下文中创建以下bean时:

    @Bean
    public RmiRegistryFactoryBean rmiRegistryFactoryBean() {
        RmiRegistryFactoryBean rmiRegistryFactoryBean = new RmiRegistryFactoryBean();
        rmiRegistryFactoryBean.setPort(rmiConfig.getPort());
        rmiRegistryFactoryBean.setAlwaysCreate(true);

        return rmiRegistryFactoryBean;
    }

没有明确的循环引用。

0 个答案:

没有答案