Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Rpc: Add until parameter for getConfirmedSignaturesForAddress2 #11644

Merged
merged 7 commits into from
Aug 15, 2020

Conversation

CriesofCarrots
Copy link
Contributor

Problem

getConfirmedSignaturesForAccount2 allows searching before a certain signature but doesn't support searching recent history up until a signature that you already have. Using until would be useful when refreshing the explorer UI to check if any new signatures have been confirmed since the last fetch.

Summary of Changes

  • Add back-end handling in bigtable and blockstore needed to support until requests
  • Also refactor bigtable apis to enable getting a range of row data, and to use get_row_data range in get_confirmed_signatures_for_address
  • Add until parameter to getConfirmedSignaturesForAccount2 rpc
  • Plumb until through client/cli apis

Fixes #11446

@CriesofCarrots CriesofCarrots requested a review from mvines August 14, 2020 22:36
@codecov
Copy link

codecov bot commented Aug 14, 2020

Codecov Report

Merging #11644 into master will decrease coverage by 0.0%.
The diff coverage is 65.0%.

@@            Coverage Diff            @@
##           master   #11644     +/-   ##
=========================================
- Coverage    82.1%    82.1%   -0.1%     
=========================================
  Files         330      330             
  Lines       76106    76198     +92     
=========================================
+ Hits        62506    62561     +55     
- Misses      13600    13637     +37     

mvines
mvines previously approved these changes Aug 15, 2020
Copy link
Contributor

@mvines mvines left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BigTable is pretty fun 'eh. It seems to just kinda work

client/src/rpc_client.rs Outdated Show resolved Hide resolved
@mergify mergify bot dismissed mvines’s stale review August 15, 2020 06:59

Pull request has been modified.

@CriesofCarrots
Copy link
Contributor Author

BigTable is pretty fun 'eh. It seems to just kinda work

Indeed! It's a joy

@CriesofCarrots CriesofCarrots merged commit 6c5b8f3 into solana-labs:master Aug 15, 2020
mergify bot pushed a commit that referenced this pull request Aug 15, 2020
* Refactor bigtable apis to accept start and end keys

* Make helper fn to deserialize cell data

* Refactor get_confirmed_signatures_for_address to use get_row_data range

* Add until param to get_confirmed_signatures_for_address

* Add until param to blockstore api

* Plumb until through client/cli

* Simplify client params

(cherry picked from commit 6c5b8f3)
mergify bot pushed a commit that referenced this pull request Aug 15, 2020
* Refactor bigtable apis to accept start and end keys

* Make helper fn to deserialize cell data

* Refactor get_confirmed_signatures_for_address to use get_row_data range

* Add until param to get_confirmed_signatures_for_address

* Add until param to blockstore api

* Plumb until through client/cli

* Simplify client params

(cherry picked from commit 6c5b8f3)
mergify bot added a commit that referenced this pull request Aug 15, 2020
… (#11648)

* Refactor bigtable apis to accept start and end keys

* Make helper fn to deserialize cell data

* Refactor get_confirmed_signatures_for_address to use get_row_data range

* Add until param to get_confirmed_signatures_for_address

* Add until param to blockstore api

* Plumb until through client/cli

* Simplify client params

(cherry picked from commit 6c5b8f3)

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
mergify bot added a commit that referenced this pull request Aug 15, 2020
… (#11647)

* Refactor bigtable apis to accept start and end keys

* Make helper fn to deserialize cell data

* Refactor get_confirmed_signatures_for_address to use get_row_data range

* Add until param to get_confirmed_signatures_for_address

* Add until param to blockstore api

* Plumb until through client/cli

* Simplify client params

(cherry picked from commit 6c5b8f3)

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
@CriesofCarrots CriesofCarrots deleted the bigtable-sigs-until branch September 1, 2020 19:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

RPC: Query account history newer than specific signature
2 participants