A smart contract which shows how blockchain can be leveraged to bring open data about addresses one step further.
Open data about belgian addresses can be found on the SPF BOSA site.
- The application provides a decentralized registry for belgian addresses.
- The maintainer of the registry can add, remove and update addresses.
- The consumers can use the registry as a trustable data source for belgian addresses
- When addresses are added, removed or updated, actionable events are be emitted to allow consumers to react.
- Addresses removed from the registry remain accessible in the history of data.
- Consumers are be able to query the full data history and registry in a easy way.
Two personnas are defined for the application :
- The maintainer, who deploys the smart contract and manages the addresses.
- Consumers, who use the functionalities provided by the smart contract to use the blockchain as a database and as an event publishing system for events related to address management (insertions, deletions & updates)
Address data model :
struct StreetAddress {
bytes32 addressId;
string streetName;
string postcode;
string houseNumber;
string boxNumber;
string latitude;
string longitude;
}
Three data structures are managed by the contract :
- A map which uses the address ID as key and the address as value
- A map which uses the postcode as key and a list of all ids of addresses related to that postcode as value
- A list of all postcodes which have addresses in the registry
- Internet connection
- Web browser
See Lab1.md
- Internet connection
- Web browser
- Docker CLI
The lab has been tested with a virtual machine with 2vCPU, 8GB of RAM and 30GB of disk space
See Lab2.md