Jim Posen
f5c003d3ea
[test] Add test for NODE_COMPACT_FILTER.
...
Test that a node configured to serve compact filters will signal
NODE_COMPACT_FILTER service bit.
2020-05-31 23:01:13 -04:00
Jim Posen
132b30d9c8
[net] Signal NODE_COMPACT_FILTERS if we're serving compact filters.
...
If -peerblockfilters is configured, signal the NODE_COMPACT_FILTERS service
bit to indicate that we are able to serve compact block filters, headers
and checkpoints.
2020-05-31 23:01:06 -04:00
Jim Posen
9e36067d8c
[test] Add test for cfilters.
2020-05-26 17:38:26 -04:00
Jim Posen
11106a4722
[net processing] Message handling for getcfilters.
...
Handle getcfilters request if -peercfilter is configured.
2020-05-26 17:38:20 -04:00
Jim Posen
e535670726
[indexes] Fix default [de]serialization of BlockFilter.
...
This only changes network serialization. Disk serialization does not
include the filter_type and is defined in
ReadFilterFromDisk()/WriteFilterToDisk().
2020-05-26 17:27:15 -04:00
Jim Posen
5308c97cca
[test] Add test for cfheaders
2020-05-22 11:59:58 -04:00
Jim Posen
f6b58c1506
[net processing] Message handling for getcfheaders.
...
if -peerblockfilters is configured, handle requests for cfheaders.
2020-05-22 11:59:58 -04:00
Jim Posen
23083856a5
[test] Add test for cfcheckpt
2020-05-08 16:36:19 -04:00
Jim Posen
f9e00bb25a
[net processing] Message handling for getcfcheckpt.
...
If -peerblockfilters is configured, handle requests for cfcheckpt.
2020-05-08 16:36:19 -04:00
Jim Posen
9ccaaba11e
[init] Add -peerblockfilters option
...
When a node is configured with --blockfilterindex=basic and
-peerblockfilters it can serve compact block filters to its peers.
This commit adds the configuration option handling. Future commits
add compact block serving and service bits signaling.
2020-05-08 16:36:18 -04:00
Jim Posen
9dd58ca611
init: Stop indexes on shutdown after ChainStateFlushed callback.
...
Currently, the latest index state may not be committed to disk on shutdown.
2020-01-09 19:46:57 -05:00
Jim Posen
f59bbb61af
test: Fix bug in blockfilter_index_tests.
...
The test case tests a chain reorganization, however the two
chains were generated in the same manner and thus produced
the same blocks.
2019-10-14 22:04:19 +02:00
Jim Posen
c7efb652f3
blockfilter: Update BIP 158 test vectors.
...
New tests for the case of non-standard OP_RETURN outputs.
2019-04-06 12:10:55 -07:00
Jim Posen
19308c9e21
rpc: Add getblockfilter RPC method.
...
Retrieves and returns block filter and header from index.
2019-04-06 12:10:55 -07:00
Jim Posen
ff35105096
init: Add CLI option to enable block filter index.
2019-04-06 12:10:55 -07:00
Jim Posen
accc8b8b18
index: Access functions for global block filter indexes.
2019-04-06 12:10:55 -07:00
Jim Posen
2bc90e4e7b
test: Unit test for block filter index reorg handling.
2019-04-06 12:10:22 -07:00
Jim Posen
6bcf0998c0
test: Unit tests for block index filter.
2019-04-06 12:10:22 -07:00
Jim Posen
b5e8200db7
index: Implement lookup methods on block filter index.
2019-04-06 12:10:22 -07:00
Jim Posen
75a76e3619
index: Implement block filter index with write operations.
2019-04-06 12:10:22 -07:00
Jim Posen
2ad2338ef9
serialize: Serialization support for big-endian 32-bit ints.
2019-04-06 12:03:21 -07:00
Jim Posen
ba6ff9a6f7
blockfilter: Functions to translate filter types to/from names.
2019-04-06 12:03:21 -07:00
Jim Posen
62b7a4f094
index: Ensure block locator is not stale after chain reorg.
2019-04-06 12:03:21 -07:00
Jim Posen
4368384f1d
index: Allow atomic commits of index state to be extended.
2019-04-06 12:03:21 -07:00
Jim Posen
04cca33094
Style cleanup.
2019-02-22 17:38:45 -08:00
Jim Posen
4c01e4e159
flatfile: Unit tests for FlatFileSeq methods.
2019-02-22 17:38:45 -08:00
Jim Posen
65a489e93d
scripted-diff: Rename CBlockDiskPos to FlatFilePos.
...
-BEGIN VERIFY SCRIPT-
sed -i 's/CDiskBlockPos/FlatFilePos/g' $(git ls-files 'src/*.h' 'src/*.cpp')
-END VERIFY SCRIPT-
2019-02-22 17:38:45 -08:00
Jim Posen
d6d8a78f26
Move CDiskBlockPos from chain to flatfile.
2019-02-22 17:38:45 -08:00
Jim Posen
e0380933e3
validation: Refactor file flush logic into FlatFileSeq.
2019-02-22 17:38:45 -08:00
Jim Posen
992404b31e
validation: Refactor block file pre-allocation into FlatFileSeq.
2019-02-22 17:38:45 -08:00
Jim Posen
e2d2abb99f
validation: Refactor OpenDiskFile into method on FlatFileSeq.
2019-02-22 17:38:45 -08:00
Jim Posen
9183d6ef65
validation: Extract basic block file logic into FlatFileSeq class.
2019-02-22 17:38:45 -08:00
Jim Posen
62e7addb63
util: Move CheckDiskSpace to util.
2019-02-22 17:38:45 -08:00
Jim Posen
e4ed8ce2c8
blockfilter: Remove default clause in switch statement.
...
Now the compiler will warn if not all enums are handled in the
switch.
2018-12-21 23:53:29 -06:00
Jim Posen
c30620983d
blockfilter: Additional constructors for BlockFilter.
2018-11-06 09:12:54 -08:00
Jim Posen
20b812993a
blockfilter: Refactor GCS params into struct.
2018-11-06 09:12:54 -08:00
Jim Posen
fef5adcc33
blockfilter: Use unordered_set instead of set in blockfilter.
2018-11-05 09:30:56 -08:00
Jim Posen
4fb789e9b2
Extract CSipHasher to it's own file in crypto/ directory.
...
This is a move-only commit with the exception of changes to includes.
2018-11-05 09:25:15 -08:00
Jim Posen
2068f089c8
scripted-diff: Move util files to separate directory.
...
-BEGIN VERIFY SCRIPT-
mkdir -p src/util
git mv src/util.h src/util/system.h
git mv src/util.cpp src/util/system.cpp
git mv src/utilmemory.h src/util/memory.h
git mv src/utilmoneystr.h src/util/moneystr.h
git mv src/utilmoneystr.cpp src/util/moneystr.cpp
git mv src/utilstrencodings.h src/util/strencodings.h
git mv src/utilstrencodings.cpp src/util/strencodings.cpp
git mv src/utiltime.h src/util/time.h
git mv src/utiltime.cpp src/util/time.cpp
sed -i 's/<util\.h>/<util\/system\.h>/g' $(git ls-files 'src/*.h' 'src/*.cpp')
sed -i 's/<utilmemory\.h>/<util\/memory\.h>/g' $(git ls-files 'src/*.h' 'src/*.cpp')
sed -i 's/<utilmoneystr\.h>/<util\/moneystr\.h>/g' $(git ls-files 'src/*.h' 'src/*.cpp')
sed -i 's/<utilstrencodings\.h>/<util\/strencodings\.h>/g' $(git ls-files 'src/*.h' 'src/*.cpp')
sed -i 's/<utiltime\.h>/<util\/time\.h>/g' $(git ls-files 'src/*.h' 'src/*.cpp')
sed -i 's/BITCOIN_UTIL_H/BITCOIN_UTIL_SYSTEM_H/g' src/util/system.h
sed -i 's/BITCOIN_UTILMEMORY_H/BITCOIN_UTIL_MEMORY_H/g' src/util/memory.h
sed -i 's/BITCOIN_UTILMONEYSTR_H/BITCOIN_UTIL_MONEYSTR_H/g' src/util/moneystr.h
sed -i 's/BITCOIN_UTILSTRENCODINGS_H/BITCOIN_UTIL_STRENCODINGS_H/g' src/util/strencodings.h
sed -i 's/BITCOIN_UTILTIME_H/BITCOIN_UTIL_TIME_H/g' src/util/time.h
sed -i 's/ util\.\(h\|cpp\)/ util\/system\.\1/g' src/Makefile.am
sed -i 's/utilmemory\.\(h\|cpp\)/util\/memory\.\1/g' src/Makefile.am
sed -i 's/utilmoneystr\.\(h\|cpp\)/util\/moneystr\.\1/g' src/Makefile.am
sed -i 's/utilstrencodings\.\(h\|cpp\)/util\/strencodings\.\1/g' src/Makefile.am
sed -i 's/utiltime\.\(h\|cpp\)/util\/time\.\1/g' src/Makefile.am
sed -i 's/-> util ->/-> util\/system ->/' test/lint/lint-circular-dependencies.sh
sed -i 's/src\/util\.cpp/src\/util\/system\.cpp/g' test/lint/lint-format-strings.py test/lint/lint-locale-dependence.sh
sed -i 's/src\/utilmoneystr\.cpp/src\/util\/moneystr\.cpp/g' test/lint/lint-locale-dependence.sh
sed -i 's/src\/utilstrencodings\.\(h\|cpp\)/src\/util\/strencodings\.\1/g' test/lint/lint-locale-dependence.sh
sed -i 's/src\\utilstrencodings\.cpp/src\\util\\strencodings\.cpp/' build_msvc/libbitcoinconsensus/libbitcoinconsensus.vcxproj
-END VERIFY SCRIPT-
2018-11-04 22:46:07 -08:00
Jim Posen
f05599557a
blockfilter: Omit empty scripts from filter contents.
...
Code change also avoids out-of-bounds script access bug.
2018-08-28 12:12:32 -07:00
Jim Posen
ed12d5df1b
index: Fix for indexers skipping genesis block.
2018-08-27 17:03:24 -07:00
Jim Posen
254c85b687
bench: Benchmark GCS filter creation and matching.
2018-08-25 10:02:37 -07:00
Jim Posen
f33b717a85
blockfilter: Optimization on compilers with int128 support.
2018-08-25 10:02:37 -07:00
Jim Posen
ec3073a274
index: Move index DBs into index/ directory.
2018-06-04 19:22:30 -07:00
Jim Posen
89eddcd365
index: Remove TxIndexDB from public interface of TxIndex.
2018-06-04 19:22:28 -07:00
Jim Posen
2318affd27
MOVEONLY: Move BaseIndex to its own file.
2018-06-04 19:22:26 -07:00
Jim Posen
f376a49241
index: Generalize logged statements in BaseIndex.
2018-06-04 19:22:24 -07:00
Jim Posen
61a1226d87
index: Extract logic from TxIndex into reusable base class.
2018-06-04 19:22:23 -07:00
Jim Posen
e5af5fc6fb
db: Make reusable base class for index databases.
2018-06-04 19:22:21 -07:00
Jim Posen
9b0ec1a7f9
db: Remove obsolete methods from CBlockTreeDB.
2018-06-04 19:22:20 -07:00