Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
老大叔也想要天天的爱情
DolphinScheduler
提交
c8b0c1f1
DolphinScheduler
项目概览
老大叔也想要天天的爱情
/
DolphinScheduler
与 Fork 源项目一致
Fork自
apache / DolphinScheduler
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
DolphinScheduler
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
c8b0c1f1
编写于
11月 17, 2019
作者:
B
Baoqi Wu
提交者:
qiaozhanwei
11月 17, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
make combined server works in new dev-db branch (#1257)
上级
ef86be2d
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
40 addition
and
7 deletion
+40
-7
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/CombinedApplicationServer.java
...pache/dolphinscheduler/api/CombinedApplicationServer.java
+2
-4
dolphinscheduler-api/src/main/resources/application-combined.properties
...er-api/src/main/resources/application-combined.properties
+23
-0
dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/worker/WorkerServer.java
...g/apache/dolphinscheduler/server/worker/WorkerServer.java
+12
-3
script/dolphinscheduler-daemon.sh
script/dolphinscheduler-daemon.sh
+3
-0
未找到文件。
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/CombinedApplicationServer.java
浏览文件 @
c8b0c1f1
...
...
@@ -24,11 +24,13 @@ import org.springframework.boot.autoconfigure.SpringBootApplication;
import
org.springframework.boot.web.servlet.ServletComponentScan
;
import
org.springframework.boot.web.servlet.support.SpringBootServletInitializer
;
import
org.springframework.context.annotation.ComponentScan
;
import
org.springframework.context.annotation.Import
;
import
springfox.documentation.swagger2.annotations.EnableSwagger2
;
@SpringBootApplication
@ServletComponentScan
@ComponentScan
(
"org.apache.dolphinscheduler"
)
@Import
({
MasterServer
.
class
,
WorkerServer
.
class
})
@EnableSwagger2
public
class
CombinedApplicationServer
extends
SpringBootServletInitializer
{
...
...
@@ -36,10 +38,6 @@ public class CombinedApplicationServer extends SpringBootServletInitializer {
ApiApplicationServer
.
main
(
args
);
MasterServer
.
main
(
args
);
WorkerServer
.
main
(
args
);
LoggerServer
server
=
new
LoggerServer
();
server
.
start
();
...
...
dolphinscheduler-api/src/main/resources/application-combined.properties
0 → 100644
浏览文件 @
c8b0c1f1
logging.config
=
classpath:combined_logback.xml
# server port
server.port
=
12345
# session config
server.servlet.session.timeout
=
7200
server.servlet.context-path
=
/dolphinscheduler/
# file size limit for upload
spring.servlet.multipart.max-file-size
=
1024MB
spring.servlet.multipart.max-request-size
=
1024MB
#post content
server.jetty.max-http-post-size
=
5000000
spring.messages.encoding
=
UTF-8
#i18n classpath folder , file prefix messages, if have many files, use "," seperator
spring.messages.basename
=
i18n/messages
server.is-combined-server
=
true
dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/worker/WorkerServer.java
浏览文件 @
c8b0c1f1
...
...
@@ -42,6 +42,7 @@ import org.apache.dolphinscheduler.server.zk.ZKWorkerClient;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.boot.SpringApplication
;
import
org.springframework.context.annotation.ComponentScan
;
...
...
@@ -114,6 +115,12 @@ public class WorkerServer extends AbstractServer {
*/
private
CountDownLatch
latch
;
/**
* If inside combined server, WorkerServer no need to await on CountDownLatch
*/
@Value
(
"${server.is-combined-server:false}"
)
private
Boolean
isCombinedServer
;
/**
* master server startup
*
...
...
@@ -196,9 +203,11 @@ public class WorkerServer extends AbstractServer {
//let the main thread await
latch
=
new
CountDownLatch
(
1
);
try
{
latch
.
await
();
}
catch
(
InterruptedException
ignore
)
{
if
(!
isCombinedServer
)
{
try
{
latch
.
await
();
}
catch
(
InterruptedException
ignore
)
{
}
}
}
...
...
script/dolphinscheduler-daemon.sh
浏览文件 @
c8b0c1f1
...
...
@@ -54,6 +54,9 @@ elif [ "$command" = "alert-server" ]; then
CLASS
=
org.apache.dolphinscheduler.alert.AlertServer
elif
[
"
$command
"
=
"logger-server"
]
;
then
CLASS
=
org.apache.dolphinscheduler.server.rpc.LoggerServer
elif
[
"
$command
"
=
"combined-server"
]
;
then
LOG_FILE
=
"-Dspring.profiles.active=combined"
CLASS
=
org.apache.dolphinscheduler.api.CombinedApplicationServer
else
echo
"Error: No command named
\`
$command
' was found."
exit
1
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录