neo-go/pkg
decentralisedkev 30e5aa8f48
Add Chain saving functionality to Database (#206)
* [database]

- Add Prefix method to interface
- Convert leveldb error to `database error`
- Be explicit with prefixedKey in `Table` as slices can be pointers

* [protocol]
- Add stringer method to protocol

* [Chaindb]

- Added saveBlock() which will allow us to save a block into the
database. The block is broken up into transactions and Headers. The
headers are saved as is. The transactions are saved as is, then the
utxos in the transactions are collected to make the utxo db.

- Verification for blocks and transactions will reside in the same
package. Note that the save methods are all unexported, while the Get
methods are exported. Making it so that any can call a get method, but
only code in this package may save to the database. The other code which
will reside in this package will be code verification logic.

* [chaindb]

- Added saveHeader function which saveHeaders  uses

- Update the latest header, each time we save a header instead of after a batch. This is so that we can call saveHeader without saveHeaders. This functionality can be rolled back if the performance of updating the header after a batch is significant

- small refactor in test code
2019-03-23 16:57:05 +00:00
..
chain Add Chain saving functionality to Database (#206) 2019-03-23 16:57:05 +00:00
connmgr [connmgr] Refactor Connmgr (#205) 2019-03-21 23:18:02 +00:00
crypto remove extra base58 2019-03-17 23:02:34 +00:00
database Add Chain saving functionality to Database (#206) 2019-03-23 16:57:05 +00:00
peer Add Chain saving functionality to Database (#206) 2019-03-23 16:57:05 +00:00
pubsub Fix lint errors (#182) 2019-03-17 18:26:35 +00:00
vm VM: Add basic vm (#166) 2019-03-18 21:40:21 +00:00
wire Add Chain saving functionality to Database (#206) 2019-03-23 16:57:05 +00:00
Readme.md Initial commit 2019-02-25 22:44:14 +00:00

ReadMe

Currently this package is in Development.

References

btcd https://github.com/btcsuite/btcd

geth https://github.com/ethereum/go-ethereum

aeternity https://github.com/aeternity/elixir-node