Skip to content

Refactor remote package to only have one remote cache impl.#10200

Closed
buchgr wants to merge 1 commit intobazelbuild:masterfrom
buchgr:two-remote-cache
Closed

Refactor remote package to only have one remote cache impl.#10200
buchgr wants to merge 1 commit intobazelbuild:masterfrom
buchgr:two-remote-cache

Conversation

@buchgr
Copy link
Copy Markdown
Contributor

@buchgr buchgr commented Nov 8, 2019

Historically the remote package shipped two implementations
for remote caching: GrpcRemoteCache and SimpleBlobStoreActionCache.
Today there is no good reason to keep this structure and the
duplication of code and tests that comes with it. This is the
final refactoring of a long series:

This change makes it so that there is one RemoteCache that
has a RemoteCacheClient. The RemoteCacheClient has one
implementation per caching protocol:

  • DiskCacheClient (formerly OnDiskBlobStore)
  • GrpcCacheClient (formerly GrpcRemoteCache)
  • HttpCacheClient (formerly HttpBlobStore)
  • CombinedDiskHttpCacheClient (formerly CombinedDiskHttpBlobStore)

A single RemoteCache type for all protocols will allow
composition of caching protocols. In particular, grpc and disk
caching. Additionally, this change will allow us to fix a longstanding
bug where for the HTTP

@buchgr buchgr requested a review from ola-rozenfeld as a code owner November 8, 2019 16:15
@buchgr
Copy link
Copy Markdown
Contributor Author

buchgr commented Nov 8, 2019

FYI @sergiocampama @borkaehw

@buchgr buchgr force-pushed the two-remote-cache branch 3 times, most recently from b4ee4ce to a70f3db Compare November 11, 2019 10:32
@buchgr buchgr changed the title One RemoteCache Refactor remote package to only have one remote cache impl. Nov 11, 2019
Historically the remote package shipped two implementations
for remote caching: GrpcRemoteCache and SimpleBlobStoreActionCache.
Today there is no good reason to keep this structure and the
duplication of code and tests that comes with it. This is the
final refactoring of a long series:

 * 5fc91a7
 * 12ebb84
 * 8ac6bdc
 * 9fb83b4
 * 36611c3
 * a6b5b05
 * d40933d
 * 797f292

This change makes it so that there is one RemoteCache that
has a RemoteCacheClient. The RemoteCacheClient has one
implementation per caching protocol:

 * DiskCacheClient (formerly OnDiskBlobStore)
 * GrpcCacheClient (formerly GrpcRemoteCache)
 * HttpCacheClient (formerly HttpBlobStore)
 * CombinedDiskHttpCacheClient (formerly CombinedDiskHttpBlobStore)

A single RemoteCache type for all protocols will allow
composition of caching protocols. In particular, grpc and disk
caching. Additionally, this change will allow us to fix a longstanding
bug where for the HTTP protocol uploads of outputs for an action are
not done in parallel.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants