Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
Harvey
/
job-executor
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 2188ea7a
由
Harvey
编写于
2025-04-28 15:55:05 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
no message
1 个父辈
f1ce9450
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
6 行增加
和
9 行删除
build/index.js
src/index.ts
build/index.js
查看文件 @
2188ea7
...
...
@@ -2,11 +2,9 @@
Object
.
defineProperty
(
exports
,
"__esModule"
,
{
value
:
true
});
const
express
=
require
(
"express"
);
const
config
=
require
(
'../config/config.js'
);
const
index_1
=
require
(
"./job/index"
);
const
index_2
=
require
(
"./xxl_job/index"
);
const
app
=
express
();
app
.
use
(
require
(
'body-parser'
).
json
());
new
index_2
.
XxlJobExecutor
(
config
.
xxl_job
,
index_1
.
job_handlers
).
applyMiddleware
({
app
,
domain
:
config
.
app_domain
,
path
:
''
});
new
(
require
(
"./xxl_job/index"
).
XxlJobExecutor
)(
config
.
xxl_job
,
require
(
'./job'
)
.
job_handlers
).
applyMiddleware
({
app
,
domain
:
config
.
app_domain
,
path
:
''
});
app
.
listen
(
config
.
port
,
()
=>
{
console
.
log
(
`job-ydn-zq app listening on port
${
config
.
port
}
`
);
});
...
...
src/index.ts
查看文件 @
2188ea7
import
*
as
express
from
'express'
import
*
as
express
from
'express'
const
config
=
require
(
'../config/config.js'
)
import
{
job_handlers
}
from
'./job/index'
import
{
XxlJobExecutor
}
from
'./xxl_job/index'
const
app
=
express
()
app
.
use
(
require
(
'body-parser'
).
json
())
new
XxlJobExecutor
(
config
.
xxl_job
,
job_handlers
).
applyMiddleware
({
app
,
domain
:
config
.
app_domain
,
path
:
''
})
new
(
require
(
"./xxl_job/index"
).
XxlJobExecutor
)(
config
.
xxl_job
,
require
(
'./job'
).
job_handlers
).
applyMiddleware
({
app
,
domain
:
config
.
app_domain
,
path
:
''
})
app
.
listen
(
config
.
port
,
()
=>
{
console
.
log
(
`job-ydn-zq app listening on port
${
config
.
port
}
`
)
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论