MCPcopy Create free account
hub / github.com/base/base / components

Method components

crates/execution/node/src/node.rs:249–288  ·  view source on GitHub ↗

Returns the components for the given [`RollupArgs`].

(&self)

Source from the content-addressed store, hash-verified

247
248 /// Returns the components for the given [`RollupArgs`].
249 pub fn components<Node>(&self) -> BaseNodeComponentBuilder<Node>
250 where
251 Node: FullNodeTypes<Types: BaseNodeTypes>,
252 {
253 let RollupArgs {
254 discovery_v4,
255 txpool_ordering,
256 max_inflight_delegated_slots,
257 mempool_sender_limit,
258 mempool_payer_limit,
259 ..
260 } = self.args;
261 let ordering = match txpool_ordering {
262 TxpoolOrdering::CoinbaseTip => BaseOrdering::coinbase_tip(),
263 TxpoolOrdering::Timestamp => BaseOrdering::timestamp(),
264 };
265 ComponentsBuilder::default()
266 .node_types::<Node>()
267 .executor(BaseExecutorBuilder::default())
268 .pool(
269 BasePoolBuilder::default()
270 .with_ordering(ordering)
271 .with_max_inflight_delegated_slots(max_inflight_delegated_slots)
272 .with_guard_limits(GuardLimits {
273 signature_limit: mempool_sender_limit,
274 payment_limit: mempool_payer_limit,
275 })
276 .with_validity_pool_limits(self.args.validity_pool_limits())
277 .with_additional_trusted_delegation_targets(
278 self.args.mempool_trusted_delegation_targets.iter().copied(),
279 ),
280 )
281 .payload(BasePayloadServiceBuilder::new(
282 BasePayloadBuilder::new()
283 .with_da_config(self.da_config.clone())
284 .with_gas_limit_config(self.gas_limit_config.clone()),
285 ))
286 .network(BaseNetworkBuilder::new(!discovery_v4))
287 .consensus(BaseConsensusBuilder::default())
288 }
289
290 /// Returns [`BaseAddOnsBuilder`] with configured arguments.
291 pub fn add_ons_builder<NetworkT: RpcTypes>(&self) -> BaseAddOnsBuilder<NetworkT> {

Callers 6

startMethod · 0.45
startMethod · 0.45
fetch_entryMethod · 0.45
validate_idMethod · 0.45

Calls 15

consensusMethod · 0.80
with_orderingMethod · 0.80
validity_pool_limitsMethod · 0.80
newFunction · 0.50
networkMethod · 0.45
payloadMethod · 0.45
poolMethod · 0.45
with_guard_limitsMethod · 0.45
iterMethod · 0.45

Tested by 1