Skip to content

Commit 1be6815

Browse files
authored
api: Remove obsolete TODO in EquivalentAddressGroup#toString (#12627)
### Background EquivalentAddressGroup is intended to represent a small set of addresses for the same endpoint (e.g., IPv4/IPv6). A long-standing TODO in EquivalentAddressGroup#toString() suggested adding summarization for very large address lists. During review, maintainers noted that large address lists within a single EquivalentAddressGroup are no longer expected in current designs, and the historical behavior that could create a very large group (e.g., by aggregating many groups into one) has been removed. As a result, the TODO is now obsolete. ### Changes Remove the obsolete TODO comment in EquivalentAddressGroup#toString(). Add a brief explanatory comment capturing why summarization is no longer needed. ### Purpose Avoid leaving stale TODOs that imply work is still required. Align the codebase with the intended semantics and current behavior of EquivalentAddressGroup. ### Note This change is comment-only and does not alter any runtime behavior or output format. Fixes #12593 ---------
1 parent a5b7192 commit 1be6815

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

api/src/main/java/io/grpc/EquivalentAddressGroup.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,9 @@ public Attributes getAttributes() {
122122

123123
@Override
124124
public String toString() {
125-
// TODO(zpencer): Summarize return value if addr is very large
125+
// EquivalentAddressGroup is intended to contain a small number of addresses for the same
126+
// endpoint(e.g., IPv4/IPv6). Aggregating many groups into a single EquivalentAddressGroup
127+
// is no longer done, so this no longer needs summarization.
126128
return "[" + addrs + "/" + attrs + "]";
127129
}
128130

0 commit comments

Comments
 (0)