Merge pull request #3042 from poanetwork/vb-speedup-pendinng-list

Speedup pending txs list query
pull/3043/head
Victor Baranov 5 years ago committed by GitHub
commit ef770a9b57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      CHANGELOG.md
  2. 2
      apps/explorer/lib/explorer/chain.ex

@ -3,6 +3,7 @@
### Features
### Fixes
- [#3042](https://github.com/poanetwork/blockscout/pull/3042) - Speedup pending txs list query
- [#2944](https://github.com/poanetwork/blockscout/pull/2944) - Split js logic into multiple files
### Chore

@ -2367,7 +2367,7 @@ defmodule Explorer.Chain do
|> page_pending_transaction(paging_options)
|> limit(^paging_options.page_size)
|> pending_transactions_query()
|> order_by([transaction], desc: transaction.inserted_at, desc: transaction.hash)
|> order_by([transaction], desc: transaction.hash, desc: transaction.inserted_at)
|> join_associations(necessity_by_association)
|> preload([{:token_transfers, [:token, :from_address, :to_address]}])
|> Repo.all()

Loading…
Cancel
Save