Skip to content

Yaml format to support shard ids and environment addresses. #44

Description

@poemm

The following is a proposed sample yaml file which supports both shards ids and environment addresses. (I should write a schema, which yaml schema definition language is preferred?)

prestates: # list of envs (envid, shardid, wasm filename, pre_state)
 - envid: 0x1000000000000000000000000000000000000000000000000000000000000000
   shardid: 1
   code: helloshards.wasm
   stateroot: 0x0000000000000000000000000000000000000000000000000000000000000000
 - envid: 0x2000000000000000000000000000000000000000000000000000000000000000
   shardid: 2
   code: helloshards.wasm
   stateroot: 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
timeslots: # list of time slots each with a list of shard_blocks (envid, calldata)
 - slot:
   - envid: 0x1000000000000000000000000000000000000000000000000000000000000000
     inputdata: 0x0200000000000000000000000000000000000000000000000000000000000000
   - envid: 0x2000000000000000000000000000000000000000000000000000000000000000
     inputdata: 0x0100000000000000000000000000000000000000000000000000000000000000
 - slot:
   - envid: 0x1000000000000000000000000000000000000000000000000000000000000000
     inputdata: 0x0000000000000000000000000000000000000000000000000000000000000000
poststates: # list of envs (envid, shardid, post_state)
 - envid: 0x1000000000000000000000000000000000000000000000000000000000000000
   shardid: 0
   stateroot: 0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
 - envid: 0x2000000000000000000000000000000000000000000000000000000000000000
   shardid: 1
   stateroot: 0x0000000000000000000000000000000000000000000000000000000000000000

Before I extend C, C++, and Python Scout yaml parsers, I am soliciting feedback.

This is a dependency to test shard-aware host functions proposed here #38 .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions