Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove jaeger everywhere #5875

Merged
merged 16 commits into from
Oct 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 1 addition & 64 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,6 @@ members = [
"polkadot/node/core/runtime-api",
"polkadot/node/gum",
"polkadot/node/gum/proc-macro",
"polkadot/node/jaeger",
"polkadot/node/malus",
"polkadot/node/metrics",
"polkadot/node/network/approval-distribution",
Expand Down Expand Up @@ -845,7 +844,6 @@ merkleized-metadata = { version = "0.1.0" }
merlin = { version = "3.0", default-features = false }
messages-relay = { path = "bridges/relays/messages" }
metered = { version = "0.6.1", default-features = false, package = "prioritized-metered-channel" }
mick-jaeger = { version = "0.1.8" }
milagro-bls = { version = "1.5.4", default-features = false, package = "snowbridge-milagro-bls" }
minimal-template-node = { path = "templates/minimal/node" }
minimal-template-runtime = { path = "templates/minimal/runtime" }
Expand Down Expand Up @@ -1049,7 +1047,6 @@ polkadot-node-core-pvf-common = { path = "polkadot/node/core/pvf/common", defaul
polkadot-node-core-pvf-execute-worker = { path = "polkadot/node/core/pvf/execute-worker", default-features = false }
polkadot-node-core-pvf-prepare-worker = { path = "polkadot/node/core/pvf/prepare-worker", default-features = false }
polkadot-node-core-runtime-api = { path = "polkadot/node/core/runtime-api", default-features = false }
polkadot-node-jaeger = { path = "polkadot/node/jaeger", default-features = false }
polkadot-node-metrics = { path = "polkadot/node/metrics", default-features = false }
polkadot-node-network-protocol = { path = "polkadot/node/network/protocol", default-features = false }
polkadot-node-primitives = { path = "polkadot/node/primitives", default-features = false }
Expand Down
1 change: 0 additions & 1 deletion cumulus/client/relay-chain-inprocess-interface/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ fn build_polkadot_full_node(
// Disable BEEFY. It should not be required by the internal relay chain node.
enable_beefy: false,
force_authoring_backoff: false,
jaeger_agent: None,
telemetry_worker_handle,

// Cumulus doesn't spawn PVF workers, so we can disable version checks.
Expand Down
6 changes: 0 additions & 6 deletions polkadot/cli/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,6 @@ pub struct RunCmd {
#[arg(long)]
pub force_authoring_backoff: bool,

/// Add the destination address to the 'Jaeger' agent.
///
/// Must be valid socket address, of format `IP:Port` (commonly `127.0.0.1:6831`).
#[arg(long)]
pub jaeger_agent: Option<String>,

/// Add the destination address to the `pyroscope` agent.
///
/// Must be valid socket address, of format `IP:Port` (commonly `127.0.0.1:4040`).
Expand Down
37 changes: 11 additions & 26 deletions polkadot/cli/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,15 @@ use polkadot_service::{
benchmarking::{benchmark_inherent_data, RemarkBuilder, TransferKeepAliveBuilder},
HeaderBackend, IdentifyVariant,
};
#[cfg(feature = "pyroscope")]
use pyroscope_pprofrs::{pprof_backend, PprofConfig};
use sc_cli::SubstrateCli;
use sp_core::crypto::Ss58AddressFormatRegistry;
use sp_keyring::Sr25519Keyring;
use std::net::ToSocketAddrs;

pub use crate::error::Error;
#[cfg(feature = "pyroscope")]
use pyroscope_pprofrs::{pprof_backend, PprofConfig};
use std::net::ToSocketAddrs;
alexggh marked this conversation as resolved.
Show resolved Hide resolved

type Result<T> = std::result::Result<T, Error>;

Expand Down Expand Up @@ -195,18 +196,6 @@ where
info!("----------------------------");
}

let jaeger_agent = if let Some(ref jaeger_agent) = cli.run.jaeger_agent {
Some(
jaeger_agent
.to_socket_addrs()
.map_err(Error::AddressResolutionFailure)?
.next()
.ok_or_else(|| Error::AddressResolutionMissing)?,
)
} else {
None
};

let node_version =
if cli.run.disable_worker_version_check { None } else { Some(NODE_VERSION.to_string()) };

Expand All @@ -227,7 +216,6 @@ where
is_parachain_node: polkadot_service::IsParachainNode::No,
enable_beefy,
force_authoring_backoff: cli.run.force_authoring_backoff,
jaeger_agent,
telemetry_worker_handle: None,
node_version,
secure_validator_mode,
Expand Down Expand Up @@ -306,7 +294,7 @@ pub fn run() -> Result<()> {

runner.async_run(|mut config| {
let (client, _, import_queue, task_manager) =
polkadot_service::new_chain_ops(&mut config, None)?;
polkadot_service::new_chain_ops(&mut config)?;
Ok((cmd.run(client, import_queue).map_err(Error::SubstrateCli), task_manager))
})
},
Expand All @@ -318,8 +306,7 @@ pub fn run() -> Result<()> {

Ok(runner.async_run(|mut config| {
let (client, _, _, task_manager) =
polkadot_service::new_chain_ops(&mut config, None)
.map_err(Error::PolkadotService)?;
polkadot_service::new_chain_ops(&mut config).map_err(Error::PolkadotService)?;
Ok((cmd.run(client, config.database).map_err(Error::SubstrateCli), task_manager))
})?)
},
Expand All @@ -330,8 +317,7 @@ pub fn run() -> Result<()> {
set_default_ss58_version(chain_spec);

Ok(runner.async_run(|mut config| {
let (client, _, _, task_manager) =
polkadot_service::new_chain_ops(&mut config, None)?;
let (client, _, _, task_manager) = polkadot_service::new_chain_ops(&mut config)?;
Ok((cmd.run(client, config.chain_spec).map_err(Error::SubstrateCli), task_manager))
})?)
},
Expand All @@ -343,7 +329,7 @@ pub fn run() -> Result<()> {

Ok(runner.async_run(|mut config| {
let (client, _, import_queue, task_manager) =
polkadot_service::new_chain_ops(&mut config, None)?;
polkadot_service::new_chain_ops(&mut config)?;
Ok((cmd.run(client, import_queue).map_err(Error::SubstrateCli), task_manager))
})?)
},
Expand All @@ -359,7 +345,7 @@ pub fn run() -> Result<()> {

Ok(runner.async_run(|mut config| {
let (client, backend, _, task_manager) =
polkadot_service::new_chain_ops(&mut config, None)?;
polkadot_service::new_chain_ops(&mut config)?;
let task_handle = task_manager.spawn_handle();
let aux_revert = Box::new(|client, backend, blocks| {
polkadot_service::revert_backend(client, backend, blocks, config, task_handle)
Expand Down Expand Up @@ -392,22 +378,21 @@ pub fn run() -> Result<()> {
.into()),
#[cfg(feature = "runtime-benchmarks")]
BenchmarkCmd::Storage(cmd) => runner.sync_run(|mut config| {
let (client, backend, _, _) =
polkadot_service::new_chain_ops(&mut config, None)?;
let (client, backend, _, _) = polkadot_service::new_chain_ops(&mut config)?;
let db = backend.expose_db();
let storage = backend.expose_storage();

cmd.run(config, client.clone(), db, storage).map_err(Error::SubstrateCli)
}),
BenchmarkCmd::Block(cmd) => runner.sync_run(|mut config| {
let (client, _, _, _) = polkadot_service::new_chain_ops(&mut config, None)?;
let (client, _, _, _) = polkadot_service::new_chain_ops(&mut config)?;

cmd.run(client.clone()).map_err(Error::SubstrateCli)
}),
// These commands are very similar and can be handled in nearly the same way.
BenchmarkCmd::Extrinsic(_) | BenchmarkCmd::Overhead(_) =>
runner.sync_run(|mut config| {
let (client, _, _, _) = polkadot_service::new_chain_ops(&mut config, None)?;
let (client, _, _, _) = polkadot_service::new_chain_ops(&mut config)?;
let header = client.header(client.info().genesis_hash).unwrap().unwrap();
let inherent_data = benchmark_inherent_data(header)
.map_err(|e| format!("generating inherent data: {:?}", e))?;
Expand Down
1 change: 0 additions & 1 deletion polkadot/node/collation-generation/src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1090,7 +1090,6 @@ mod helpers {
unpin_handle: polkadot_node_subsystem_test_helpers::mock::dummy_unpin_handle(
activated_hash,
),
span: Arc::new(overseer::jaeger::Span::Disabled),
}),
..Default::default()
})))
Expand Down
1 change: 0 additions & 1 deletion polkadot/node/core/approval-voting-parallel/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ polkadot-node-subsystem-util = { workspace = true, default-features = true }
polkadot-overseer = { workspace = true, default-features = true }
polkadot-primitives = { workspace = true, default-features = true }
polkadot-node-primitives = { workspace = true, default-features = true }
polkadot-node-jaeger = { workspace = true, default-features = true }
polkadot-node-network-protocol = { workspace = true, default-features = true }
polkadot-node-metrics = { workspace = true, default-features = true }

Expand Down
1 change: 0 additions & 1 deletion polkadot/node/core/av-store/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ polkadot-overseer = { workspace = true, default-features = true }
polkadot-primitives = { workspace = true, default-features = true }
polkadot-node-primitives = { workspace = true, default-features = true }
sp-consensus = { workspace = true }
polkadot-node-jaeger = { workspace = true, default-features = true }

[dev-dependencies]
log = { workspace = true, default-features = true }
Expand Down
7 changes: 0 additions & 7 deletions polkadot/node/core/av-store/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ use polkadot_node_subsystem_util::database::{DBTransaction, Database};
use sp_consensus::SyncOracle;

use bitvec::{order::Lsb0 as BitOrderLsb0, vec::BitVec};
use polkadot_node_jaeger as jaeger;
use polkadot_node_primitives::{AvailableData, ErasureChunk};
use polkadot_node_subsystem::{
errors::{ChainApiError, RuntimeApiError},
Expand Down Expand Up @@ -1315,10 +1314,6 @@ fn store_available_data(
},
};

let erasure_span = jaeger::Span::new(candidate_hash, "erasure-coding")
.with_candidate(candidate_hash)
.with_pov(&available_data.pov);

// Important note: This check below is critical for consensus and the `backing` subsystem relies
// on it to ensure candidate validity.
let chunks = polkadot_erasure_coding::obtain_chunks_v1(n_validators, &available_data)?;
Expand All @@ -1328,8 +1323,6 @@ fn store_available_data(
return Err(Error::InvalidErasureRoot)
}

drop(erasure_span);

let erasure_chunks: Vec<_> = chunks
.iter()
.zip(branches.map(|(proof, _)| proof))
Expand Down
Loading