This is an automated email from the ASF dual-hosted git repository.

rainyu pushed a commit to branch 3.3
in repository https://gitbox.apache.org/repos/asf/dubbo.git


The following commit(s) were added to refs/heads/3.3 by this push:
     new 8dabe605ad fix typos (#15625)
8dabe605ad is described below

commit 8dabe605ad5ddb0698035158b2b0e60e597a5c6f
Author: co63oc <[email protected]>
AuthorDate: Fri Aug 8 10:24:45 2025 +0800

    fix typos (#15625)
    
    * fix typos
    
    * fix
---
 .../org/apache/dubbo/common/constants/RegistryConstants.java |  2 +-
 .../java/org/apache/dubbo/common/timer/HashedWheelTimer.java |  8 ++++----
 .../java/org/apache/dubbo/registry/nacos/NacosRegistry.java  |  6 +++---
 .../org/apache/dubbo/remoting/codec/ExchangeCodecTest.java   | 10 +++++-----
 .../main/java/org/apache/dubbo/rpc/filter/GenericFilter.java | 12 ++++++------
 .../java/org/apache/dubbo/rpc/protocol/tri/RequestPath.java  |  2 +-
 .../rpc/protocol/tri/TripleCustomerProtocolWrapper.java      |  6 ++++--
 .../apache/dubbo/rpc/protocol/tri/TriplePathResolver.java    |  2 +-
 8 files changed, 25 insertions(+), 23 deletions(-)

diff --git 
a/dubbo-common/src/main/java/org/apache/dubbo/common/constants/RegistryConstants.java
 
b/dubbo-common/src/main/java/org/apache/dubbo/common/constants/RegistryConstants.java
index 0b7732ec8b..aff18763b9 100644
--- 
a/dubbo-common/src/main/java/org/apache/dubbo/common/constants/RegistryConstants.java
+++ 
b/dubbo-common/src/main/java/org/apache/dubbo/common/constants/RegistryConstants.java
@@ -148,5 +148,5 @@ public interface RegistryConstants {
      * by default, dubbo export servicename is "${interface}:${version}:", 
this servicename with ':' suffix
      * for compatible, we should export noting suffix servicename, eg: 
${interface}:${version}
      */
-    String NACOE_REGISTER_COMPATIBLE = "nacos.register-compatible";
+    String NACOS_REGISTER_COMPATIBLE = "nacos.register-compatible";
 }
diff --git 
a/dubbo-common/src/main/java/org/apache/dubbo/common/timer/HashedWheelTimer.java
 
b/dubbo-common/src/main/java/org/apache/dubbo/common/timer/HashedWheelTimer.java
index 8b6d57589c..1fc08f97ca 100644
--- 
a/dubbo-common/src/main/java/org/apache/dubbo/common/timer/HashedWheelTimer.java
+++ 
b/dubbo-common/src/main/java/org/apache/dubbo/common/timer/HashedWheelTimer.java
@@ -88,7 +88,7 @@ public class HashedWheelTimer implements Timer {
     /**
      * may be in spi?
      */
-    public static final String NAME = "hased";
+    public static final String NAME = "hashed";
 
     private static final ErrorTypeAwareLogger logger = 
LoggerFactory.getErrorTypeAwareLogger(HashedWheelTimer.class);
 
@@ -306,11 +306,11 @@ public class HashedWheelTimer implements Timer {
     }
 
     /**
-     * Starts the background thread explicitly.  The background thread will
+     * Starts the background thread explicitly. The background thread will
      * start automatically on demand even if you did not call this method.
      *
      * @throws IllegalStateException if this timer has been
-     *                               {@linkplain #stop() stopped} already
+     * {@linkplain #stop() stopped} already
      */
     public void start() {
         switch (WORKER_STATE_UPDATER.get(this)) {
@@ -698,7 +698,7 @@ public class HashedWheelTimer implements Timer {
     private static final class HashedWheelBucket {
 
         /**
-         * Used for the linked-list datastructure
+         * Used for the linked-list data structure
          */
         private HashedWheelTimeout head;
         private HashedWheelTimeout tail;
diff --git 
a/dubbo-registry/dubbo-registry-nacos/src/main/java/org/apache/dubbo/registry/nacos/NacosRegistry.java
 
b/dubbo-registry/dubbo-registry-nacos/src/main/java/org/apache/dubbo/registry/nacos/NacosRegistry.java
index fa8d64c756..fbeb9cf987 100644
--- 
a/dubbo-registry/dubbo-registry-nacos/src/main/java/org/apache/dubbo/registry/nacos/NacosRegistry.java
+++ 
b/dubbo-registry/dubbo-registry-nacos/src/main/java/org/apache/dubbo/registry/nacos/NacosRegistry.java
@@ -75,7 +75,7 @@ import static 
org.apache.dubbo.common.constants.RegistryConstants.DEFAULT_CATEGO
 import static 
org.apache.dubbo.common.constants.RegistryConstants.DEFAULT_ENABLE_EMPTY_PROTECTION;
 import static 
org.apache.dubbo.common.constants.RegistryConstants.EMPTY_PROTOCOL;
 import static 
org.apache.dubbo.common.constants.RegistryConstants.ENABLE_EMPTY_PROTECTION_KEY;
-import static 
org.apache.dubbo.common.constants.RegistryConstants.NACOE_REGISTER_COMPATIBLE;
+import static 
org.apache.dubbo.common.constants.RegistryConstants.NACOS_REGISTER_COMPATIBLE;
 import static 
org.apache.dubbo.common.constants.RegistryConstants.PROVIDERS_CATEGORY;
 import static 
org.apache.dubbo.common.constants.RegistryConstants.REGISTER_CONSUMER_URL_KEY;
 import static 
org.apache.dubbo.common.constants.RegistryConstants.ROUTERS_CATEGORY;
@@ -188,7 +188,7 @@ public class NacosRegistry extends FailbackRegistry {
                 serviceNames.add(serviceName);
 
                 // in https://github.com/apache/dubbo/issues/14075
-                if (getUrl().getParameter(NACOE_REGISTER_COMPATIBLE, false)) {
+                if (getUrl().getParameter(NACOS_REGISTER_COMPATIBLE, false)) {
                     // servicename is "org.apache.dubbo.xxService:1.0.0"
                     String compatibleServiceName = getServiceName(url, true);
                     serviceNames.add(compatibleServiceName);
@@ -227,7 +227,7 @@ public class NacosRegistry extends FailbackRegistry {
             serviceNames.add(serviceName);
 
             // in https://github.com/apache/dubbo/issues/14075
-            if (getUrl().getParameter(NACOE_REGISTER_COMPATIBLE, false)) {
+            if (getUrl().getParameter(NACOS_REGISTER_COMPATIBLE, false)) {
                 // servicename is "org.apache.dubbo.xxService:1.0.0"
                 String serviceName1 = getServiceName(url, true);
                 serviceNames.add(serviceName1);
diff --git 
a/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/codec/ExchangeCodecTest.java
 
b/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/codec/ExchangeCodecTest.java
index d06ea53c91..cbd8019ca0 100644
--- 
a/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/codec/ExchangeCodecTest.java
+++ 
b/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/codec/ExchangeCodecTest.java
@@ -164,7 +164,7 @@ class ExchangeCodecTest extends TelnetCodecTest {
 
     @Test
     void test_Decode_Error_Response_Object() throws IOException {
-        // 00000010-response/oneway/hearbeat=true |20-stats=ok|id=0|length=0
+        // 00000010-response/oneway/heartbeat=true |20-stats=ok|id=0|length=0
         byte[] header = new byte[] {MAGIC_HIGH, MAGIC_LOW, SERIALIZATION_BYTE, 
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
         Person person = new Person();
         byte[] request = getRequestBytes(person, header);
@@ -242,7 +242,7 @@ class ExchangeCodecTest extends TelnetCodecTest {
     void test_Decode_Return_Response_Person() throws IOException {
         DefaultFuture future = 
DefaultFuture.newFuture(Mockito.mock(Channel.class), new Request(0), 100000, 
null);
 
-        // 00000010-response/oneway/hearbeat=false/hessian 
|20-stats=ok|id=0|length=0
+        // 00000010-response/oneway/heartbeat=false/hessian 
|20-stats=ok|id=0|length=0
         byte[] header = new byte[] {MAGIC_HIGH, MAGIC_LOW, SERIALIZATION_BYTE, 
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
         Person person = new Person();
         byte[] request = getRequestBytes(person, header);
@@ -334,7 +334,7 @@ class ExchangeCodecTest extends TelnetCodecTest {
 
     @Test
     void test_Decode_Error_Request_Object() throws IOException {
-        // 00000010-response/oneway/hearbeat=true |20-stats=ok|id=0|length=0
+        // 00000010-response/oneway/heartbeat=true |20-stats=ok|id=0|length=0
         byte[] header = new byte[] {
             MAGIC_HIGH, MAGIC_LOW, (byte) (SERIALIZATION_BYTE | (byte) 0xe0), 
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
         };
@@ -353,7 +353,7 @@ class ExchangeCodecTest extends TelnetCodecTest {
     void test_Header_Response_NoSerializationFlag() throws IOException {
         DefaultFuture future = 
DefaultFuture.newFuture(Mockito.mock(Channel.class), new Request(0), 100000, 
null);
 
-        // 00000010-response/oneway/hearbeat=false/noset 
|20-stats=ok|id=0|length=0
+        // 00000010-response/oneway/heartbeat=false/noset 
|20-stats=ok|id=0|length=0
         byte[] header = new byte[] {MAGIC_HIGH, MAGIC_LOW, SERIALIZATION_BYTE, 
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
         Person person = new Person();
         byte[] request = getRequestBytes(person, header);
@@ -369,7 +369,7 @@ class ExchangeCodecTest extends TelnetCodecTest {
     void test_Header_Response_Heartbeat() throws IOException {
         DefaultFuture future = 
DefaultFuture.newFuture(Mockito.mock(Channel.class), new Request(0), 100000, 
null);
 
-        // 00000010-response/oneway/hearbeat=true |20-stats=ok|id=0|length=0
+        // 00000010-response/oneway/heartbeat=true |20-stats=ok|id=0|length=0
         byte[] header = new byte[] {MAGIC_HIGH, MAGIC_LOW, SERIALIZATION_BYTE, 
20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
         Person person = new Person();
         byte[] request = getRequestBytes(person, header);
diff --git 
a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/filter/GenericFilter.java
 
b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/filter/GenericFilter.java
index d50b7cf019..e4ef56e85c 100644
--- 
a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/filter/GenericFilter.java
+++ 
b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/filter/GenericFilter.java
@@ -256,22 +256,22 @@ public class GenericFilter implements Filter, 
Filter.Listener, ScopeModelAware {
             throws NoSuchMethodException, ClassNotFoundException {
         Method method;
         if (parameterTypes == null) {
-            List<Method> finded = new ArrayList<>();
+            List<Method> found = new ArrayList<>();
             for (Method m : clazz.getMethods()) {
                 if (m.getName().equals(methodName)) {
-                    finded.add(m);
+                    found.add(m);
                 }
             }
-            if (finded.isEmpty()) {
+            if (found.isEmpty()) {
                 throw new NoSuchMethodException("No such method " + methodName 
+ " in class " + clazz);
             }
-            if (finded.size() > 1) {
+            if (found.size() > 1) {
                 String msg = String.format(
                         "Not unique method for method name(%s) in class(%s), 
find %d methods.",
-                        methodName, clazz.getName(), finded.size());
+                        methodName, clazz.getName(), found.size());
                 throw new IllegalStateException(msg);
             }
-            method = finded.get(0);
+            method = found.get(0);
         } else {
             Class<?>[] types = new Class<?>[parameterTypes.length];
             for (int i = 0; i < parameterTypes.length; i++) {
diff --git 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/RequestPath.java
 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/RequestPath.java
index 22e79ca102..50f19bf8a4 100644
--- 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/RequestPath.java
+++ 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/RequestPath.java
@@ -30,7 +30,7 @@ public final class RequestPath {
         this.methodName = methodName;
     }
 
-    // Request path patten:
+    // Request path pattern:
     //     '{interfaceName}/{methodName}' or 
'{contextPath}/{interfaceName}/{methodName}'
     //      └─── path ────┘ └─ method ─┘      └────────── path ───────────┘ └─ 
method ─┘
     public static RequestPath parse(String fullPath) {
diff --git 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleCustomerProtocolWrapper.java
 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleCustomerProtocolWrapper.java
index c4d833ed6d..7b57a71d25 100644
--- 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleCustomerProtocolWrapper.java
+++ 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleCustomerProtocolWrapper.java
@@ -106,7 +106,8 @@ public class TripleCustomerProtocolWrapper {
                 int fieldNum = extractFieldNumFromTag(tag);
                 int wireType = extractWireTypeFromTag(tag);
                 if (wireType != 2) {
-                    throw new RuntimeException(String.format("unexpect 
wireType, expect %d realType %d", 2, wireType));
+                    throw new RuntimeException(
+                            String.format("unexpected wireType, expect %d 
realType %d", 2, wireType));
                 }
                 if (fieldNum == 1) {
                     int serializeTypeLength = readRawVarint32(byteBuffer);
@@ -237,7 +238,8 @@ public class TripleCustomerProtocolWrapper {
                 int fieldNum = extractFieldNumFromTag(tag);
                 int wireType = extractWireTypeFromTag(tag);
                 if (wireType != 2) {
-                    throw new RuntimeException(String.format("unexpect 
wireType, expect %d realType %d", 2, wireType));
+                    throw new RuntimeException(
+                            String.format("unexpected wireType, expect %d 
realType %d", 2, wireType));
                 }
                 if (fieldNum == 1) {
                     int serializeTypeLength = readRawVarint32(byteBuffer);
diff --git 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TriplePathResolver.java
 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TriplePathResolver.java
index da41ff0ee4..aed8395ddc 100644
--- 
a/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TriplePathResolver.java
+++ 
b/dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TriplePathResolver.java
@@ -41,7 +41,7 @@ public class TriplePathResolver implements PathResolver {
 
         register0(serviceKey, serviceInterface, invoker, url);
 
-        // Path patten: '{interfaceName}' or '{contextPath}/{interfaceName}'
+        // Path pattern: '{interfaceName}' or '{contextPath}/{interfaceName}'
         String path = url.getPath();
         int index = path.lastIndexOf('/');
         if (index == -1) {

Reply via email to