Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KAFKA-16878: Remove powermock and easymock from code base #16236

Merged
merged 1 commit into from
Jun 8, 2024

Conversation

FrankYang0529
Copy link
Member

This is the follow-up of KAFKA-16223. It should include following changes:

  • remove all related code from code base
  • remove testsToExclude from build.gradle

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

Copy link
Member

@chia7712 chia7712 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chia7712
Copy link
Member

chia7712 commented Jun 7, 2024

@FrankYang0529 could you please rebase code to trigger QA?

@mimaison
Copy link
Member

mimaison commented Jun 7, 2024

Wow, we're finally doing it!
According to KAFKA-7438, it looks like it almost took us 6 years to do it.

Copy link
Member

@mimaison mimaison left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!
We still have a handful of comments mentioning EasyMock/PowerMock, it would be good to remove them as well.

@@ -522,13 +522,6 @@ subprojects {
// The suites are for running sets of tests in IDEs.
// Gradle will run each test class, so we exclude the suites to avoid redundantly running the tests twice.
def testsToExclude = ['**/*Suite.class']
// Exclude PowerMock tests when running with Java 16 or newer until a version of PowerMock that supports the relevant versions is released
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's another comment about PowerMock at line 822, can we remove it as well?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are also comments about EasyMock in 4 places:

  • 2 in DescribeTopicPartitionsRequestHandlerTest
  • 2 in KafkaApisTest
    Let's clean those up as well.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @mimaison, thanks for the review. I remove all remaining comments.

@chia7712
Copy link
Member

chia7712 commented Jun 7, 2024

Wow, we're finally doing it!
According to KAFKA-7438, it looks like it almost took us 6 years to do it.

That is a lengthy journey 😄

@chia7712
Copy link
Member

chia7712 commented Jun 8, 2024

@FrankYang0529 thanks for this patch. I will merge it after getting approve from @mimaison

@chia7712
Copy link
Member

chia7712 commented Jun 8, 2024

oh, the QA is not completed. I re-trigger it ...

@FrankYang0529
Copy link
Member Author

oh, the QA is not completed. I re-trigger it ...

I rebase trunk branch to include #16248.

@ocadaruma
Copy link
Contributor

@FrankYang0529 FYI it turned out there's another blocking test so we may need to wait #16249 gets merged not only 16248

@FrankYang0529
Copy link
Member Author

@FrankYang0529 FYI it turned out there's another blocking test so we may need to wait #16249 gets merged not only 16248

Thank you for the reminder. We will wait for it 👍

@showuon
Copy link
Contributor

showuon commented Jun 8, 2024

#16249 is merged. FYI.

@@ -826,7 +819,6 @@ subprojects {
toolVersion = versions.jacoco
}

// NOTE: Jacoco Gradle plugin does not support "offline instrumentation" this means that classes mocked by PowerMock
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can't just remove the first line, the following line does not mean anything now.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for that. I remove related comments.

@FrankYang0529
Copy link
Member Author

#16249 is merged. FYI.

Rebased it. Thanks.

@chia7712
Copy link
Member

chia7712 commented Jun 8, 2024

failed tests pass on my local.

@chia7712 chia7712 merged commit 3d5d150 into apache:trunk Jun 8, 2024
1 check failed
@ijuma
Copy link
Member

ijuma commented Jun 8, 2024

Wow, we're finally doing it! According to KAFKA-7438, it looks like it almost took us 6 years to do it.

Well done team, this was a Herculean effort!

@FrankYang0529 FrankYang0529 deleted the KAFKA-16878 branch June 9, 2024 00:10
gongxuanzhang pushed a commit to gongxuanzhang/kafka that referenced this pull request Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants