Skip to content

chore(deps): update commons-cli version #557

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

Merged
merged 1 commit into from
May 27, 2025
Merged

Conversation

mjsax
Copy link
Member

@mjsax mjsax commented May 26, 2025

Splitting out one version bump from #541 to apply required code changes.

@Copilot Copilot AI review requested due to automatic review settings May 26, 2025 22:43
@mjsax mjsax requested review from a team as code owners May 26, 2025 22:43
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates the commons-cli dependency from version 1.4 to 1.9.0 and adjusts calls to getOptionValue() across multiple utility classes to include an explicit String cast for the default value.

  • Updated dependency version in pom.xml
  • Applied explicit (String) null cast in getOptionValue() calls across multiple service classes

Reviewed Changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/main/java/io/confluent/examples/streams/microservices/util/ProducePayments.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/util/ProduceOrders.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/util/ProduceCustomers.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/util/ConsumePayments.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/util/ConsumeOrders.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/util/ConsumeCustomers.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/ValidationsAggregatorService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/PostOrdersAndPayments.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/OrdersService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/OrderDetailsService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/InventoryService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/FraudService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/EmailService.java Added explicit cast in getOptionValue() for compatibility
src/main/java/io/confluent/examples/streams/microservices/AddInventory.java Added explicit cast in getOptionValue() for compatibility
pom.xml Upgraded commons-cli dependency to version 1.9.0
Comments suppressed due to low confidence (15)

src/main/java/io/confluent/examples/streams/microservices/util/ProducePayments.java:40

  • [nitpick] Verify that the explicit cast to (String) null is necessary with the updated commons-cli API and ensure it aligns with expected behavior.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/util/ProduceOrders.java:42

  • [nitpick] Verify that the explicit (String) cast used here correctly disambiguates the overloaded getOptionValue method as intended by the new dependency version.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/util/ProduceCustomers.java:48

  • [nitpick] Ensure that the explicit cast to (String) null is required for correct overload resolution with the updated commons-cli version.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/util/ConsumePayments.java:41

  • [nitpick] Confirm that the explicit (String) cast properly resolves the correct overloaded method signature in the context of the updated API.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/util/ConsumeOrders.java:42

  • [nitpick] Check that the explicit cast to (String) null is necessary to avoid ambiguity with overloaded method calls in the updated library.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/util/ConsumeCustomers.java:42

  • [nitpick] Ensure that the explicit cast here is consistent with other similar changes and is required for proper overload resolution.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/ValidationsAggregatorService.java:183

  • [nitpick] Verify that the explicit (String) cast in the getOptionValue call complies with the updated commons-cli API expectations.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/PostOrdersAndPayments.java:97

  • [nitpick] Ensure that the explicit cast is necessary in this context and test for any unexpected behaviors with the new dependency version.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/OrdersService.java:454

  • [nitpick] Check that the explicit cast to (String) null maintains the consistency of overload resolution in the updated API.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/OrderDetailsService.java:220

  • [nitpick] Ensure that the added explicit cast fits the intended overload of getOptionValue as per the updated dependency.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/InventoryService.java:203

  • [nitpick] Confirm that the explicit (String) cast is necessary and correctly distinguishes the method overload for getOptionValue.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/FraudService.java:169

  • [nitpick] Review the explicit cast to ensure it is intended for overload resolution with the newer commons-cli API.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/EmailService.java:155

  • [nitpick] Make sure that the explicit (String) cast is necessary in ensuring the correct overload of getOptionValue is used.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

src/main/java/io/confluent/examples/streams/microservices/AddInventory.java:80

  • [nitpick] Verify that the explicit cast to (String) null here is necessary for proper overload resolution with the updated commons-cli version.
final Properties defaultConfig = Optional.ofNullable(cl.getOptionValue("config-file", (String) null))

pom.xml:119

  • Ensure that the upgrade to commons-cli 1.9.0 is compatible with all usages in the codebase and does not introduce any breaking changes in command line parsing behavior.
<version>1.9.0</version>

@mjsax mjsax merged commit 725af2a into master May 27, 2025
2 checks passed
@mjsax mjsax deleted the minor-update-common-cli branch May 27, 2025 16:00
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.

2 participants