From 02f3b7bfc1a49edd980a27f17b1fb836aa4788a6 Mon Sep 17 00:00:00 2001 From: HzjNeverStop <441627022@qq.com> Date: Tue, 30 Aug 2022 17:51:53 +0800 Subject: [PATCH] update_3.14.1 and fix refrencefactory getObjectType (#1011) --- pom.xml | 2 +- .../sofa/runtime/spring/factory/ReferenceFactoryBean.java | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index a906d3e2e..72024a64d 100644 --- a/pom.xml +++ b/pom.xml @@ -37,7 +37,7 @@ SOFABoot Build - 3.14.0 + 3.14.1-SNAPSHOT ${revision} 1.6.7 diff --git a/sofa-boot-project/sofa-boot-core/runtime-sofa-boot/src/main/java/com/alipay/sofa/runtime/spring/factory/ReferenceFactoryBean.java b/sofa-boot-project/sofa-boot-core/runtime-sofa-boot/src/main/java/com/alipay/sofa/runtime/spring/factory/ReferenceFactoryBean.java index f361eaf48..20150117a 100644 --- a/sofa-boot-project/sofa-boot-core/runtime-sofa-boot/src/main/java/com/alipay/sofa/runtime/spring/factory/ReferenceFactoryBean.java +++ b/sofa-boot-project/sofa-boot-core/runtime-sofa-boot/src/main/java/com/alipay/sofa/runtime/spring/factory/ReferenceFactoryBean.java @@ -79,7 +79,13 @@ public Object getObject() throws Exception { @Override public Class getObjectType() { - return getInterfaceClass(); + try { + Class type = getInterfaceClass(); + return type != null ? type : ReferenceFactoryBean.class; + } catch (Throwable t) { + // Class not found + return ReferenceFactoryBean.class; + } } @Override