默认禁用报表模块,
parent
e46286d18a
commit
39ac59efee
|
@ -4,6 +4,7 @@ import cn.hutool.core.thread.ThreadUtil;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.boot.ApplicationArguments;
|
import org.springframework.boot.ApplicationArguments;
|
||||||
import org.springframework.boot.ApplicationRunner;
|
import org.springframework.boot.ApplicationRunner;
|
||||||
|
import org.springframework.util.ClassUtils;
|
||||||
|
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
|
@ -30,7 +31,17 @@ public class BannerApplicationRunner implements ApplicationRunner {
|
||||||
"https://doc.iocoder.cn",
|
"https://doc.iocoder.cn",
|
||||||
"https://t.zsxq.com/02Yf6M7Qn",
|
"https://t.zsxq.com/02Yf6M7Qn",
|
||||||
"https://t.zsxq.com/02B6ujIee");
|
"https://t.zsxq.com/02B6ujIee");
|
||||||
|
|
||||||
|
// 数据报表
|
||||||
|
if (isNotPresent("cn.iocoder.yudao.module.visualization.framework.security.config.SecurityConfiguration")) {
|
||||||
|
System.out.println("[报表模块 yudao-module-visualization-biz - 已禁用][参考 https://doc.iocoder.cn/report/ 开启]");
|
||||||
|
}
|
||||||
|
// 支付模块
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static boolean isNotPresent(String className) {
|
||||||
|
return !ClassUtils.isPresent(className, ClassUtils.getDefaultClassLoader());
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,10 +5,31 @@ import cn.iocoder.yudao.framework.flowable.core.web.FlowableWebFilter;
|
||||||
import org.springframework.boot.web.servlet.FilterRegistrationBean;
|
import org.springframework.boot.web.servlet.FilterRegistrationBean;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
import org.springframework.core.task.AsyncListenableTaskExecutor;
|
||||||
|
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
public class YudaoFlowableConfiguration {
|
public class YudaoFlowableConfiguration {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 参考 {@link org.flowable.spring.boot.FlowableJobConfiguration} 类,创建对应的 AsyncListenableTaskExecutor Bean
|
||||||
|
*
|
||||||
|
* 如果不创建,会导致项目启动时,Flowable 报错的问题
|
||||||
|
*/
|
||||||
|
@Bean
|
||||||
|
public AsyncListenableTaskExecutor taskExecutor() {
|
||||||
|
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
|
||||||
|
executor.setCorePoolSize(8);
|
||||||
|
executor.setMaxPoolSize(8);
|
||||||
|
executor.setQueueCapacity(100);
|
||||||
|
executor.setThreadNamePrefix("flowable-task-Executor-");
|
||||||
|
executor.setAwaitTerminationSeconds(30);
|
||||||
|
executor.setWaitForTasksToCompleteOnShutdown(true);
|
||||||
|
executor.setAllowCoreThreadTimeOut(true);
|
||||||
|
executor.initialize();
|
||||||
|
return executor;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 配置 flowable Web 过滤器
|
* 配置 flowable Web 过滤器
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -51,23 +51,18 @@
|
||||||
<artifactId>yudao-module-product-biz</artifactId>
|
<artifactId>yudao-module-product-biz</artifactId>
|
||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!--数据可视化报表-->
|
<!-- 数据报表 -->
|
||||||
|
<!-- <dependency>-->
|
||||||
|
<!-- <groupId>cn.iocoder.boot</groupId>-->
|
||||||
|
<!-- <artifactId>yudao-module-visualization-biz</artifactId>-->
|
||||||
|
<!-- <version>${revision}</version>-->
|
||||||
|
<!-- </dependency>-->
|
||||||
|
<!-- 工作流 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.iocoder.boot</groupId>
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
<artifactId>yudao-module-visualization-biz</artifactId>
|
<artifactId>yudao-module-bpm-biz</artifactId>
|
||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- 默认引入 yudao-module-bpm-biz-flowable 实现,可以替换为 yudao-module-bpm-biz-activiti 实现-->
|
|
||||||
<!-- <dependency>-->
|
|
||||||
<!-- <groupId>cn.iocoder.boot</groupId>-->
|
|
||||||
<!-- <artifactId>yudao-module-bpm-biz</artifactId>-->
|
|
||||||
<!-- <version>${revision}</version>-->
|
|
||||||
<!-- </dependency>-->
|
|
||||||
<!-- <dependency>-->
|
|
||||||
<!-- <groupId>cn.iocoder.boot</groupId>-->
|
|
||||||
<!-- <artifactId>yudao-module-bpm-biz-activiti</artifactId>-->
|
|
||||||
<!-- <version>${revision}</version>-->
|
|
||||||
<!-- </dependency>-->
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.iocoder.boot</groupId>
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
<artifactId>yudao-spring-boot-starter-biz-error-code</artifactId>
|
<artifactId>yudao-spring-boot-starter-biz-error-code</artifactId>
|
||||||
|
|
Loading…
Reference in New Issue