Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Gateway API to query transaction history #1310

Merged
merged 2 commits into from
Apr 11, 2022
Merged

Conversation

lxfind
Copy link
Contributor

@lxfind lxfind commented Apr 10, 2022

This PR adds two APIs:

  1. Get most recent N transactions from the gateway.
  2. Get transactions with sequence number in range (start, end).

These two APIs should be sufficient to support explorer for now.

Need someone to help finish the REST API impl.

@lxfind lxfind force-pushed the add-gateway-tx-history-query branch from 9775377 to c90d9c9 Compare April 10, 2022 16:35
@patrickkuo
Copy link
Contributor

patrickkuo commented Apr 10, 2022

Need someone to help finish the REST API impl.

We are deprecating the REST API, I will add them to the new JSON-RPC implementation.

@codecov
Copy link

codecov bot commented Apr 10, 2022

Codecov Report

Merging #1310 (9775377) into main (28c10a6) will decrease coverage by 0.02%.
The diff coverage is 73.80%.

❗ Current head 9775377 differs from pull request most recent head 2f5912e. Consider uploading reports for the commit 2f5912e to get more accurate results

@@            Coverage Diff             @@
##             main    #1310      +/-   ##
==========================================
- Coverage   81.84%   81.82%   -0.03%     
==========================================
  Files          99       99              
  Lines       20685    20765      +80     
==========================================
+ Hits        16930    16990      +60     
- Misses       3755     3775      +20     
Impacted Files Coverage Δ
sui/src/rest_gateway.rs 0.00% <0.00%> (ø)
sui_types/src/error.rs 14.28% <ø> (ø)
sui_core/src/gateway_state.rs 90.69% <83.72%> (-0.64%) ⬇️
sui_core/src/authority/authority_store.rs 90.92% <100.00%> (+0.16%) ⬆️
sui_core/src/unit_tests/gateway_tests.rs 92.86% <100.00%> (+0.04%) ⬆️
sui_core/src/unit_tests/move_integration_tests.rs 93.33% <0.00%> (ø)
sui_types/src/object.rs 81.74% <0.00%> (+0.25%) ⬆️
...i_programmability/verifier/src/id_leak_verifier.rs 91.03% <0.00%> (+0.44%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 28c10a6...2f5912e. Read the comment docs.

Copy link
Collaborator

@sblackshear sblackshear left a comment

Choose a reason for hiding this comment

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

Nice!

@oxade
Copy link
Contributor

oxade commented Apr 11, 2022

@stella3d we had discussed you adding support for this last week pending full support using follower logic
Please check that this PR does not overlap/conflict with your plans

@lxfind lxfind force-pushed the add-gateway-tx-history-query branch from 07d470b to 2f5912e Compare April 11, 2022 00:23
@lxfind lxfind enabled auto-merge (squash) April 11, 2022 00:30
@lxfind lxfind merged commit e615cda into main Apr 11, 2022
@lxfind lxfind deleted the add-gateway-tx-history-query branch April 11, 2022 00:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants