Skip to content

Commit

Permalink
修复静态合并部署时,springcloud依赖兼容性问题导致模块先于基座被加载的问题(#1032)
Browse files Browse the repository at this point in the history
  • Loading branch information
YanZhipeng-UESTC committed Nov 22, 2024
1 parent 7ab39b4 commit 0e4604e
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import com.alipay.sofa.ark.api.ArkConfigs;
import com.alipay.sofa.ark.support.startup.EmbedSofaArkBootstrap;
import org.springframework.boot.web.context.ConfigurableWebServerApplicationContext;
import org.springframework.context.ApplicationListener;
import org.springframework.context.event.ApplicationContextEvent;
import org.springframework.context.event.ContextRefreshedEvent;
Expand All @@ -33,7 +34,8 @@ public void onApplicationEvent(ApplicationContextEvent event) {
return;
}
if (ArkConfigs.isEmbedEnable() && ArkConfigs.isEmbedStaticBizEnable()) {
if (event instanceof ContextRefreshedEvent) {
if (event instanceof ContextRefreshedEvent
&& event.getApplicationContext() instanceof ConfigurableWebServerApplicationContext) {
// After the master biz is started, statically deploy the other biz from classpath
EmbedSofaArkBootstrap.deployStaticBizAfterEmbedMasterBizStarted();
}
Expand Down

0 comments on commit 0e4604e

Please sign in to comment.