Show a warning message if versions are mismatched in `Worker` <-> `Scheduler` communication
Description
When Worker is connecting to the Scheduler, both sides should express which version of NativeLink they are using in the metadata and if they are not matched, they should throw a warning. WorkerAPI protobuf is updated to include version information for both Worker and Scheduler in the initial request and the response to that initial request. CARGO_PKG_VERSION environment varaible is used to get the current NativeLink version - which is how clap library gets version by itself. Notice that CARGO_PKG_VERSION environment variable is only set when the NativeLink is built with cargo not bazel.
Tests are updated to include version information for both Worker and Scheduler.
Fixes #1253
Type of change
Please delete options that aren't relevant.
- [x] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [x] This change requires a documentation update
How Has This Been Tested?
Please also list any relevant details for your test configuration
Checklist
- [x] Updated documentation if needed
- [x] Tests added/amended
- [x]
bazel test //...passes locally - [x] PR is contained in a single commit, using
git amendsee some docs
I hope you to review this. cc: @MarcusSorealheis, @allada, @aaronmondal
FYI, just shortened this commit message to follow the contribution rules.
@boldpulse This is of interest to us again as we've just had some folks running into problems without this sort of thing. Are you able to bring this up to date?