Skip to content

Commit

Permalink
remove requested block after cache hit (lavanet#1159)
Browse files Browse the repository at this point in the history
  • Loading branch information
ranlavanet authored Jan 23, 2024
1 parent da0129f commit 141dd17
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions protocol/rpcconsumer/rpcconsumer_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -444,8 +444,13 @@ func (rpccs *RPCConsumerServer) sendRelayToProvider(
if cacheError == nil && reply != nil {
// Info was fetched from cache, so we don't need to change the state
// so we can return here, no need to update anything and calculate as this info was fetched from the cache
relayResult = &common.RelayResult{Reply: reply, Request: &pairingtypes.RelayRequest{RelayData: relayRequestData}}
lavaprotocol.SetRequestedBlockNotApplicable(relayResult.Request.RelayData)
relayResult = &common.RelayResult{
Reply: reply,
Request: &pairingtypes.RelayRequest{
RelayData: relayRequestData,
},
Finalized: false, // set false to skip data reliability
}
return relayResult, nil
}
// cache failed, move on to regular relay
Expand Down

0 comments on commit 141dd17

Please sign in to comment.