Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Kwan的解忧杂货铺@新空间代码工作室
Rocketmq
提交
4117d001
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看板
未验证
提交
4117d001
编写于
4月 14, 2021
作者:
P
ph3636
提交者:
GitHub
4月 14, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[ISSUE 2800] optimize: the spelling of topicSynFlag
Co-authored-by:
N
ph3636
<
tianxingguang@kanzhun.com
>
上级
0f860e5c
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
22 addition
and
22 deletion
+22
-22
client/src/test/java/org/apache/rocketmq/client/impl/factory/MQClientInstanceTest.java
...he/rocketmq/client/impl/factory/MQClientInstanceTest.java
+1
-1
client/src/test/java/org/apache/rocketmq/client/producer/DefaultMQProducerTest.java
...pache/rocketmq/client/producer/DefaultMQProducerTest.java
+1
-1
client/src/test/java/org/apache/rocketmq/client/trace/DefaultMQConsumerWithTraceTest.java
...rocketmq/client/trace/DefaultMQConsumerWithTraceTest.java
+2
-2
client/src/test/java/org/apache/rocketmq/client/trace/DefaultMQProducerWithTraceTest.java
...rocketmq/client/trace/DefaultMQProducerWithTraceTest.java
+2
-2
common/src/main/java/org/apache/rocketmq/common/protocol/route/QueueData.java
.../org/apache/rocketmq/common/protocol/route/QueueData.java
+8
-8
common/src/test/java/org/apache/rocketmq/common/protocol/route/TopicRouteDataTest.java
...he/rocketmq/common/protocol/route/TopicRouteDataTest.java
+2
-2
namesrv/src/main/java/org/apache/rocketmq/namesrv/routeinfo/RouteInfoManager.java
...g/apache/rocketmq/namesrv/routeinfo/RouteInfoManager.java
+5
-5
tools/src/main/java/org/apache/rocketmq/tools/command/topic/UpdateTopicPermSubCommand.java
...cketmq/tools/command/topic/UpdateTopicPermSubCommand.java
+1
-1
未找到文件。
client/src/test/java/org/apache/rocketmq/client/impl/factory/MQClientInstanceTest.java
浏览文件 @
4117d001
...
...
@@ -79,7 +79,7 @@ public class MQClientInstanceTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
3
);
queueData
.
setWriteQueueNums
(
4
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
...
...
client/src/test/java/org/apache/rocketmq/client/producer/DefaultMQProducerTest.java
浏览文件 @
4117d001
...
...
@@ -481,7 +481,7 @@ public class DefaultMQProducerTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
3
);
queueData
.
setWriteQueueNums
(
4
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
return
topicRouteData
;
...
...
client/src/test/java/org/apache/rocketmq/client/trace/DefaultMQConsumerWithTraceTest.java
浏览文件 @
4117d001
...
...
@@ -273,7 +273,7 @@ public class DefaultMQConsumerWithTraceTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
3
);
queueData
.
setWriteQueueNums
(
4
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
return
topicRouteData
;
...
...
@@ -309,7 +309,7 @@ public class DefaultMQConsumerWithTraceTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
1
);
queueData
.
setWriteQueueNums
(
1
);
queueData
.
setTopicSy
n
Flag
(
1
);
queueData
.
setTopicSy
s
Flag
(
1
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
return
topicRouteData
;
...
...
client/src/test/java/org/apache/rocketmq/client/trace/DefaultMQProducerWithTraceTest.java
浏览文件 @
4117d001
...
...
@@ -168,7 +168,7 @@ public class DefaultMQProducerWithTraceTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
3
);
queueData
.
setWriteQueueNums
(
4
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
return
topicRouteData
;
...
...
@@ -204,7 +204,7 @@ public class DefaultMQProducerWithTraceTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
1
);
queueData
.
setWriteQueueNums
(
1
);
queueData
.
setTopicSy
n
Flag
(
1
);
queueData
.
setTopicSy
s
Flag
(
1
);
queueDataList
.
add
(
queueData
);
topicRouteData
.
setQueueDatas
(
queueDataList
);
return
topicRouteData
;
...
...
common/src/main/java/org/apache/rocketmq/common/protocol/route/QueueData.java
浏览文件 @
4117d001
...
...
@@ -25,7 +25,7 @@ public class QueueData implements Comparable<QueueData> {
private
int
readQueueNums
;
private
int
writeQueueNums
;
private
int
perm
;
private
int
topicSy
n
Flag
;
private
int
topicSy
s
Flag
;
public
int
getReadQueueNums
()
{
return
readQueueNums
;
...
...
@@ -51,12 +51,12 @@ public class QueueData implements Comparable<QueueData> {
this
.
perm
=
perm
;
}
public
int
getTopicSy
n
Flag
()
{
return
topicSy
n
Flag
;
public
int
getTopicSy
s
Flag
()
{
return
topicSy
s
Flag
;
}
public
void
setTopicSy
nFlag
(
int
topicSyn
Flag
)
{
this
.
topicSy
nFlag
=
topicSyn
Flag
;
public
void
setTopicSy
sFlag
(
int
topicSys
Flag
)
{
this
.
topicSy
sFlag
=
topicSys
Flag
;
}
@Override
...
...
@@ -67,7 +67,7 @@ public class QueueData implements Comparable<QueueData> {
result
=
prime
*
result
+
perm
;
result
=
prime
*
result
+
readQueueNums
;
result
=
prime
*
result
+
writeQueueNums
;
result
=
prime
*
result
+
topicSy
n
Flag
;
result
=
prime
*
result
+
topicSy
s
Flag
;
return
result
;
}
...
...
@@ -91,7 +91,7 @@ public class QueueData implements Comparable<QueueData> {
return
false
;
if
(
writeQueueNums
!=
other
.
writeQueueNums
)
return
false
;
if
(
topicSy
nFlag
!=
other
.
topicSyn
Flag
)
if
(
topicSy
sFlag
!=
other
.
topicSys
Flag
)
return
false
;
return
true
;
}
...
...
@@ -99,7 +99,7 @@ public class QueueData implements Comparable<QueueData> {
@Override
public
String
toString
()
{
return
"QueueData [brokerName="
+
brokerName
+
", readQueueNums="
+
readQueueNums
+
", writeQueueNums="
+
writeQueueNums
+
", perm="
+
perm
+
", topicSy
nFlag="
+
topicSyn
Flag
+
", writeQueueNums="
+
writeQueueNums
+
", perm="
+
perm
+
", topicSy
sFlag="
+
topicSys
Flag
+
"]"
;
}
...
...
common/src/test/java/org/apache/rocketmq/common/protocol/route/TopicRouteDataTest.java
浏览文件 @
4117d001
...
...
@@ -43,7 +43,7 @@ public class TopicRouteDataTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
8
);
queueData
.
setWriteQueueNums
(
8
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
List
<
QueueData
>
queueDataList
=
new
ArrayList
<
QueueData
>();
queueDataList
.
add
(
queueData
);
...
...
@@ -78,7 +78,7 @@ public class TopicRouteDataTest {
queueData
.
setPerm
(
6
);
queueData
.
setReadQueueNums
(
8
);
queueData
.
setWriteQueueNums
(
8
);
queueData
.
setTopicSy
n
Flag
(
0
);
queueData
.
setTopicSy
s
Flag
(
0
);
List
<
QueueData
>
queueDataList
=
new
ArrayList
<
QueueData
>();
queueDataList
.
add
(
queueData
);
...
...
namesrv/src/main/java/org/apache/rocketmq/namesrv/routeinfo/RouteInfoManager.java
浏览文件 @
4117d001
...
...
@@ -220,7 +220,7 @@ public class RouteInfoManager {
queueData
.
setWriteQueueNums
(
topicConfig
.
getWriteQueueNums
());
queueData
.
setReadQueueNums
(
topicConfig
.
getReadQueueNums
());
queueData
.
setPerm
(
topicConfig
.
getPerm
());
queueData
.
setTopicSy
n
Flag
(
topicConfig
.
getTopicSysFlag
());
queueData
.
setTopicSy
s
Flag
(
topicConfig
.
getTopicSysFlag
());
List
<
QueueData
>
queueDataList
=
this
.
topicQueueTable
.
get
(
topicConfig
.
getTopicName
());
if
(
null
==
queueDataList
)
{
...
...
@@ -684,7 +684,7 @@ public class RouteInfoManager {
String
topic
=
topicEntry
.
getKey
();
List
<
QueueData
>
queueDatas
=
topicEntry
.
getValue
();
if
(
queueDatas
!=
null
&&
queueDatas
.
size
()
>
0
&&
TopicSysFlag
.
hasUnitFlag
(
queueDatas
.
get
(
0
).
getTopicSy
n
Flag
()))
{
&&
TopicSysFlag
.
hasUnitFlag
(
queueDatas
.
get
(
0
).
getTopicSy
s
Flag
()))
{
topicList
.
getTopicList
().
add
(
topic
);
}
}
...
...
@@ -710,7 +710,7 @@ public class RouteInfoManager {
String
topic
=
topicEntry
.
getKey
();
List
<
QueueData
>
queueDatas
=
topicEntry
.
getValue
();
if
(
queueDatas
!=
null
&&
queueDatas
.
size
()
>
0
&&
TopicSysFlag
.
hasUnitSubFlag
(
queueDatas
.
get
(
0
).
getTopicSy
n
Flag
()))
{
&&
TopicSysFlag
.
hasUnitSubFlag
(
queueDatas
.
get
(
0
).
getTopicSy
s
Flag
()))
{
topicList
.
getTopicList
().
add
(
topic
);
}
}
...
...
@@ -736,8 +736,8 @@ public class RouteInfoManager {
String
topic
=
topicEntry
.
getKey
();
List
<
QueueData
>
queueDatas
=
topicEntry
.
getValue
();
if
(
queueDatas
!=
null
&&
queueDatas
.
size
()
>
0
&&
!
TopicSysFlag
.
hasUnitFlag
(
queueDatas
.
get
(
0
).
getTopicSy
n
Flag
())
&&
TopicSysFlag
.
hasUnitSubFlag
(
queueDatas
.
get
(
0
).
getTopicSy
n
Flag
()))
{
&&
!
TopicSysFlag
.
hasUnitFlag
(
queueDatas
.
get
(
0
).
getTopicSy
s
Flag
())
&&
TopicSysFlag
.
hasUnitSubFlag
(
queueDatas
.
get
(
0
).
getTopicSy
s
Flag
()))
{
topicList
.
getTopicList
().
add
(
topic
);
}
}
...
...
tools/src/main/java/org/apache/rocketmq/tools/command/topic/UpdateTopicPermSubCommand.java
浏览文件 @
4117d001
...
...
@@ -94,7 +94,7 @@ public class UpdateTopicPermSubCommand implements SubCommand {
topicConfig
.
setTopicName
(
topic
);
topicConfig
.
setWriteQueueNums
(
queueData
.
getWriteQueueNums
());
topicConfig
.
setReadQueueNums
(
queueData
.
getReadQueueNums
());
topicConfig
.
setTopicSysFlag
(
queueData
.
getTopicSy
n
Flag
());
topicConfig
.
setTopicSysFlag
(
queueData
.
getTopicSy
s
Flag
());
//new perm
int
perm
;
if
(
commandLine
.
hasOption
(
'p'
))
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录