bazel-buildfarm icon indicating copy to clipboard operation
bazel-buildfarm copied to clipboard

[refactor] move functionality out of getActionResult

Open luxe opened this issue 3 years ago • 2 comments

This change is part of https://github.com/bazelbuild/bazel-buildfarm/pull/943, but separating it here to make smaller diffs.

I'd like ShardInstance to implement its own version of getActionResult, and that can be done more cleanly if it still leverages the existing EnsureOutputs code from the abstract class. This change splits a function into two functions.

luxe avatar Nov 18 '21 20:11 luxe

So your intent is to call the ensure check after doing special things within the ShardInstance.

I'd prefer if we decorated the actionCache object, and left this pristine, since it represents the correct logic for an asynchronous actionCache fetch in a single point that won't require maintenance for implementation specifics.

werkt avatar Dec 01 '21 02:12 werkt

So your intent is to call the ensure check after doing special things within the ShardInstance.

I'd prefer if we decorated the actionCache object, and left this pristine, since it represents the correct logic for an asynchronous actionCache fetch in a single point that won't require maintenance for implementation specifics.

We want to move the AC functionality into the backplane. The current AC is split between the backplane and the instance hierarchy. I see what you mean by having only 1 implementation. Here were the issues I was hoping to address: https://github.com/bazelbuild/bazel-buildfarm/pull/943.

luxe avatar Dec 01 '21 05:12 luxe