KAFKA-14647: Moving TopicFilter to server-common/utils#13158
KAFKA-14647: Moving TopicFilter to server-common/utils#13158mimaison merged 9 commits intoapache:trunkfrom
Conversation
|
@fvaleri , plz review this PR. |
There was a problem hiding this comment.
Hi @vamossagar12, thanks for working on this!
I left some comments, but there are build errors.
In this PR, it is probably a good idea to also move the TopicPartitionFilter and related code contained in GetOffsetShell. They are very similar and of general use.
@fvaleri , sorry about the build failures. I hadn't run the checkstyle for core on my local before pushing. I will work on the TopicPartitionFilter class, rest of the comments have been addressed/answered. Thanks for reviewing. |
3cf1723 to
e78c502
Compare
|
Thanks @fvaleri , I made the changes. |
fvaleri
left a comment
There was a problem hiding this comment.
Hi @vamossagar12, I left few comments, but looks mostly good.
I guess we also need to add some unit tests for PartitionFilter and TopicPartitionFilter, like we have for TopicFilter. They are in GetOffsetShellParsingTest, which should rather test the tool interface not filters.
43e20ac to
856a703
Compare
|
Thanks @fvaleri , I addressed the review comments. Regarding unit tests for PartitionFilter and TopicPartitionFilter, I checked the tests in |
|
Hi @vamossagar12 this looks good, but I still think we should move |
Thanks @fvaleri . I tried doing this today. A problem that I see is that |
|
What is the justification for this? For something to be in server-common, it needs to be used by multiple modules. |
|
@ijuma these classes are currently used in both tools and core modules. Not all tools will be migrated in the same release and we also have the deprecated MirrorMaker 1, which we do not plan to move. |
|
TopicFilter and TopicPartitionFilter are very customized and simple interfaces, it's unnecessary to rewrite them currently IMO, at least currently, they are only used in a few tools, especially |
|
In that case, would it make sense to close this PR @fvaleri ? |
Why? We can discuss where to place these interfaces, but I would keep the work that has been done. It's just another step towards KAFKA-14524. |
|
I see. TBH I haven't followed that migration effort off-late. I think there are build failures as well which I haven't addressed yet. |
I agree. This work is already in use in another PR. |
I see. In that case, I need to fix the build issue and ask folks for reviews then. Will try to do so as soon as I can. Thanks for notifying. |
47039ce to
f10b612
Compare
|
@ruslankrivoshein , I have fixed the checkstyle issues. Also, I believe that the other comment here has been addressed by you in the PR #13562. |
|
@vamossagar12 LGTM. Thanks. |
|
Thanks @fvaleri . Hmm I see 101 test failures. 92 existing and 9 new. Atleast the new ones look unrelated.. |
|
I took a look at the changes and they look fine. If I understand correctly we're moving these classes to server-common while we have to keep MirrorMaker. Then in Kafka 4.0 (and assuming KAFKA-14525 is complete) we will be able to move all these classes to tools. Is that right? |
|
Yes, once the MirrorMaker1 dependency will be gone in 4.0.0, we can move them to tools. I added a note in KAFKA-14705. |
Thanks @mimaison , yes that's the idea. |
|
@mimaison can this be merged if all changes look fine? |
* ak/trunk: (110 commits) MINOR: Update docs to include ZK deprecation notice and information (apache#14031) KAFKA-15091: Fix misleading Javadoc for SourceTask::commit (apache#13948) KAFKA-14669: Use the generated docs for MirrorMaker configs in the doc (apache#13658) KAFKA-14953: Add tiered storage related metrics (apache#13944) KAFKA-15121: Implement the alterOffsets method in the FileStreamSourceConnector and the FileStreamSinkConnector (apache#13945) Revert "MINOR: Update .asf.yaml file with refreshed github_whitelist, and collaborators" (apache#14037) MINOR: Update .asf.yaml file with refreshed github_whitelist, and collaborators KAFKA-14737: Move kafka.utils.json to server-common (apache#13585) KAFKA-14647: Move TopicFilter to server-common/utils (apache#13158) MINOR: remove unused variable in examples (apache#14021) ...
Reviewers: Mickael Maison <mickael.maison@gmail.com>, Federico Valeri <fedevaleri@gmail.com>
Reviewers: Mickael Maison <mickael.maison@gmail.com>, Federico Valeri <fedevaleri@gmail.com>
Reviewers: Mickael Maison <mickael.maison@gmail.com>, Federico Valeri <fedevaleri@gmail.com>
Moving TopicFilter to server-common/utils