Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Kwan的解忧杂货铺@新空间代码工作室
Rocketmq
提交
89c0668c
R
Rocketmq
项目概览
Kwan的解忧杂货铺@新空间代码工作室
/
Rocketmq
与 Fork 源项目一致
Fork自
Apache RocketMQ / Rocketmq
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
Rocketmq
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
89c0668c
编写于
12月 27, 2018
作者:
D
dongeforever
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add example conf and bin for dledger
上级
7e8c0125
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
169 addition
and
1 deletion
+169
-1
distribution/bin/dledger/fast-try.sh
distribution/bin/dledger/fast-try.sh
+87
-0
distribution/conf/dledger/broker-n0.conf
distribution/conf/dledger/broker-n0.conf
+27
-0
distribution/conf/dledger/broker-n1.conf
distribution/conf/dledger/broker-n1.conf
+27
-0
distribution/conf/dledger/broker-n2.conf
distribution/conf/dledger/broker-n2.conf
+27
-0
distribution/release.xml
distribution/release.xml
+1
-1
未找到文件。
distribution/bin/dledger/fast-try.sh
0 → 100644
浏览文件 @
89c0668c
#! /bin/bash
## Revise the base dir
CURRENT_DIR
=
"
$(
cd
"
$(
dirname
"
$0
"
)
"
;
pwd
)
"
RMQ_DIR
=
$CURRENT_DIR
/../..
cd
$RMQ_DIR
function
startNameserver
()
{
export
JAVA_OPT_EXT
=
" -Xms512m -Xmx512m "
nohup
bin/mqnamesrv &
}
function
startBroker
()
{
export
JAVA_OPT_EXT
=
" -Xms1g -Xmx1g "
conf_name
=
$1
nohup
bin/mqbroker
-c
$conf_name
&
}
function
stopNameserver
()
{
PIDS
=
$(
ps
-ef
|grep java|grep NamesrvStartup|grep
-v
grep
|awk
'{print $2}'
)
if
[
!
-z
"
$PIDS
"
]
;
then
kill
-s
TERM
$PIDS
fi
}
function
stopBroker
()
{
conf_name
=
$1
PIDS
=
$(
ps
-ef
|grep java|grep BrokerStartup|grep
$conf_name
|grep
-v
grep
|awk
'{print $2}'
)
i
=
1
while
[
!
-z
"
$PIDS
"
-a
$i
-lt
5
]
do
echo
"Waiting to kill ..."
kill
-s
TERM
$PIDS
((
i
=
$i
+1
))
sleep
2
PIDS
=
$(
ps
-ef
|grep java|grep BrokerStartup|grep
$conf_name
|grep
-v
grep
|awk
'{print $2}'
)
done
PIDS
=
$(
ps
-ef
|grep java|grep BrokerStartup|grep
$conf_name
|grep
-v
grep
|awk
'{print $2}'
)
if
[
!
-z
"
$PIDS
"
]
;
then
kill
-9
$PIDS
fi
}
function
stopAll
()
{
ps
-ef
|grep java|grep BrokerStartup|grep
-v
grep
|awk
'{print $2}'
|xargs
kill
stopNameserver
stopBroker ./conf/dledger/broker-n0.conf
stopBroker ./conf/dledger/broker-n1.conf
stopBroker ./conf/dledger/broker-n2.conf
}
function
startAll
()
{
startNameserver
startBroker ./conf/dledger/broker-n0.conf
startBroker ./conf/dledger/broker-n1.conf
startBroker ./conf/dledger/broker-n2.conf
}
function
checkConf
()
{
if
[
!
-f
./conf/dledger/broker-n0.conf
-o
!
-f
./conf/dledger/broker-n1.conf
-o
!
-f
./conf/dledger/broker-n2.conf
]
;
then
echo
"Make sure the ./conf/dledger/broker-n0.conf, ./conf/dledger/broker-n1.conf, ./conf/dledger/broker-n2.conf exists"
exit
-1
fi
}
## Main
if
[
$#
-lt
1
]
;
then
echo
"Usage: sh
$0
start|stop"
exit
-1
fi
action
=
$1
checkConf
case
$action
in
"start"
)
startAll
exit
;;
"stop"
)
stopAll
;;
*
)
echo
"Usage: sh
$0
start|stop"
;;
esac
distribution/conf/dledger/broker-n0.conf
0 → 100644
浏览文件 @
89c0668c
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
brokerClusterName
=
RaftCluster
brokerName
=
RaftNode00
listenPort
=
30911
namesrvAddr
=
127
.
0
.
0
.
1
:
9876
storePathRootDir
=/
tmp
/
rmqstore
/
node00
storePathCommitLog
=/
tmp
/
rmqstore
/
node00
/
commitlog
enableDLegerCommitLog
=
true
dLegerGroup
=
RaftNode00
dLegerPeers
=
n0
-
127
.
0
.
0
.
1
:
40911
;
n1
-
127
.
0
.
0
.
1
:
40912
;
n2
-
127
.
0
.
0
.
1
:
40913
## must be unique
dLegerSelfId
=
n0
sendMessageThreadPoolNums
=
16
distribution/conf/dledger/broker-n1.conf
0 → 100644
浏览文件 @
89c0668c
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
brokerClusterName
=
RaftCluster
brokerName
=
RaftNode00
listenPort
=
30921
namesrvAddr
=
127
.
0
.
0
.
1
:
9876
storePathRootDir
=/
tmp
/
rmqstore
/
node01
storePathCommitLog
=/
tmp
/
rmqstore
/
node01
/
commitlog
enableDLegerCommitLog
=
true
dLegerGroup
=
RaftNode00
dLegerPeers
=
n0
-
127
.
0
.
0
.
1
:
40911
;
n1
-
127
.
0
.
0
.
1
:
40912
;
n2
-
127
.
0
.
0
.
1
:
40913
## must be unique
dLegerSelfId
=
n1
sendMessageThreadPoolNums
=
16
distribution/conf/dledger/broker-n2.conf
0 → 100644
浏览文件 @
89c0668c
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
brokerClusterName
=
RaftCluster
brokerName
=
RaftNode00
listenPort
=
30931
namesrvAddr
=
127
.
0
.
0
.
1
:
9876
storePathRootDir
=/
tmp
/
rmqstore
/
node02
storePathCommitLog
=/
tmp
/
rmqstore
/
node02
/
commitlog
enableDLegerCommitLog
=
true
dLegerGroup
=
RaftNode00
dLegerPeers
=
n0
-
127
.
0
.
0
.
1
:
40911
;
n1
-
127
.
0
.
0
.
1
:
40912
;
n2
-
127
.
0
.
0
.
1
:
40913
## must be unique
dLegerSelfId
=
n2
sendMessageThreadPoolNums
=
16
distribution/release.xml
浏览文件 @
89c0668c
...
...
@@ -40,7 +40,7 @@
<fileSet>
<includes>
<include>
bin/*
</include>
<include>
bin/*
*
</include>
</includes>
<fileMode>
0755
</fileMode>
</fileSet>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录