Skip to content

Commit

Permalink
Followup: decouple SkipCache and DoNotCache in rexec package.
Browse files Browse the repository at this point in the history
  • Loading branch information
ramymedhat committed May 13, 2024
1 parent 369e1ca commit 115eea5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions go/pkg/rexec/rexec.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ func (ec *Context) GetCachedResult() {
ec.Result = command.NewLocalErrorResult(err)
return
}
if ec.opt.AcceptCached && !ec.opt.DoNotCache {
if ec.opt.AcceptCached {
ec.Metadata.EventTimes[command.EventCheckActionCache] = &command.TimeInterval{From: time.Now()}
resPb, err := ec.client.GrpcClient.CheckActionCache(ec.ctx, ec.Metadata.ActionDigest.ToProto())
ec.Metadata.EventTimes[command.EventCheckActionCache].To = time.Now()
Expand Down Expand Up @@ -393,7 +393,7 @@ func (ec *Context) ExecuteRemotely() {
var nOutStreamed, nErrStreamed int64
op, err := ec.client.GrpcClient.ExecuteAndWaitProgress(ec.ctx, &repb.ExecuteRequest{
InstanceName: ec.client.GrpcClient.InstanceName,
SkipCacheLookup: !ec.opt.AcceptCached || ec.opt.DoNotCache,
SkipCacheLookup: !ec.opt.AcceptCached,
ActionDigest: ec.Metadata.ActionDigest.ToProto(),
}, func(md *repb.ExecuteOperationMetadata) {
if !ec.opt.StreamOutErr {
Expand Down

0 comments on commit 115eea5

Please sign in to comment.