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

Raw trace of transaction on-demand #3013

Merged
merged 3 commits into from
Feb 25, 2020
Merged

Conversation

vbaranov
Copy link
Member

@vbaranov vbaranov commented Feb 18, 2020

Motivation

We will start to ignore first traces from #3000 in case of Parity variant. Thus, we will not store them in the DB in order to shrink occupated space. In order to not break raw trace feature in Blockscout it is implemented to get transaction's raw traces on demand. Actually, the first trace will be fetched on-demand from the archive node once anyone opens the /raw_trace page of transactions for the first time and this first trace saved to the DB. And raw trace will be collected from all internal transactions from the DB and displayed on the page. If the first trace already exist in the DB, application will no request the node again in order to fetch it.

Checklist for your Pull Request (PR)

@vbaranov vbaranov self-assigned this Feb 18, 2020
@vbaranov vbaranov added the ready for review This PR is ready for reviews. label Feb 18, 2020
@coveralls
Copy link

coveralls commented Feb 18, 2020

Pull Request Test Coverage Report for Build 42a158d6-28a5-4ddf-8e27-6bf0804547b6

  • 43 of 78 (55.13%) changed or added relevant lines in 6 files are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage decreased (-0.1%) to 75.075%

Changes Missing Coverage Covered Lines Changed/Added Lines %
apps/ethereum_jsonrpc/lib/ethereum_jsonrpc.ex 0 1 0.0%
apps/indexer/lib/indexer/fetcher/internal_transaction.ex 0 3 0.0%
apps/ethereum_jsonrpc/lib/ethereum_jsonrpc/parity.ex 16 20 80.0%
apps/explorer/lib/explorer/chain/import/runner/internal_transactions.ex 0 4 0.0%
apps/explorer/lib/explorer/chain.ex 27 38 71.05%
apps/block_scout_web/lib/block_scout_web/controllers/transaction_raw_trace_controller.ex 0 12 0.0%
Files with Coverage Reduction New Missed Lines %
apps/block_scout_web/lib/block_scout_web/controllers/chain/market_history_chart_controller.ex 1 78.57%
Totals Coverage Status
Change from base Build 64e3f4f0-9d21-4c8c-86e1-46c9589b45a5: -0.1%
Covered Lines: 5482
Relevant Lines: 7302

💛 - Coveralls

@vbaranov vbaranov force-pushed the vb-first-trace-on-demand branch 4 times, most recently from 9a548f1 to f1ef2e9 Compare February 19, 2020 16:18
@vbaranov vbaranov force-pushed the vb-first-trace-on-demand branch 5 times, most recently from c4c7a78 to 5758253 Compare February 20, 2020 13:12
@vbaranov vbaranov merged commit bb17f4f into master Feb 25, 2020
@vbaranov vbaranov deleted the vb-first-trace-on-demand branch February 25, 2020 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready for review This PR is ready for reviews.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants