@@ -1416,12 +1416,19 @@ impl EthereumAdapterTrait for EthereumAdapter {
1416
1416
)
1417
1417
. await ;
1418
1418
1419
- fetch_receipts_with_retry ( web3, hashes, block_hash, logger, supports_block_receipts)
1420
- . await
1421
- . map ( |transaction_receipts| EthereumBlock {
1422
- block : Arc :: new ( block) ,
1423
- transaction_receipts,
1424
- } )
1419
+ fetch_receipts_with_retry (
1420
+ web3,
1421
+ hashes,
1422
+ block_hash,
1423
+ logger,
1424
+ supports_block_receipts,
1425
+ & self . provider ,
1426
+ )
1427
+ . await
1428
+ . map ( |transaction_receipts| EthereumBlock {
1429
+ block : Arc :: new ( block) ,
1430
+ transaction_receipts,
1431
+ } )
1425
1432
}
1426
1433
1427
1434
async fn block_hash_by_block_number (
@@ -2331,11 +2338,12 @@ async fn fetch_receipts_with_retry(
2331
2338
block_hash : H256 ,
2332
2339
logger : Logger ,
2333
2340
supports_block_receipts : bool ,
2341
+ provider : & str ,
2334
2342
) -> Result < Vec < Arc < TransactionReceipt > > , IngestorError > {
2335
2343
if supports_block_receipts {
2336
2344
return fetch_block_receipts_with_retry ( web3, hashes, block_hash, logger) . await ;
2337
2345
}
2338
- fetch_individual_receipts_with_retry ( web3, hashes, block_hash, logger) . await
2346
+ fetch_individual_receipts_with_retry ( web3, hashes, block_hash, logger, provider ) . await
2339
2347
}
2340
2348
2341
2349
// Fetches receipts for each transaction in the block individually.
@@ -2344,6 +2352,7 @@ async fn fetch_individual_receipts_with_retry(
2344
2352
hashes : Vec < H256 > ,
2345
2353
block_hash : H256 ,
2346
2354
logger : Logger ,
2355
+ provider : & str ,
2347
2356
) -> Result < Vec < Arc < TransactionReceipt > > , IngestorError > {
2348
2357
if ENV_VARS . fetch_receipts_in_batches {
2349
2358
return fetch_transaction_receipts_in_batch_with_retry ( web3, hashes, block_hash, logger)
@@ -2359,6 +2368,7 @@ async fn fetch_individual_receipts_with_retry(
2359
2368
tx_hash,
2360
2369
block_hash,
2361
2370
logger. cheap_clone ( ) ,
2371
+ provider,
2362
2372
)
2363
2373
} )
2364
2374
. buffered ( ENV_VARS . block_ingestor_max_concurrent_json_rpc_calls ) ;
@@ -2419,11 +2429,12 @@ async fn fetch_transaction_receipt_with_retry(
2419
2429
transaction_hash : H256 ,
2420
2430
block_hash : H256 ,
2421
2431
logger : Logger ,
2432
+ provider : & str ,
2422
2433
) -> Result < Arc < TransactionReceipt > , IngestorError > {
2423
2434
let logger = logger. cheap_clone ( ) ;
2424
2435
let retry_log_message = format ! (
2425
- "eth_getTransactionReceipt RPC call for transaction {:?}" ,
2426
- transaction_hash
2436
+ "eth_getTransactionReceipt RPC call for transaction {:?} from provider {} " ,
2437
+ transaction_hash, provider
2427
2438
) ;
2428
2439
retry ( retry_log_message, & logger)
2429
2440
. redact_log_urls ( true )
@@ -2602,6 +2613,7 @@ async fn get_transaction_receipts_for_transaction_hashes(
2602
2613
* transaction_hash,
2603
2614
* block_hash,
2604
2615
logger. cheap_clone ( ) ,
2616
+ & adapter. provider ,
2605
2617
) ;
2606
2618
receipt_futures. push ( receipt_future)
2607
2619
}
0 commit comments