@@ -14,12 +14,14 @@ use anyhow::Context;
14
14
use async_std:: sync:: RwLock ;
15
15
use catchup:: StatePeers ;
16
16
use context:: SequencerContext ;
17
- use espresso_types:: { BackoffParams , L1Client , NodeState , PubKey , SeqTypes , ValidatedState } ;
17
+ use espresso_types:: {
18
+ BackoffParams , L1Client , NodeState , PubKey , SeqTypes , SolverAuctionResultsProvider ,
19
+ ValidatedState ,
20
+ } ;
18
21
use ethers:: types:: U256 ;
19
22
#[ cfg( feature = "libp2p" ) ]
20
23
use futures:: FutureExt ;
21
24
use genesis:: L1Finalized ;
22
- use hotshot_example_types:: auction_results_provider_types:: TestAuctionResultsProvider ;
23
25
// Should move `STAKE_TABLE_CAPACITY` in the sequencer repo when we have variate stake table support
24
26
use libp2p:: Multiaddr ;
25
27
use network:: libp2p:: split_off_peer_id;
@@ -47,6 +49,7 @@ use hotshot::{
47
49
WrappedSignatureKey ,
48
50
} ,
49
51
types:: SignatureKey ,
52
+ MarketplaceConfig ,
50
53
} ;
51
54
use hotshot_orchestrator:: {
52
55
client:: { OrchestratorClient , ValidatorArgs } ,
@@ -95,7 +98,7 @@ impl<N: ConnectedNetwork<PubKey>, P: SequencerPersistence> NodeImplementation<Se
95
98
{
96
99
type Network = N ;
97
100
type Storage = Arc < RwLock < P > > ;
98
- type AuctionResultsProvider = TestAuctionResultsProvider < SeqTypes > ;
101
+ type AuctionResultsProvider = SolverAuctionResultsProvider ;
99
102
}
100
103
101
104
#[ derive( Clone , Debug ) ]
@@ -136,6 +139,7 @@ pub async fn init_node<P: PersistenceOptions, Ver: StaticVersionType + 'static>(
136
139
bind_version : Ver ,
137
140
is_da : bool ,
138
141
identity : Identity ,
142
+ marketplace_config : MarketplaceConfig < SeqTypes , Node < network:: Production , P :: Persistence > > ,
139
143
) -> anyhow:: Result < SequencerContext < network:: Production , P :: Persistence , Ver > > {
140
144
// Expose git information via status API.
141
145
metrics
@@ -409,6 +413,7 @@ pub async fn init_node<P: PersistenceOptions, Ver: StaticVersionType + 'static>(
409
413
network_params. public_api_url ,
410
414
Url :: from_str ( "http://localhost" ) . unwrap ( ) ,
411
415
bind_version,
416
+ marketplace_config,
412
417
)
413
418
. await ?;
414
419
if wait_for_orchestrator {
@@ -423,7 +428,7 @@ pub fn empty_builder_commitment() -> BuilderCommitment {
423
428
424
429
#[ cfg( any( test, feature = "testing" ) ) ]
425
430
pub mod testing {
426
- use std:: { collections:: HashMap , time:: Duration } ;
431
+ use std:: { collections:: HashMap , str :: FromStr , time:: Duration } ;
427
432
428
433
use committable:: Committable ;
429
434
use espresso_types:: {
@@ -758,6 +763,12 @@ pub mod testing {
758
763
None , // The public API URL
759
764
Url :: from_str ( "http://localhost" ) . unwrap ( ) ,
760
765
bind_version,
766
+ MarketplaceConfig :: < SeqTypes , Node < network:: Memory , P :: Persistence > > {
767
+ auction_results_provider : Arc :: new ( SolverAuctionResultsProvider (
768
+ Url :: from_str ( "https://some.solver" ) . unwrap ( ) ,
769
+ ) ) ,
770
+ generic_builder_url : Url :: from_str ( "https://some.builder" ) . unwrap ( ) ,
771
+ } ,
761
772
)
762
773
. await
763
774
. unwrap ( )
0 commit comments