This is an automated email from the ASF dual-hosted git repository. jinrongtong pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/rocketmq.git
The following commit(s) were added to refs/heads/develop by this push: new c033c3e85f [ISSUE #8848] Fix log typo c033c3e85f is described below commit c033c3e85f9487e07a0c521082df34f1cd686bb4 Author: mawen12 <118196301...@gmail.com> AuthorDate: Wed Oct 23 08:29:35 2024 +0800 [ISSUE #8848] Fix log typo --- .../org/apache/rocketmq/broker/BrokerController.java | 2 +- .../client/impl/factory/MQClientInstance.java | 2 +- .../statistics/StatisticsBriefInterceptor.java | 2 +- .../StatisticsItemScheduledIncrementPrinter.java | 12 ++++++------ .../protocol/statictopic/TopicQueueMappingUtils.java | 20 ++++++++++---------- .../org/apache/rocketmq/store/timer/TimerLog.java | 2 +- .../apache/rocketmq/test/util/MQAdminTestUtils.java | 4 ++-- .../broadcast/order/OrderMsgBroadcastIT.java | 2 +- 8 files changed, 23 insertions(+), 23 deletions(-) diff --git a/broker/src/main/java/org/apache/rocketmq/broker/BrokerController.java b/broker/src/main/java/org/apache/rocketmq/broker/BrokerController.java index aaf06caddf..05a00a5005 100644 --- a/broker/src/main/java/org/apache/rocketmq/broker/BrokerController.java +++ b/broker/src/main/java/org/apache/rocketmq/broker/BrokerController.java @@ -1010,7 +1010,7 @@ public class BrokerController { private void initialAcl() { if (!this.brokerConfig.isAclEnable()) { - LOG.info("The broker dose not enable acl"); + LOG.info("The broker does not enable acl"); return; } diff --git a/client/src/main/java/org/apache/rocketmq/client/impl/factory/MQClientInstance.java b/client/src/main/java/org/apache/rocketmq/client/impl/factory/MQClientInstance.java index c9fd3c83e0..ad0676d091 100644 --- a/client/src/main/java/org/apache/rocketmq/client/impl/factory/MQClientInstance.java +++ b/client/src/main/java/org/apache/rocketmq/client/impl/factory/MQClientInstance.java @@ -1238,7 +1238,7 @@ public class MQClientInstance { if (impl instanceof DefaultMQPushConsumerImpl) { consumer = (DefaultMQPushConsumerImpl) impl; } else { - log.info("[reset-offset] consumer dose not exist. group={}", group); + log.info("[reset-offset] consumer does not exist. group={}", group); return; } consumer.suspend(); diff --git a/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsBriefInterceptor.java b/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsBriefInterceptor.java index b0b6937844..3ec295f54c 100644 --- a/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsBriefInterceptor.java +++ b/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsBriefInterceptor.java @@ -34,7 +34,7 @@ public class StatisticsBriefInterceptor implements Interceptor { String name = briefMetas[i].getKey(); int index = ArrayUtils.indexOf(item.getItemNames(), name); if (index < 0) { - throw new IllegalArgumentException("illegal breifItemName: " + name); + throw new IllegalArgumentException("illegal briefItemName: " + name); } indexOfItems[i] = index; statisticsBriefs[i] = new StatisticsBrief(briefMetas[i].getValue()); diff --git a/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsItemScheduledIncrementPrinter.java b/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsItemScheduledIncrementPrinter.java index 2890e6e15c..e1998473bf 100644 --- a/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsItemScheduledIncrementPrinter.java +++ b/common/src/main/java/org/apache/rocketmq/common/statistics/StatisticsItemScheduledIncrementPrinter.java @@ -65,15 +65,15 @@ public class StatisticsItemScheduledIncrementPrinter extends StatisticsItemSched item.getStatObject()); StatisticsItem increment = snapshot.subtract(lastSnapshot); - Interceptor inteceptor = item.getInterceptor(); - String inteceptorStr = formatInterceptor(inteceptor); - if (inteceptor != null) { - inteceptor.reset(); + Interceptor interceptor = item.getInterceptor(); + String interceptorStr = formatInterceptor(interceptor); + if (interceptor != null) { + interceptor.reset(); } StatisticsItemSampleBrief brief = getSampleBrief(item.getStatKind(), item.getStatObject()); if (brief != null && (!increment.allZeros() || printZeroLine())) { - printer.print(name, increment, inteceptorStr, brief.toString()); + printer.print(name, increment, interceptorStr, brief.toString()); } setItemSnapshot(lastItemSnapshots, snapshot); @@ -85,7 +85,7 @@ public class StatisticsItemScheduledIncrementPrinter extends StatisticsItemSched }, getInitialDelay(), interval, TimeUnit.MILLISECONDS); addFuture(item, future); - // sample every TPS_INTREVAL + // sample every TPS_INTERVAL ScheduledFuture futureSample = executor.scheduleAtFixedRate(new Runnable() { @Override public void run() { diff --git a/remoting/src/main/java/org/apache/rocketmq/remoting/protocol/statictopic/TopicQueueMappingUtils.java b/remoting/src/main/java/org/apache/rocketmq/remoting/protocol/statictopic/TopicQueueMappingUtils.java index 45cbed7572..647669fde2 100644 --- a/remoting/src/main/java/org/apache/rocketmq/remoting/protocol/statictopic/TopicQueueMappingUtils.java +++ b/remoting/src/main/java/org/apache/rocketmq/remoting/protocol/statictopic/TopicQueueMappingUtils.java @@ -172,21 +172,21 @@ public class TopicQueueMappingUtils { if (scope != null && !scope.equals(mappingDetail.getScope())) { - throw new RuntimeException(String.format("scope dose not match %s != %s in %s", mappingDetail.getScope(), scope, broker)); + throw new RuntimeException(String.format("scope does not match %s != %s in %s", mappingDetail.getScope(), scope, broker)); } else { scope = mappingDetail.getScope(); } if (maxEpoch != -1 && maxEpoch != mappingDetail.getEpoch()) { - throw new RuntimeException(String.format("epoch dose not match %d != %d in %s", maxEpoch, mappingDetail.getEpoch(), mappingDetail.getBname())); + throw new RuntimeException(String.format("epoch does not match %d != %d in %s", maxEpoch, mappingDetail.getEpoch(), mappingDetail.getBname())); } else { maxEpoch = mappingDetail.getEpoch(); } if (maxNum != -1 && maxNum != mappingDetail.getTotalQueues()) { - throw new RuntimeException(String.format("total queue number dose not match %d != %d in %s", maxNum, mappingDetail.getTotalQueues(), mappingDetail.getBname())); + throw new RuntimeException(String.format("total queue number does not match %d != %d in %s", maxNum, mappingDetail.getTotalQueues(), mappingDetail.getBname())); } else { maxNum = mappingDetail.getTotalQueues(); } @@ -266,7 +266,7 @@ public class TopicQueueMappingUtils { throw new RuntimeException("The non-latest item has negative logic offset"); } if (lastGen != -1 && item.getGen() >= lastGen) { - throw new RuntimeException("The gen dose not increase monotonically"); + throw new RuntimeException("The gen does not increase monotonically"); } if (item.getEndOffset() != -1 @@ -276,10 +276,10 @@ public class TopicQueueMappingUtils { if (lastOffset != -1 && item.getLogicOffset() != -1) { if (item.getLogicOffset() >= lastOffset) { - throw new RuntimeException("The base logic offset dose not increase monotonically"); + throw new RuntimeException("The base logic offset does not increase monotonically"); } if (item.computeMaxStaticQueueOffset() >= lastOffset) { - throw new RuntimeException("The max logic offset dose not increase monotonically"); + throw new RuntimeException("The max logic offset does not increase monotonically"); } } lastGen = item.getGen(); @@ -321,11 +321,11 @@ public class TopicQueueMappingUtils { for (List<LogicQueueMappingItem> items: configMapping.getMappingDetail().getHostedQueues().values()) { for (LogicQueueMappingItem item: items) { if (item.getStartOffset() != 0) { - throw new RuntimeException("The start offset dose not begin from 0"); + throw new RuntimeException("The start offset does not begin from 0"); } TopicConfig topicConfig = brokerConfigMap.get(item.getBname()); if (topicConfig == null) { - throw new RuntimeException("The broker of item dose not exist"); + throw new RuntimeException("The broker of item does not exist"); } if (item.getQueueId() >= topicConfig.getWriteQueueNums()) { throw new RuntimeException("The physical queue id is overflow the write queues"); @@ -365,7 +365,7 @@ public class TopicQueueMappingUtils { } if (checkConsistence) { if (maxNum != globalIdMap.size()) { - throw new RuntimeException(String.format("The total queue number in config dose not match the real hosted queues %d != %d", maxNum, globalIdMap.size())); + throw new RuntimeException(String.format("The total queue number in config does not match the real hosted queues %d != %d", maxNum, globalIdMap.size())); } for (int i = 0; i < maxNum; i++) { if (!globalIdMap.containsKey(i)) { @@ -417,7 +417,7 @@ public class TopicQueueMappingUtils { continue; } if (!targetBrokers.contains(broker)) { - throw new RuntimeException("The existed broker " + broker + " dose not in target brokers "); + throw new RuntimeException("The existed broker " + broker + " does not in target brokers "); } } } diff --git a/store/src/main/java/org/apache/rocketmq/store/timer/TimerLog.java b/store/src/main/java/org/apache/rocketmq/store/timer/TimerLog.java index e0836fef18..8c93d3d526 100644 --- a/store/src/main/java/org/apache/rocketmq/store/timer/TimerLog.java +++ b/store/src/main/java/org/apache/rocketmq/store/timer/TimerLog.java @@ -117,7 +117,7 @@ public class TimerLog { // be careful. // if the format of timerlog changed, this offset has to be changed too - // so dose the batch writing + // so does the batch writing public int getOffsetForLastUnit() { return fileSize - (fileSize - MIN_BLANK_LEN) % UNIT_SIZE - MIN_BLANK_LEN - UNIT_SIZE; diff --git a/test/src/main/java/org/apache/rocketmq/test/util/MQAdminTestUtils.java b/test/src/main/java/org/apache/rocketmq/test/util/MQAdminTestUtils.java index 47a8db3c9a..276d08d806 100644 --- a/test/src/main/java/org/apache/rocketmq/test/util/MQAdminTestUtils.java +++ b/test/src/main/java/org/apache/rocketmq/test/util/MQAdminTestUtils.java @@ -193,7 +193,7 @@ public class MQAdminTestUtils { return true; } - //should only be test, if some middle operation failed, it dose not backup the brokerConfigMap + //should only be test, if some middle operation failed, it does not backup the brokerConfigMap public static Map<String, TopicConfigAndQueueMapping> createStaticTopic(String topic, int queueNum, Set<String> targetBrokers, DefaultMQAdminExt defaultMQAdminExt) throws Exception { Map<String, TopicConfigAndQueueMapping> brokerConfigMap = MQAdminUtils.examineTopicConfigAll(topic, defaultMQAdminExt); assert brokerConfigMap.isEmpty(); @@ -203,7 +203,7 @@ public class MQAdminTestUtils { return brokerConfigMap; } - //should only be test, if some middle operation failed, it dose not backup the brokerConfigMap + //should only be test, if some middle operation failed, it does not backup the brokerConfigMap public static void remappingStaticTopic(String topic, Set<String> targetBrokers, DefaultMQAdminExt defaultMQAdminExt) throws Exception { Map<String, TopicConfigAndQueueMapping> brokerConfigMap = MQAdminUtils.examineTopicConfigAll(topic, defaultMQAdminExt); assert !brokerConfigMap.isEmpty(); diff --git a/test/src/test/java/org/apache/rocketmq/test/client/consumer/broadcast/order/OrderMsgBroadcastIT.java b/test/src/test/java/org/apache/rocketmq/test/client/consumer/broadcast/order/OrderMsgBroadcastIT.java index 679fdd4f38..d1e2c0ddaf 100644 --- a/test/src/test/java/org/apache/rocketmq/test/client/consumer/broadcast/order/OrderMsgBroadcastIT.java +++ b/test/src/test/java/org/apache/rocketmq/test/client/consumer/broadcast/order/OrderMsgBroadcastIT.java @@ -36,7 +36,7 @@ import org.junit.Test; import static com.google.common.truth.Truth.assertThat; /** - * Currently, dose not support the ordered broadcast message + * Currently, does not support the ordered broadcast message */ @Ignore public class OrderMsgBroadcastIT extends BaseBroadcast {