This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// initialise with: | |
// post({sender: runtime.indices.ss58Decode('F7Gh'), call: calls.demo.setPayment(1000)}).tie(console.log) | |
use parity_codec::Encode; | |
use srml_support::{StorageValue, dispatch::Result, decl_module, decl_storage}; | |
use runtime_primitives::traits::Hash; | |
use {balances, system::{self, ensure_signed}}; | |
pub trait Trait: balances::Trait {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use support::{decl_module, decl_storage, decl_event, StorageValue, dispatch::Result}; | |
use system::ensure_signed; | |
pub trait Trait: system::Trait { | |
type Event: From<Event<Self>> + Into<<Self as system::Trait>::Event>; | |
} | |
type U8 = [u8; 1]; | |
decl_storage! { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use support::{decl_module, dispatch::Result, | |
traits::{Currency, ExistenceRequirement, WithdrawReason}}; | |
use system::ensure_signed; | |
// v1.0 branch | |
// use runtime_primitives::traits::As; | |
pub trait Trait: balances::Trait {} | |
decl_module! { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use support::{decl_module, decl_storage, decl_event, StorageValue, dispatch::Result, ensure, StorageMap}; | |
use system::ensure_signed; | |
pub trait Trait: system::Trait { | |
type Event: From<Event<Self>> + Into<<Self as system::Trait>::Event>; | |
} | |
decl_storage! { | |
trait Store for Module<T: Trait> as calculator { | |
FinalResult: u64; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use support::{decl_module, decl_storage, StorageValue, dispatch::Result}; | |
use system::ensure_signed; | |
use parity_codec::{ Encode, Decode }; | |
#[derive(Encode, Decode, Clone, PartialEq)] | |
#[cfg_attr(feature = "std", derive(Debug))] | |
pub enum Choices { | |
None, | |
One, | |
Two, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use support::{decl_module, decl_storage, decl_event, StorageValue, dispatch::Result}; | |
use system::ensure_signed; | |
use rstd::prelude::*; | |
use rstd::collections::btree_set::BTreeSet; | |
pub trait Trait: system::Trait { | |
type Event: From<Event<Self>> + Into<<Self as system::Trait>::Event>; | |
} | |
decl_storage! { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "Local Testnet", | |
"id": "local_testnet", | |
"bootNodes": [ | |
"/ip4/127.0.0.1/tcp/30333/p2p/QmSidBKvi8CcbqK5TZdAq1cxFBJAYwUWmg6VwwPtVK2eyT" | |
], | |
"telemetryEndpoints": null, | |
"protocolId": null, | |
"consensusEngine": null, | |
"properties": null, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// A runtime module that interprets a sipmlified pi calculus | |
use support::{decl_module, decl_storage, decl_event, StorageMap, dispatch::Result, ensure}; | |
use system::ensure_signed; | |
use rstd::boxed::Box; | |
use codec::{ Encode, Decode }; | |
use sr_primitives::traits::Hash; | |
/// All the types of processes in our calculus |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
###################################### | |
+++ Winner Validators: | |
#1 == W3F-012 [578e1d3e796c1df204ceb0dd0841b28df59ca81b1e49e0c81e08da11eb088158 (EZ7uBY7Z...)] | |
[stake_total: 26827_KSM (26,827,164,243,973,954)] [vote_count: 5] [ctrl: Some(1e4c6490abbc74684fa6a32b771a6ace358279948b2655685236679ea8d1af67 (DG3eXF79...))] | |
#2 == cp287-cloudwalk [30599dba50b5f3ba0b36f856a761eb3c0aee61e830d4beb448ef94b6ad92be39 (DfiSM1qq...)] | |
[stake_total: 22056_KSM (22,056,129,553,895,962)] [vote_count: 15] [ctrl: Some(30599dba50b5f3ba0b36f856a761eb3c0aee61e830d4beb448ef94b6ad92be39 (DfiSM1qq...))] | |
#3 == W3F-020 [9ee6f9ef5cb4d24b3519c7efca31a60dc27c215100014e50f8871feb381aebba (GAfhRsNq...)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fio --randrepeat=1 --ioengine=posixaio --direct=1 --gtod_reduce=1 --name=test --filename=test --bs=4k --iodepth=64 --size=4G --readwrite=randrw --rwmixread=75 |
OlderNewer