feat: Rebrand Polkadot/Substrate references to PezkuwiChain

This commit systematically rebrands various references from Parity Technologies'
Polkadot/Substrate ecosystem to PezkuwiChain within the kurdistan-sdk.

Key changes include:
- Updated external repository URLs (zombienet-sdk, parity-db, parity-scale-codec, wasm-instrument) to point to pezkuwichain forks.
- Modified internal documentation and code comments to reflect PezkuwiChain naming and structure.
- Replaced direct references to  with  or specific paths within the  for XCM, Pezkuwi, and other modules.
- Cleaned up deprecated  issue and PR references in various  and  files, particularly in  and  modules.
- Adjusted image and logo URLs in documentation to point to PezkuwiChain assets.
- Removed or rephrased comments related to external Polkadot/Substrate PRs and issues.

This is a significant step towards fully customizing the SDK for the PezkuwiChain ecosystem.
This commit is contained in:
2025-12-14 00:04:10 +03:00
parent 286de54384
commit 1c0e57d984
9084 changed files with 997839 additions and 997557 deletions
@@ -0,0 +1,55 @@
// This file is part of Bizinikiwi.
// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
use criterion::{criterion_group, criterion_main, Criterion};
use tracing_subscriber::fmt::{
format,
time::{ChronoLocal, FormatTime},
};
fn bench_fast_local_time(c: &mut Criterion) {
c.bench_function("fast_local_time", |b| {
let mut buffer = String::new();
let t = pezsc_tracing::logging::FastLocalTime { with_fractional: true };
b.iter(|| {
buffer.clear();
let mut writer = format::Writer::new(&mut buffer);
t.format_time(&mut writer).unwrap();
})
});
}
// This is here just as a point of comparison.
fn bench_chrono_local(c: &mut Criterion) {
c.bench_function("chrono_local", |b| {
let mut buffer = String::new();
let t = ChronoLocal::new("%Y-%m-%d %H:%M:%S%.3f".to_string());
b.iter(|| {
buffer.clear();
let mut writer: format::Writer<'_> = format::Writer::new(&mut buffer);
t.format_time(&mut writer).unwrap();
})
});
}
criterion_group! {
name = benches;
config = Criterion::default();
targets = bench_fast_local_time, bench_chrono_local
}
criterion_main!(benches);
@@ -0,0 +1,105 @@
// This file is part of Bizinikiwi.
//
// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
//! Common utilities for interest cache benchmarks.
use log::{Level, LevelFilter};
use tracing_subscriber::{EnvFilter, FmtSubscriber};
/// Initialize logger with interest cache configuration from INTEREST_CACHE environment variable.
pub fn init_logger() {
let mut log_tracer = tracing_log::LogTracer::builder().with_max_level(LevelFilter::Trace);
if let Some(config) = parse_interest_cache_config() {
eprintln!("Interest cache config: {config:?}");
log_tracer = log_tracer.with_interest_cache(config);
}
log_tracer.init().expect("Failed to init LogTracer");
let env_filter = EnvFilter::default()
.add_directive("info".parse().unwrap())
.add_directive("dummy=trace".parse().unwrap());
let subscriber = FmtSubscriber::builder()
.with_env_filter(env_filter)
.with_writer(std::io::sink)
.with_filter_reloading()
.finish();
tracing::subscriber::set_global_default(subscriber).expect("Failed to set subscriber");
}
/// Parse interest cache configuration from INTEREST_CACHE environment variable.
///
/// Returns `None` if cache should be disabled, `Some(config)` otherwise.
///
/// Supported formats:
/// - "disabled", "none", "no", "false" - cache disabled
/// - "default" - cache enabled with default config
/// - "key=value,key=value" - cache enabled with custom config
/// - lru_cache_size=<number> - set LRU cache size
/// - min_verbosity=<level> - set minimum verbosity level (error, warn, info, debug, trace)
fn parse_interest_cache_config() -> Option<tracing_log::InterestCacheConfig> {
let config_str = std::env::var("INTEREST_CACHE").ok()?;
let config_lower = config_str.to_lowercase();
let mut config = tracing_log::InterestCacheConfig::default();
// Check if disabled
if matches!(config_lower.as_str(), "none" | "disabled" | "no" | "false") {
eprintln!("Interest cache: disabled");
return Some(config.with_lru_cache_size(0));
}
// If "default", use default config
if config_lower == "default" {
eprintln!("Interest cache: default config");
return Some(config);
}
// Parse key=value pairs
for pair in config_str.split(',') {
let parts: Vec<&str> = pair.trim().split('=').collect();
if parts.len() != 2 {
eprintln!("Invalid config pair '{}', expected key=value", pair);
continue;
}
let key = parts[0].trim();
let value = parts[1].trim();
match key {
"lru_cache_size" =>
if let Ok(size) = value.parse::<usize>() {
config = config.with_lru_cache_size(size);
eprintln!("Interest cache: lru_cache_size = {}", size);
} else {
eprintln!("Invalid lru_cache_size value '{}'", value);
},
"min_verbosity" => {
let level = match value.to_lowercase().as_str() {
"error" => Some(Level::Error),
"warn" => Some(Level::Warn),
"info" => Some(Level::Info),
"debug" => Some(Level::Debug),
"trace" => Some(Level::Trace),
_ => {
eprintln!("Invalid min_verbosity '{}', using default", value);
None
},
};
if let Some(level) = level {
config = config.with_min_verbosity(level);
eprintln!("Interest cache: min_verbosity = {:?}", level);
}
},
_ => {
eprintln!("Unknown config key '{}'", key);
},
}
}
Some(config)
}
@@ -0,0 +1,33 @@
// This file is part of Bizinikiwi.
//
// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
//! Benchmark diverse targets with interest cache configuration from INTEREST_CACHE env var.
//!
//! Usage:
//! ```
//! INTEREST_CACHE=lru_cache_size=1024,min_verbosity=debug cargo bench --bench interest_cache_diverse
//! INTEREST_CACHE=default cargo bench --bench interest_cache_diverse
//! INTEREST_CACHE=disabled cargo bench --bench interest_cache_diverse
//! ```
use criterion::{criterion_group, criterion_main, Criterion};
mod common;
fn bench_diverse_targets(c: &mut Criterion) {
common::init_logger();
c.bench_function("diverse_targets", |b| {
b.iter(|| {
for i in 0..1000 {
let target = format!("module_{}", i % 50);
log::debug!(target: &target, "message {}", i);
log::trace!(target: &target, "trace {}", i);
}
})
});
}
criterion_group!(benches, bench_diverse_targets);
criterion_main!(benches);
@@ -0,0 +1,44 @@
// This file is part of Bizinikiwi.
//
// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
//! Benchmark multithreaded logging with interest cache configuration from INTEREST_CACHE env var.
//!
//! Usage:
//! ```
//! INTEREST_CACHE=lru_cache_size=1024,min_verbosity=debug cargo bench --bench interest_cache_multithreaded
//! INTEREST_CACHE=default cargo bench --bench interest_cache_multithreaded
//! INTEREST_CACHE=disabled cargo bench --bench interest_cache_multithreaded
//! ```
use criterion::{criterion_group, criterion_main, Criterion};
mod common;
fn bench_multithreaded(c: &mut Criterion) {
common::init_logger();
let mut group = c.benchmark_group("multithreaded");
group.bench_function("8_threads", |b| {
b.iter(|| {
let handles: Vec<_> = (0..8)
.map(|thread_id| {
std::thread::spawn(move || {
for i in 0..1000 {
log::debug!(target: "bizinikiwi", "thread {} msg {}", thread_id, i);
log::trace!(target: "runtime", "thread {} trace {}", thread_id, i);
}
})
})
.collect();
for handle in handles {
handle.join().unwrap();
}
})
});
group.finish();
}
criterion_group!(benches, bench_multithreaded);
criterion_main!(benches);
@@ -0,0 +1,38 @@
// This file is part of Bizinikiwi.
//
// Copyright (C) Parity Technologies (UK) Ltd.
// SPDX-License-Identifier: GPL-3.0-or-later WITH Classpath-exception-2.0
//! Benchmark realistic logging with interest cache configuration from INTEREST_CACHE env var.
//!
//! Usage:
//! ```
//! INTEREST_CACHE=lru_cache_size=1024,min_verbosity=debug cargo bench --bench interest_cache_realistic
//! INTEREST_CACHE=default cargo bench --bench interest_cache_realistic
//! INTEREST_CACHE=disabled cargo bench --bench interest_cache_realistic
//! ```
use criterion::{criterion_group, criterion_main, Criterion};
mod common;
fn bench_realistic_logging(c: &mut Criterion) {
common::init_logger();
c.bench_function("realistic_logging", |b| {
b.iter(|| {
for i in 0..1000 {
log::trace!(target: "bizinikiwi", "trace message {}", i);
log::debug!(target: "runtime", "debug message {}", i);
log::debug!(target: "sync", "sync debug {}", i);
log::trace!(target: "consensus", "consensus trace {}", i);
log::debug!(target: "network", "network debug {}", i);
if i % 10 == 0 {
log::info!(target: "bizinikiwi", "info message {}", i);
}
}
})
});
}
criterion_group!(benches, bench_realistic_logging);
criterion_main!(benches);