chia7712 commented on code in PR #20508:
URL: https://github.com/apache/kafka/pull/20508#discussion_r2337979712
##########
raft/src/main/java/org/apache/kafka/raft/EpochState.java:
##########
@@ -59,4 +59,10 @@ default Optional<LogOffsetMetadata> highWatermark() {
* User-friendly description of the state
*/
String name();
+
+ @Override
+ default void close() {
+ // Since all subclasses implement the Closeable interface while none
throw any IOException,
Review Comment:
It feels odd to add a default implementation just for the sake of
documentation. How about using the following style instead?
```java
/**
* Since all subclasses implement the Closeable interface while none
throw any IOException,
* this default implementation is provided to eliminate the need for
exception handling in the close operation.
*/
@Override
void close();
```
--
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]