mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2026-05-04 11:01:26 +08:00
add 新增 ruoyi-powerjob-server 整合 powerjob 框架
update 重构 ruoyi-job 适配 powerjob remove 移除 xxljob 建议使用 powerjob
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
package org.dromara.powerjob;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
import tech.powerjob.server.common.utils.PropertyUtils;
|
||||
|
||||
/**
|
||||
* powerjob 启动程序
|
||||
*
|
||||
* @author yhan219
|
||||
*/
|
||||
@Slf4j
|
||||
@EnableScheduling
|
||||
@SpringBootApplication(scanBasePackages = "tech.powerjob.server")
|
||||
public class PowerJobServerApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
PropertyUtils.init();
|
||||
SpringApplication.run(tech.powerjob.server.PowerJobServerApplication.class, args);
|
||||
log.info("文档地址: https://www.yuque.com/powerjob/guidence/problem");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
# Http server port
|
||||
server.port=7700
|
||||
|
||||
spring.profiles.active=@profiles.active@
|
||||
spring.main.banner-mode=log
|
||||
spring.jpa.open-in-view=false
|
||||
spring.data.mongodb.repositories.type=none
|
||||
logging.level.org.mongodb=warn
|
||||
logging.config: classpath:logback-plus.xml
|
||||
|
||||
# Configuration for uploading files.
|
||||
spring.servlet.multipart.enabled=true
|
||||
spring.servlet.multipart.file-size-threshold=0
|
||||
spring.servlet.multipart.max-file-size=209715200
|
||||
spring.servlet.multipart.max-request-size=209715200
|
||||
|
||||
###### PowerJob transporter configuration ######
|
||||
oms.transporter.active.protocols=AKKA,HTTP
|
||||
oms.transporter.main.protocol=HTTP
|
||||
oms.akka.port=10086
|
||||
oms.http.port=10010
|
||||
# Prefix for all tables. Default empty string. Config if you have needs, i.e. pj_
|
||||
oms.table-prefix=pj_
|
||||
|
||||
spring.application.name: ruoyi-powerjob-server
|
||||
management.endpoints.web.exposure.include=*
|
||||
management.endpoint.health.show-details=ALWAYS
|
||||
management.endpoint.logfile.external-file=./logs/ruoyi-powerjob-server.log
|
||||
management.health.mongo.enabled=${oms.mongodb.enable}
|
||||
|
||||
# nacos 配置
|
||||
spring.cloud.nacos.server-addr=@nacos.server@
|
||||
spring.cloud.nacos.discovery.group=@nacos.discovery.group@
|
||||
spring.cloud.nacos.discovery.namespace=${spring.profiles.active}
|
||||
spring.cloud.nacos.config.group=@nacos.config.group@
|
||||
spring.cloud.nacos.config.namespace=${spring.profiles.active}
|
||||
spring.config.import[0]=optional:nacos:datasource.yml
|
||||
spring.config.import[1]=optional:nacos:${spring.application.name}.properties
|
||||
@@ -0,0 +1,11 @@
|
||||
Application Version: ${revision}
|
||||
Spring Boot Version: ${spring-boot.version}
|
||||
_ _
|
||||
(_) | |
|
||||
_ __ _____ _____ _ __ _ ___ | |__ ______ ___ ___ _ ____ _____ _ __
|
||||
| '_ \ / _ \ \ /\ / / _ \ '__| |/ _ \| '_ \______/ __|/ _ \ '__\ \ / / _ \ '__|
|
||||
| |_) | (_) \ V V / __/ | | | (_) | |_) | \__ \ __/ | \ V / __/ |
|
||||
| .__/ \___/ \_/\_/ \___|_| | |\___/|_.__/ |___/\___|_| \_/ \___|_|
|
||||
| | _/ |
|
||||
|_| |__/
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration scan="true" scanPeriod="60 seconds" debug="false">
|
||||
|
||||
<!-- 日志存放路径 -->
|
||||
<property name="log.path" value="logs/${project.artifactId}"/>
|
||||
<!-- 日志输出格式 -->
|
||||
<property name="console.log.pattern"
|
||||
value="%red(%d{yyyy-MM-dd HH:mm:ss}) %green([%thread]) %highlight(%-5level) %boldMagenta(%logger{36}%n) - %msg%n"/>
|
||||
|
||||
<!-- 控制台输出 -->
|
||||
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>${console.log.pattern}</pattern>
|
||||
<charset>utf-8</charset>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<include resource="logback-common.xml" />
|
||||
|
||||
<include resource="logback-logstash.xml" />
|
||||
|
||||
<!-- 开启 skywalking 日志收集 -->
|
||||
<include resource="logback-skylog.xml" />
|
||||
|
||||
<!--系统操作日志-->
|
||||
<root level="info">
|
||||
<appender-ref ref="console"/>
|
||||
</root>
|
||||
|
||||
</configuration>
|
||||
Reference in New Issue
Block a user