Skip to content

Commit

Permalink
[refactor] #4152: Remove bridge and dex features
Browse files Browse the repository at this point in the history
Signed-off-by: Shanin Roman <[email protected]>
  • Loading branch information
Erigara committed Jan 11, 2024
1 parent 1b2b2cd commit a44095d
Show file tree
Hide file tree
Showing 11 changed files with 7 additions and 48 deletions.
4 changes: 0 additions & 4 deletions Cargo.lock

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

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,6 @@ members = [
"smart_contract/utils",
"smart_contract/executor",
"smart_contract/executor/derive",
"substrate",
"telemetry",
"tools/kagami",
"tools/kura_inspector",
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ Iroha project mainly consists of the following crates:
* [`iroha_macro`](macro) provides the convenience macros.
* [`iroha_p2p`](p2p) defines peer creation and handshake logic.
* [`iroha_default_executor`](default_executor) defines runtime validation logic.
* [`iroha_substrate`](substrate) is the bridge substrate `XClaim` external module.
* [`iroha_telemetry`](telemetry) is used for monitoring and analysis of telemetry data.
* [`iroha_version`](version) provides message versioning for non-simultaneous system updates.

Expand Down
10 changes: 2 additions & 8 deletions cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,8 @@ categories.workspace = true
workspace = true

[features]
default = ["bridge", "telemetry", "schema-endpoint"]
default = ["telemetry", "schema-endpoint"]

# Support interoperability with popular blockchain networks (Substrate, Ether, etc.)
bridge = ["iroha_core/bridge"]
# Support Decentralised Exchange, including functionality for atomic exchange instruction
dex = ["iroha_core/dex"]
# Support lightweight telemetry, including diagnostics
telemetry = ["iroha_telemetry", "iroha_core/telemetry", "iroha_torii/telemetry"]
# Support developer-specific telemetry.
Expand Down Expand Up @@ -82,10 +78,8 @@ vergen = { workspace = true, features = ["cargo"] }

[package.metadata.cargo-all-features]
denylist = [
"bridge",
"dex",
"schema-endpoint",
"telemetry",
"test-network",
] # TODO: remove `dex` and `bridge` once there's code for them.
]
skip_optional_dependencies = true
6 changes: 3 additions & 3 deletions cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,17 @@ The results of the compilation can be found in `<IROHA REPO ROOT>/target/release

### Add features

To add optional features, use ``--features``. For example, to add the support for _dex_, run:
To add optional features, use ``--features``. For example, to add the support for _dev_telemetry_, run:

```bash
cargo build --release --features dex
cargo build --release --features dev-telemetry
```

A full list of features can be found in the [cargo manifest file](Cargo.toml) for this crate.

### Disable default features

By default, the Iroha binary is compiled with the `bridge`, `telemetry`, and `schema-endpoint` features. If you wish to remove those features, add `--no-default-features` to the command.
By default, the Iroha binary is compiled with the `telemetry`, and `schema-endpoint` features. If you wish to remove those features, add `--no-default-features` to the command.

```bash
cargo build --release --no-default-features
Expand Down
10 changes: 2 additions & 8 deletions core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,12 @@ categories.workspace = true
workspace = true

[features]
default = ["bridge", "cli", "telemetry"]
default = ["cli", "telemetry"]

# Interoperability with popular blockchain networks (Substrate, Ether, etc.)
bridge = []
# Support lightweight telemetry, including diagnostics
telemetry = []
# Support the included CLI
cli = []
# Support Decentralised Exchange, including functionality for atomic exchange instruction
dex = []
# Support developer-specific telemetry.
# Should not be enabled on production builds.
dev-telemetry = ["telemetry", "iroha_telemetry/dev-telemetry"]
Expand Down Expand Up @@ -110,10 +106,8 @@ path = "benches/blocks/validate_blocks_oneshot.rs"

[package.metadata.cargo-all-features]
denylist = [
"bridge",
"dex",
"schema-endpoint",
"telemetry",
"test-network"
] # TODO: remove `dex` and `bridge` once there's code for them.
]
skip_optional_dependencies = true
1 change: 0 additions & 1 deletion core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ pub mod executor;
pub mod gossiper;
pub mod kiso;
pub mod kura;
pub mod modules;
pub mod query;
pub mod queue;
pub mod smartcontracts;
Expand Down
1 change: 0 additions & 1 deletion core/src/modules/dex.rs

This file was deleted.

4 changes: 0 additions & 4 deletions core/src/modules/mod.rs

This file was deleted.

13 changes: 0 additions & 13 deletions substrate/Cargo.toml

This file was deleted.

4 changes: 0 additions & 4 deletions substrate/src/lib.rs

This file was deleted.

0 comments on commit a44095d

Please sign in to comment.