nativelink icon indicating copy to clipboard operation
nativelink copied to clipboard

Show a warning message if versions are mismatched in `Worker` <-> `Scheduler` communication

Open boldpulse opened this issue 1 year ago • 3 comments

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 amend see some docs

This change is Reviewable

boldpulse avatar Aug 16 '24 13:08 boldpulse

I hope you to review this. cc: @MarcusSorealheis, @allada, @aaronmondal

boldpulse avatar Aug 16 '24 13:08 boldpulse

FYI, just shortened this commit message to follow the contribution rules.

boldpulse avatar Aug 16 '24 13:08 boldpulse

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

palfrey avatar Nov 11 '25 16:11 palfrey