bazel-buildfarm
bazel-buildfarm copied to clipboard
Implement Blake3 hash function support
Adds the option to configure Blake3 hash function which was recently added to Bazel.
Outside of just adding the reference implementation of Blake3 + java, we need to make some small affordances which were changed in the byestream calls. Importantly they add the name of the hash function now, which is a nice improvement and could make it easier to run multiple hash implementations on the same instance(s).
Summary
- Add Blake3Hasher to DigestUtil via Blake3Provider
- Pull reference implementation of Blake JNI bridge that works with how we hash stuff in buildfarm
- Pull Bazel's JNI loader minues some deps
- From a build perspective, we hinge some of the build settings to handle macOS and linux per Bazel's shims which work very well
@werkt putting this up as a draft; this one gained some recent excitement in the community and I'm excited to try it out on our fork!
This week I've got some more cycles to get CI fixed. Outside of the complaints from static analysis this has been working very well in our fork
Fixes: https://github.com/bazelbuild/bazel-buildfarm/issues/1423
BLAKE3 implemented via https://github.com/bazelbuild/bazel-buildfarm/pull/1697