yin-bo-Final opened a new issue, #16314:
URL: https://github.com/apache/dubbo/issues/16314

   ### Pre-check
   
   - [x] I am sure that all the content I provide is in English.
   
   
   ### Search before asking
   
   - [x] I had searched in the 
[issues](https://github.com/apache/dubbo/issues?q=is%3Aissue) and found no 
similar feature requirement.
   
   
   ### Apache Dubbo Component
   
   Java SDK (apache/dubbo)
   
   ### Descriptions
   
   While working on PR #16309, I noticed that `AddressMatch` uses `cird` as the 
field and accessor method name:
   ```java
   private String cird;
   
   public String getCird() {
       return cird;
   }
   
   public void setCird(String cird) {
       this.cird = cird;
   }
   ```
   Based on the address matching logic, this field is used for `CIDR/IP` 
expression matching. It seems that `cird` may be a typo of `cidr`, since the 
correct networking term is `CIDR`, which stands for Classless Inter-Domain 
Routing.
   Since `getCird` / `setCird` may already be used by configuration binding, 
serialization, or external code, directly renaming them may introduce 
compatibility risks.
   I would like to propose adding backward-compatible `cidr` accessors while 
keeping the existing `cird` accessors.
   ```java
   private String cidr;
   
   public String getCidr() {
       return cidr;
   }
   
   public void setCidr(String cidr) {
       this.cidr = cidr;
   }
   
   /**
    * @deprecated use {@link #getCidr()} instead.
    */
   @Deprecated
   public String getCird() {
       return cidr;
   }
   
   /**
    * @deprecated use {@link #setCidr(String)} instead.
    */
   @Deprecated
   public void setCird(String cird) {
       this.cidr = cird;
   }
   ```
   This keeps backward compatibility while making the intended CIDR naming 
clearer for future usage.
   
   ### Related issues
   
   _No response_
   
   ### Are you willing to submit a pull request to fix on your own?
   
   - [x] Yes I am willing to submit a pull request on my own!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to