Commit Graph
26 Commits
Author SHA1 Message Date
Jaco Greeff bcb0186422 FlatDb open with 'r+' 2018-09-07 12:49:22 +02:00
Jaco Greeff daf84b850d Mark FlatDb as closed when closed 2018-09-07 10:44:44 +02:00
Jaco Greeff 61357fb289 Add drop() to BaseDb 2018-09-07 09:29:01 +02:00
Jaco Greeff c056480c28 Add size() to BaseDb 2018-09-06 22:48:51 +02:00
Jaco Greeff 0707a238d5 Export rename(base, file) on BaseDb 2018-09-06 22:15:11 +02:00
Jaco Greeff cc7227846e Add ability for the Trie to snapshot current root (#214)
* Add ability for the Trie to snapshot current root

* Allow ability to empty/drop database
2018-09-06 17:22:30 +02:00
Jaco Greeff ca6934b6cf Bump LRU sizes 2018-09-05 11:57:54 +02:00
Jaco Greeff 5120b95bc8 FlatDb code refactor & optimisations (#213)
* Move Compactor into own class

* Combine multiple buffer writes

* Skip failing CI test (again)

* Clean up value > current.length

* Test code linting
2018-09-04 22:54:13 +02:00
Jaco Greeff 0b5d6bfb60 FlatDb LRU for data (key & value) 2018-09-04 10:49:25 +02:00
Jaco Greeff 385db9ef25 Cleanup FlatDb branching logic (re-use) 2018-09-03 20:02:14 +02:00
Jaco Greeff 4655726c92 Cleanup variable assignments (FlatDb) 2018-09-03 17:21:00 +02:00
Jaco Greeff 177824d356 Expand FlatDb tests 2018-09-03 16:55:32 +02:00
Jaco Greeff 1f6d7bb118 Debug with correct position 2018-09-03 16:39:34 +02:00
Jaco Greeff a9ee22bf08 Cleanup Flat return types 2018-09-03 16:30:55 +02:00
Jaco Greeff f32ea5b40f LRU for branches (96-bytes, more re-usable) (#212) 2018-09-03 16:01:15 +02:00
Jaco Greeff dfa1d25ff5 LRU for header entries (#211)
* LRU for header entries

* Update LRU cache size

* Update caching offsets (branch re-org)

* Re-skip test

* Mark LevelDb as unused, move
2018-09-03 15:07:07 +02:00
Jaco Greeff fd216c4f05 Manage FlatDb index explosion (branch on nibbles) (#210) 2018-09-03 13:23:05 +02:00
Jaco Greeff 67895df61b isCompressed option to database 2018-09-03 12:10:07 +02:00
Jaco Greeff 081246fa0c LevelDb string serialization of keys & values (#209)
* Remove RocksDb interface (or rather, mark as unused)

* LevelDb de/serializes to utf8
2018-09-03 09:56:12 +02:00
Jaco Greeff f9da5249ca Add RocksDb interface (#208)
* Add RocksDb interface

* Move binary deps to optional

* LevelDb skip

* Travis config for rocksdb

* Use pushd to change directory

* Don't forget to run yarn

* CFLAGS for gcc?

* Library should compress

* Update dependencies
2018-09-02 20:04:34 +02:00
Jaco Greeff 5fdf2f4680 Create base directory only (not full with file) 2018-09-02 11:15:14 +02:00
Jaco Greeff 3b6407f9b7 LevelDb interface update (#207)
* LevelDb interface update

* Update disk interfaces to base + name
2018-09-02 11:00:39 +02:00
Jaco Greeff 9dc836d061 Swap default backing DB to FileFlat (interim) 2018-09-02 00:35:52 +02:00
Jaco Greeff fbbcc2d92d Fix Transaction open/close reversal 2018-09-01 23:28:34 +02:00
Jaco Greeff 130163b74e Trie implements TxDb interface fully 2018-09-01 22:44:45 +02:00
Jaco Greeff e1135a665b Re-implementation of Patricia-Merkle Trie (#203)
* Start of trie-db re-implementation

* WIP commit

* More WIP

* WIP, seems complete, untested

* Ported trie-db operational

* Add Ethereum trie tests

* Use u8aConcat to construct u8a

* Basic RocksDb interface

* Combine engines into DB, expand tests

* Update Trie with transaction wrapper

* LevelDb (sync) interface

* Remove unused (for now) package (compatibility)

* trie-d -> trie-db-old, trie-db-ext -> trie-db

* Version bump

* Skip old trie tests (package to be removed)

* Skip tests (fixed)

* Remove non-used RocksDb spec

* Skip FileFlat tests (deprecated?)
2018-09-01 22:17:57 +02:00