soarez commented on code in PR #14290: URL: https://github.com/apache/kafka/pull/14290#discussion_r1378018066
########## server-common/src/main/java/org/apache/kafka/common/DirectoryId.java: ########## @@ -16,55 +16,166 @@ */ package org.apache.kafka.common; +import java.util.ArrayList; +import java.util.Arrays; import java.util.Collections; +import java.util.HashMap; import java.util.HashSet; +import java.util.List; +import java.util.Map; import java.util.Set; -public class DirectoryId { +public class DirectoryId extends Uuid { Review Comment: > we'd have to copy between types every time we serialize to a record or to an RPC. This also removes a lot of the advantages you are touting No, I don't think so, because direct access to the metadata record fields is isolated to `PartitionRegistration` and `PartitionChangeBuilder`, so we'd get the benefits everywhere above that abstraction layer. But I do agree with your point on inconsistency, so I've pushed [04a79cd](https://github.com/apache/kafka/pull/14290/commits/04a79cd4cec478e4cfece50c50fe4abd7f8c4e50). -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org