RPCs for versioning (#175)

* RPCs for versioning.

* Build fix for bad merge.

* Add system_name RPC

* Fix tests.

* Fix demo build.

* Remove BadFormat.
This commit is contained in:
Gav Wood
2018-05-29 09:58:48 +01:00
committed by GitHub
parent fa642cf01a
commit 72eaf324a4
3 changed files with 44 additions and 5 deletions
+19
View File
@@ -22,6 +22,7 @@ pub use network::NetworkConfiguration;
/// The chain specification (this should eventually be replaced by a more general JSON-based chain
/// specification).
#[derive(Clone)]
pub enum ChainSpec {
/// Whatever the current runtime is, with just Alice as an auth.
Development,
@@ -62,3 +63,21 @@ impl Default for Configuration {
}
}
}
impl Clone for Configuration {
fn clone(&self) -> Configuration {
Configuration {
roles: self.roles.clone(),
transaction_pool: transaction_pool::Options {
max_count: self.transaction_pool.max_count.clone(),
max_mem_usage: self.transaction_pool.max_mem_usage.clone(),
max_per_sender: self.transaction_pool.max_per_sender.clone(),
},
network: self.network.clone(),
keystore_path: self.keystore_path.clone(),
database_path: self.database_path.clone(),
keys: self.keys.clone(),
chain_spec: self.chain_spec.clone(),
}
}
}