@@ -44,7 +44,7 @@ use trin_metrics::bridge::BridgeMetricsReporter;
44
44
use crate :: {
45
45
api:: consensus:: ConsensusApi ,
46
46
constants:: BEACON_GENESIS_TIME ,
47
- gossip :: gossip_beacon_content ,
47
+ put_content :: put_content_beacon_content ,
48
48
stats:: { BeaconSlotStats , StatsReporter } ,
49
49
types:: mode:: BridgeMode ,
50
50
utils:: {
@@ -127,7 +127,7 @@ impl BeaconBridge {
127
127
// test files have no slot number data, so report all gossiped content at height 0.
128
128
let slot_stats = Arc :: new ( StdMutex :: new ( BeaconSlotStats :: new ( 0 ) ) ) ;
129
129
for asset in assets. 0 . into_iter ( ) {
130
- gossip_beacon_content (
130
+ put_content_beacon_content (
131
131
self . portal_client . clone ( ) ,
132
132
asset. content_key . clone ( ) ,
133
133
asset. content_value ( ) . expect ( "Error getting content value" ) ,
@@ -336,7 +336,7 @@ impl BeaconBridge {
336
336
} ) ;
337
337
338
338
// Return the latest finalized block root if we successfully gossiped the latest bootstrap.
339
- gossip_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
339
+ put_content_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
340
340
finalized_bootstrap. lock ( ) . await . finalized_block_root = latest_finalized_block_root;
341
341
finalized_bootstrap. lock ( ) . await . in_progress = false ;
342
342
@@ -402,7 +402,7 @@ impl BeaconBridge {
402
402
) ;
403
403
404
404
// Update the current known period if we successfully gossiped the latest data.
405
- gossip_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
405
+ put_content_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
406
406
* current_period. lock ( ) . await = expected_current_period;
407
407
408
408
Ok ( ( ) )
@@ -426,7 +426,7 @@ impl BeaconBridge {
426
426
LightClientOptimisticUpdateKey :: new ( update. signature_slot ) ,
427
427
) ;
428
428
let content_value = BeaconContentValue :: LightClientOptimisticUpdate ( update. into ( ) ) ;
429
- gossip_beacon_content ( portal_client, content_key, content_value, slot_stats) . await
429
+ put_content_beacon_content ( portal_client, content_key, content_value, slot_stats) . await
430
430
}
431
431
432
432
async fn serve_light_client_finality_update (
@@ -465,7 +465,7 @@ impl BeaconBridge {
465
465
) ;
466
466
let content_value = BeaconContentValue :: LightClientFinalityUpdate ( update. into ( ) ) ;
467
467
468
- gossip_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
468
+ put_content_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
469
469
* finalized_slot. lock ( ) . await = new_finalized_slot;
470
470
471
471
Ok ( ( ) )
@@ -532,7 +532,7 @@ impl BeaconBridge {
532
532
let content_value =
533
533
BeaconContentValue :: HistoricalSummariesWithProof ( historical_summaries_with_proof) ;
534
534
535
- gossip_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
535
+ put_content_beacon_content ( portal_client, content_key, content_value, slot_stats) . await ?;
536
536
finalized_state_root. lock ( ) . await . state_root = latest_finalized_state_root;
537
537
finalized_state_root. lock ( ) . await . in_progress = false ;
538
538
0 commit comments