mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-23 14:54:45 +00:00
Remove fallback support from eth1 service (#3594)
## Issue Addressed N/A ## Proposed Changes With https://github.com/sigp/lighthouse/pull/3214 we made it such that you can either have 1 auth endpoint or multiple non auth endpoints. Now that we are post merge on all networks (testnets and mainnet), we cannot progress a chain without a dedicated auth execution layer connection so there is no point in having a non-auth eth1-endpoint for syncing deposit cache. This code removes all fallback related code in the eth1 service. We still keep the single non-auth endpoint since it's useful for testing. ## Additional Info This removes all eth1 fallback related metrics that were relevant for the monitoring service, so we might need to change the api upstream.
This commit is contained in:
@@ -230,17 +230,14 @@ pub fn get_config<E: EthSpec>(
|
||||
);
|
||||
client_config.sync_eth1_chain = true;
|
||||
|
||||
let endpoints = vec![SensitiveUrl::parse(endpoint)
|
||||
.map_err(|e| format!("eth1-endpoint was an invalid URL: {:?}", e))?];
|
||||
client_config.eth1.endpoints = Eth1Endpoint::NoAuth(endpoints);
|
||||
} else if let Some(endpoints) = cli_args.value_of("eth1-endpoints") {
|
||||
let endpoint = SensitiveUrl::parse(endpoint)
|
||||
.map_err(|e| format!("eth1-endpoint was an invalid URL: {:?}", e))?;
|
||||
client_config.eth1.endpoint = Eth1Endpoint::NoAuth(endpoint);
|
||||
} else if let Some(endpoint) = cli_args.value_of("eth1-endpoints") {
|
||||
client_config.sync_eth1_chain = true;
|
||||
let endpoints = endpoints
|
||||
.split(',')
|
||||
.map(SensitiveUrl::parse)
|
||||
.collect::<Result<_, _>>()
|
||||
let endpoint = SensitiveUrl::parse(endpoint)
|
||||
.map_err(|e| format!("eth1-endpoints contains an invalid URL {:?}", e))?;
|
||||
client_config.eth1.endpoints = Eth1Endpoint::NoAuth(endpoints);
|
||||
client_config.eth1.endpoint = Eth1Endpoint::NoAuth(endpoint);
|
||||
}
|
||||
|
||||
if let Some(val) = cli_args.value_of("eth1-blocks-per-log-query") {
|
||||
@@ -326,7 +323,7 @@ pub fn get_config<E: EthSpec>(
|
||||
--eth1-endpoints has been deprecated for post-merge configurations"
|
||||
);
|
||||
}
|
||||
client_config.eth1.endpoints = Eth1Endpoint::Auth {
|
||||
client_config.eth1.endpoint = Eth1Endpoint::Auth {
|
||||
endpoint: execution_endpoint,
|
||||
jwt_path: secret_file,
|
||||
jwt_id: el_config.jwt_id.clone(),
|
||||
|
||||
Reference in New Issue
Block a user