You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "kamalcph (via GitHub)" <gi...@apache.org> on 2024/10/12 19:28:54 UTC

[PR] KAFKA-15859: Complete delayed RemoteListOffsets requests when a replica moves away [kafka]

kamalcph opened a new pull request, #17487:
URL: https://github.com/apache/kafka/pull/17487

   - Removed the ListOffsetsMetadata wrapper class.
   - Complete the response when replica is not a leader or follower.
   - Addressed review comments from PR #16602.
   
   
   ### Committer Checklist (excluded from commit message)
   - [ ] Verify design and implementation 
   - [ ] Verify test coverage and CI build status
   - [ ] Verify documentation (including upgrade notes)
   


-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KAFKA-15859: Complete delayed RemoteListOffsets requests when replica moves away from broker [kafka]

Posted by "junrao (via GitHub)" <gi...@apache.org>.
junrao commented on code in PR #17487:
URL: https://github.com/apache/kafka/pull/17487#discussion_r1800153408


##########
core/src/main/scala/kafka/server/DelayedRemoteListOffsets.scala:
##########
@@ -31,7 +31,7 @@ import java.util.concurrent.TimeUnit
 import scala.collection.{Map, mutable}
 import scala.jdk.CollectionConverters._
 
-case class ListOffsetsPartitionStatus(var responseOpt: Option[ListOffsetsPartitionResponse] = None,
+case class ListOffsetsPartitionStatus(@volatile var responseOpt: Option[ListOffsetsPartitionResponse],

Review Comment:
   Probably this conflicts with the case class. Maybe use a non-case class?



-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KAFKA-15859: Complete delayed RemoteListOffsets requests when replica moves away from broker [kafka]

Posted by "kamalcph (via GitHub)" <gi...@apache.org>.
kamalcph commented on code in PR #17487:
URL: https://github.com/apache/kafka/pull/17487#discussion_r1797766974


##########
core/src/main/scala/kafka/server/DelayedRemoteListOffsets.scala:
##########
@@ -31,7 +31,7 @@ import java.util.concurrent.TimeUnit
 import scala.collection.{Map, mutable}
 import scala.jdk.CollectionConverters._
 
-case class ListOffsetsPartitionStatus(var responseOpt: Option[ListOffsetsPartitionResponse] = None,
+case class ListOffsetsPartitionStatus(@volatile var responseOpt: Option[ListOffsetsPartitionResponse],

Review Comment:
   Intellij shows "Class parameter shadows superclass var". How to fix this warning?
   
   <img width="1184" alt="Screenshot 2024-10-13 at 1 14 39 AM" src="https://github.com/user-attachments/assets/1c1618fd-8a2d-4732-b2dc-cdffb7b5e511">
   



-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KAFKA-15859: Complete delayed RemoteListOffsets requests when replica moves away from broker [kafka]

Posted by "junrao (via GitHub)" <gi...@apache.org>.
junrao merged PR #17487:
URL: https://github.com/apache/kafka/pull/17487


-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] KAFKA-15859: Complete delayed RemoteListOffsets requests when replica moves away from broker [kafka]

Posted by "kamalcph (via GitHub)" <gi...@apache.org>.
kamalcph commented on code in PR #17487:
URL: https://github.com/apache/kafka/pull/17487#discussion_r1801512417


##########
core/src/main/scala/kafka/server/DelayedRemoteListOffsets.scala:
##########
@@ -31,7 +31,7 @@ import java.util.concurrent.TimeUnit
 import scala.collection.{Map, mutable}
 import scala.jdk.CollectionConverters._
 
-case class ListOffsetsPartitionStatus(var responseOpt: Option[ListOffsetsPartitionResponse] = None,
+case class ListOffsetsPartitionStatus(@volatile var responseOpt: Option[ListOffsetsPartitionResponse],

Review Comment:
   Used a non-case class with object to overcome the warning.



-- 
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-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org