Skip to content

Commit

Permalink
Merge pull request #273 from Concordium/138-maintain-or-remove-features
Browse files Browse the repository at this point in the history
Fixes #138:Removes `genesis_tester` feature.
  • Loading branch information
rimbi authored Apr 20, 2022
2 parents 56a2e64 + c0eac46 commit f63761a
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 205 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,9 @@ jobs:
- name: Run clippy (without extra features)
run: |
cargo clippy --manifest-path concordium-node/Cargo.toml --all -- -Dclippy::all
- name: Run clippy (with features 'instrumentation', 'collector', 'network_dump', 'database_emitter')
- name: Run clippy (with features 'instrumentation', 'collector', 'network_dump')
run: |
cargo clippy --manifest-path concordium-node/Cargo.toml --features=instrumentation,collector,network_dump,database_emitter --all -- -Dclippy::all
cargo clippy --manifest-path concordium-node/Cargo.toml --features=instrumentation,collector,network_dump --all -- -Dclippy::all
- name: Run clippy on collector backend
run: |
cargo clippy --manifest-path collector-backend/Cargo.toml -- -Dclippy::all
Expand Down
17 changes: 0 additions & 17 deletions concordium-node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ network_dump = []
static = [ ]
profiling = [ "static" ]
collector = [ "reqwest/default-tls", "serde/derive", "rmp-serde", "collector-backend" ]
database_emitter = []
genesis_tester = [ "tempfile" ]

[profile.release]
codegen-units = 1
Expand Down Expand Up @@ -129,25 +127,10 @@ name = "node-collector"
path = "src/bin/collector.rs"
required-features = [ "collector" ]

[[bin]]
name = "network_stress_test"
path = "src/bin/network_stress_test.rs"
required-features = [ "test_utils" ]

[[bin]]
name = "bootstrap_checker"
path = "src/bin/bootstrap_checker.rs"

[[bin]]
name = "database_emitter"
path = "src/bin/database_emitter.rs"
required-features = [ "database_emitter" ]

[[bin]]
name = "genesis_tester"
path = "src/bin/genesis_tester.rs"
required-features = [ "genesis_tester" ]

[[bench]]
name = "p2p_lib_benchmark"
required-features = [ "test_utils" ]
Expand Down
2 changes: 0 additions & 2 deletions concordium-node/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
* static - build against static haskell libraries (Linux only)
* profiling - build against haskell libraries with profiling support enabled (Linux only)
* collector - enables the build of the node-collector and backend
* database_emitter - enables building the database emitter binary to inject a database exported to a set of nodes
* genesis_tester - a tool used by a CI to validate the genesis data
* dedup_benchmarks - enable support in the benchmarks for deduplication queues

## Building the node
Expand Down
124 changes: 0 additions & 124 deletions concordium-node/src/bin/database_emitter.rs

This file was deleted.

51 changes: 6 additions & 45 deletions concordium-node/src/configuration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,42 +80,6 @@ pub const DATABASE_SUB_DIRECTORY_NAME: &str = "database-v4";
/// being dropped prematurely.
const KEEP_ALIVE_FACTOR: u8 = 3;

#[cfg(feature = "database_emitter")]
#[derive(StructOpt, Debug)]
// Parameters related to the database emitter.
pub struct DatabaseEmitterConfig {
#[structopt(
long = "import-file",
help = "File to import from",
env = "CONCORDIUM_NODE_DB_EMITTER_IMPORT_FILE"
)]
pub import_file: String,

#[structopt(
long = "batches-delay",
help = "Delay between batches in miliseconds",
default_value = "2000",
env = "CONCORDIUM_NODE_DB_EMITTER_BATCHES_DELAY"
)]
pub delay_between_batches: u64,

#[structopt(
long = "batch-size",
help = "Size of each batch to emit",
default_value = "40",
env = "CONCORDIUM_NODE_DB_EMITTER_BATCH_SIZES"
)]
pub batch_sizes: u64,

#[structopt(
long = "skip-first",
help = "Amount of the initial blocks to skip",
default_value = "0",
env = "CONCORDIUM_NODE_DB_EMITTER_SKIP_FIRST"
)]
pub skip_first: u64,
}

#[cfg(feature = "instrumentation")]
#[derive(StructOpt, Debug)]
// Parameters related to Prometheus.
Expand Down Expand Up @@ -778,22 +742,19 @@ pub struct MacOsConfig {
#[structopt(about = "Concordium P2P node.")]
pub struct Config {
#[structopt(flatten)]
pub common: CommonConfig,
pub common: CommonConfig,
#[cfg(feature = "instrumentation")]
#[structopt(flatten)]
pub prometheus: PrometheusConfig,
#[structopt(flatten)]
pub connection: ConnectionConfig,
pub prometheus: PrometheusConfig,
#[structopt(flatten)]
pub cli: CliConfig,
pub connection: ConnectionConfig,
#[structopt(flatten)]
pub bootstrapper: BootstrapperConfig,
#[cfg(feature = "database_emitter")]
pub cli: CliConfig,
#[structopt(flatten)]
pub database_emitter: DatabaseEmitterConfig,
pub bootstrapper: BootstrapperConfig,
#[cfg(target_os = "macos")]
#[structopt(flatten)]
pub macos: MacOsConfig,
pub macos: MacOsConfig,
}

impl Config {
Expand Down
15 changes: 0 additions & 15 deletions scripts/test-genesis.sh

This file was deleted.

0 comments on commit f63761a

Please sign in to comment.