confluentinc / cli

CLI for Confluent Cloud and Confluent Platform
https://docs.confluent.io/confluent-cli/current/overview.html
Other
56 stars 10 forks source link

Passes CLI version info to flink APIs #2908

Closed vsantwana closed 1 week ago

vsantwana commented 4 weeks ago

Release Notes

Breaking Changes

New Features

Bug Fixes

Checklist

What

We want to be able to pass the CLI version information to the backend server for CMF to perform compatibility checks. All the commands except web-ui-forward use a SDK which sets up the UserAgent header. We simply pass the value of the version to the same header. In case of web-ui-forward, since the origin of the calls will be from user's browser, we did not want to override the user agent header as it might be used by browsers for checks of their own, we have introduced a new header for just that API.

Validation

go run -ldflags "-X main.version=1.2.0" cmd/confluent/main.go --version confluent version v1.2.0

References

Test & Review

confluent-cla-assistant[bot] commented 4 weeks ago

:tada: All Contributor License Agreements have been signed. Ready to merge.
Please push an empty commit if you would like to re-run the checks to verify CLA status for all contributors.