Skip to content

Commit

Permalink
Merge #4191
Browse files Browse the repository at this point in the history
4191: [Access] Add latest block Height and ID to api responses r=peterargue a=Guitarheroua

#2906

### Context
This pull request extends the necessary responses for the Access Node with additional fields containing information about the finalized block ID and height. To achieve this, the `synchronization.FinalizedHeaderCache` was propagated to the Access Node handler, and finalized block ID and height were added to query responses

As part of this PR:
* The protobuf structures were extended([PR 1325](onflow/flow#1325))
* The tests in [access_test.go](https://github.com/onflow/flow-go/blob/master/engine/access/access_test.go) were updated

### Note:
* These changes include only GRPC modifications and not REST. REST changes will be made in a separate pull request after getting a reply on [the issue comment](#2906 (comment)).


Co-authored-by: Andriy Slisarchuk <[email protected]>
Co-authored-by: Andrii Slisarchuk <[email protected]>
Co-authored-by: Andrii Slisarchuk <[email protected]>
  • Loading branch information
3 people authored Apr 27, 2023
2 parents e3c720f + 1e6e1f8 commit 2a88409
Show file tree
Hide file tree
Showing 18 changed files with 420 additions and 131 deletions.
2 changes: 1 addition & 1 deletion access/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func TransactionResultToMessage(result *TransactionResult) *access.TransactionRe
BlockId: result.BlockID[:],
TransactionId: result.TransactionID[:],
CollectionId: result.CollectionID[:],
BlockHeight: uint64(result.BlockHeight),
BlockHeight: result.BlockHeight,
}
}

Expand Down
Loading

0 comments on commit 2a88409

Please sign in to comment.