Commit graph

61 commits

Author SHA1 Message Date
Brandon Dahler
b64187d05f Rename leveldb.{h,cpp} to leveldbwrapper.{h,cpp}. 2013-11-08 18:03:46 -06:00
Pieter Wuille
85eb2cef33 Do not use the redundant BestInvalidWork record in the block database.
As block index entries have a flag for marking invalid blocks, the
'best invalid work' information can be derived from there. In addition,
remove the global from main.h
2013-11-01 00:54:28 +01:00
super3
db0e8ccd90 Bump Year Number to 2013 2013-10-20 15:25:06 -04:00
Gavin Andresen
cc67f1e2b4 Merge pull request #2221 from sipa/perfo
Various performance tweaks to CCoinsView
2013-02-22 09:01:30 -08:00
Pieter Wuille
8fdc94cc8f Rename database directories 2013-01-28 21:08:05 +01:00
Pieter Wuille
f369d02c51 Various performance tweaks to CCoinsView
* Pass txid's to CCoinsView functions by reference instead of by value
* Add a method to swap CCoins, and use it in some places to avoid a
  allocating copy + destruct.
* Optimize CCoinsViewCache::FetchCoins to do only a single search
  through the backing map.
2013-01-26 18:46:12 +01:00
Pieter Wuille
2d1fa42e85 Add optional transaction index to databases
By specifying -txindex when initializing the database, a txid-to-diskpos
index is maintained in the blktree database. This database is used to
help answering getrawtransaction() RPC queries, when enabled.

Changing the -txindex value requires a -reindex; the client will abort
at startup if the database and the specified -txindex mismatch.
2013-01-18 14:39:11 +01:00
Pieter Wuille
7fea484674 Add -reindex, to perform in-place reindexing of block chain files
Flushes the blktree/ and coins/ databases, and reindexes the
block chain files, as if their contents was loaded via -loadblock.

Based on earlier work by Jeff Garzik.
2012-11-09 01:06:32 +01:00
Pieter Wuille
1c83b0a377 Cache size optimizations 2012-11-04 18:06:25 +01:00
Pieter Wuille
4ca60bba5c Remove BDB block database support 2012-10-20 23:08:57 +02:00
Pieter Wuille
2d8a48292b LevelDB block and coin databases
Split off CBlockTreeDB and CCoinsViewDB into txdb-*.{cpp,h} files,
implemented by either LevelDB or BDB.

Based on code from earlier commits by Mike Hearn in his leveldb
branch.
2012-10-20 23:08:57 +02:00