You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2022/06/21 08:28:33 UTC

[GitHub] [kafka] dengziming opened a new pull request, #12318: MINOR: Support --release in FeatureCommand

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

   *More detailed description of your change,
   if necessary. The PR title and PR message become
   the squashed commit message, so use a separate
   comment to ping reviewers.*
   
   Support --release in FeatureCommand, currently, we only have one feature which is metadata.version.
   
   *Summary of testing strategy (including rationale)
   for the feature or bug fix. Unit and/or integration
   tests are expected for any behaviour change and
   system tests should be considered for larger changes.*
   
   Added a test case in FeatureCommandTest
   
   ### 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


[GitHub] [kafka] dengziming closed pull request #12318: MINOR: Support --release in FeatureCommand

Posted by "dengziming (via GitHub)" <gi...@apache.org>.
dengziming closed pull request #12318: MINOR: Support --release in FeatureCommand
URL: https://github.com/apache/kafka/pull/12318


-- 
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


[GitHub] [kafka] dengziming commented on a diff in pull request #12318: MINOR: Support --release in FeatureCommand

Posted by GitBox <gi...@apache.org>.
dengziming commented on code in PR #12318:
URL: https://github.com/apache/kafka/pull/12318#discussion_r921176571


##########
core/src/test/scala/unit/kafka/admin/FeatureCommandTest.scala:
##########
@@ -107,4 +116,17 @@ class FeatureCommandTest extends BaseRequestTest {
       assertTrue(downgradeDescribeOutput.contains(expectedOutput))
     }
   }
+
+  @ParameterizedTest(name = TestInfoUtils.TestWithParameterizedQuorumName)
+  @ValueSource(strings = Array("kraft"))
+  def testUpdateFeatureByReleaseVersion(quorum: String): Unit = {
+    val initialDescribeOutput = TestUtils.grabConsoleOutput(FeatureCommand.mainNoExit(Array("--bootstrap-server", bootstrapServers(), "describe")))
+    assertTrue(initialDescribeOutput.contains("Feature: metadata.version\tSupportedMinVersion: 1\tSupportedMaxVersion: 7\tFinalizedVersionLevel: 1"))
+
+    FeatureCommand.mainNoExit(Array("--bootstrap-server", bootstrapServers(), "upgrade", "--release", IBP_3_3_IV3.version()))

Review Comment:
   I moved the original `FeatureCommandTest` to `FeatureCommandIntegrationTest` and add a new `FeatureCommandTest` to do these unit tests.



-- 
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


[GitHub] [kafka] dengziming commented on pull request #12318: MINOR: Support --release in FeatureCommand

Posted by GitBox <gi...@apache.org>.
dengziming commented on PR #12318:
URL: https://github.com/apache/kafka/pull/12318#issuecomment-1184476081

   @mumrah Thank you for your reminder, I added `--release` support for describing and added a unit test for it.


-- 
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


[GitHub] [kafka] mumrah commented on a diff in pull request #12318: MINOR: Support --release in FeatureCommand

Posted by GitBox <gi...@apache.org>.
mumrah commented on code in PR #12318:
URL: https://github.com/apache/kafka/pull/12318#discussion_r920433990


##########
core/src/test/scala/unit/kafka/admin/FeatureCommandTest.scala:
##########
@@ -107,4 +116,17 @@ class FeatureCommandTest extends BaseRequestTest {
       assertTrue(downgradeDescribeOutput.contains(expectedOutput))
     }
   }
+
+  @ParameterizedTest(name = TestInfoUtils.TestWithParameterizedQuorumName)
+  @ValueSource(strings = Array("kraft"))
+  def testUpdateFeatureByReleaseVersion(quorum: String): Unit = {
+    val initialDescribeOutput = TestUtils.grabConsoleOutput(FeatureCommand.mainNoExit(Array("--bootstrap-server", bootstrapServers(), "describe")))
+    assertTrue(initialDescribeOutput.contains("Feature: metadata.version\tSupportedMinVersion: 1\tSupportedMaxVersion: 7\tFinalizedVersionLevel: 1"))
+
+    FeatureCommand.mainNoExit(Array("--bootstrap-server", bootstrapServers(), "upgrade", "--release", IBP_3_3_IV3.version()))

Review Comment:
   Can we add a negative test case where `--release` and `--feature` are given?



-- 
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


[GitHub] [kafka] dengziming commented on pull request #12318: MINOR: Support --release in FeatureCommand

Posted by GitBox <gi...@apache.org>.
dengziming commented on PR #12318:
URL: https://github.com/apache/kafka/pull/12318#issuecomment-1247658470

   @mumrah Do we still need --release after we add --metadata? I will close this if it's unnecessary or rebase this PR onto trunk if it's still useful.


-- 
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


[GitHub] [kafka] dengziming commented on pull request #12318: MINOR: Support --release in FeatureCommand

Posted by GitBox <gi...@apache.org>.
dengziming commented on PR #12318:
URL: https://github.com/apache/kafka/pull/12318#issuecomment-1173291675

   cc @mumrah 


-- 
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


[GitHub] [kafka] dengziming commented on pull request #12318: MINOR: Support --release in FeatureCommand

Posted by "dengziming (via GitHub)" <gi...@apache.org>.
dengziming commented on PR #12318:
URL: https://github.com/apache/kafka/pull/12318#issuecomment-1539714488

   Closing this since we are using --metadata instead of --release.


-- 
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