aboutsummaryrefslogtreecommitdiff
path: root/tests/unit_tests/blockchain_db.cpp (follow)
AgeCommit message (Collapse)AuthorFilesLines
2020-05-06Update copyright year to 2020SomaticFanatic1-1/+1
Update copyright year to 2020
2019-09-16Removed Berkeley DB and db switching logicJesus Ramirez1-8/+1
2019-07-01unit_tests: check return values on test data parsingmoneromooo-monero1-2/+2
Won't trigger in practice, but you never know when that code changes Coverity 199723, 199685
2019-04-14blockchain_db: fix db txn ending too earlymoneromooo-monero1-0/+4
The db txn in add_block ending caused the entire overarching batch txn to stop. Also add a new guard class so a db txn can be stopped in the face of exceptions. Also use a read only db txn in init when the db itself is read only, and do not save the max tx size in that case.
2019-03-05Update 2019 copyrightbinaryFate1-1/+1
2019-03-05Avoid repeated (de)serialization when syncingmoneromooo-monero1-15/+15
2019-03-04ArticMine's new block weight algorithmmoneromooo-monero1-6/+6
This curbs runaway growth while still allowing substantial spikes in block weight Original specification from ArticMine: here is the scaling proposal Define: LongTermBlockWeight Before fork: LongTermBlockWeight = BlockWeight At or after fork: LongTermBlockWeight = min(BlockWeight, 1.4*LongTermEffectiveMedianBlockWeight) Note: To avoid possible consensus issues over rounding the LongTermBlockWeight for a given block should be calculated to the nearest byte, and stored as a integer in the block itself. The stored LongTermBlockWeight is then used for future calculations of the LongTermEffectiveMedianBlockWeight and not recalculated each time. Define: LongTermEffectiveMedianBlockWeight LongTermEffectiveMedianBlockWeight = max(300000, MedianOverPrevious100000Blocks(LongTermBlockWeight)) Change Definition of EffectiveMedianBlockWeight From (current definition) EffectiveMedianBlockWeight = max(300000, MedianOverPrevious100Blocks(BlockWeight)) To (proposed definition) EffectiveMedianBlockWeight = min(max(300000, MedianOverPrevious100Blocks(BlockWeight)), 50*LongTermEffectiveMedianBlockWeight) Notes: 1) There are no other changes to the existing penalty formula, median calculation, fees etc. 2) There is the requirement to store the LongTermBlockWeight of a block unencrypted in the block itself. This is to avoid possible consensus issues over rounding and also to prevent the calculations from becoming unwieldy as we move away from the fork. 3) When the EffectiveMedianBlockWeight cap is reached it is still possible to mine blocks up to 2x the EffectiveMedianBlockWeight by paying the corresponding penalty. Note: the long term block weight is stored in the database, but not in the actual block itself, since it requires recalculating anyway for verification.
2018-09-11v8: per byte fee, pad bulletproofs, fixed 11 ring sizemoneromooo-monero1-1/+1
2018-01-26Update 2018 copyrightxmr-eric1-1/+1
2017-12-16move includes around to lessen overall loadmoneromooo-monero1-0/+1
2017-03-29Replace deprecated tmpnam function.Randi Joseph1-10/+16
2017-02-21update copyright year, fix occasional lack of newline at line endRiccardo Spagni1-1/+1
2017-02-14unit_tests: fix minor blockchain_db regressionmoneromooo-monero1-1/+1
Due to the change in ordering for adding block and tx data to the database in f2986ccfc1f41023cd667dbb488a10df492eb8e7, adding a block twice now throws TX_EXISTS, not BLOCK_EXISTS.
2017-02-08extract some basic code from libcryptonote_core into libcryptonote_basickenshi841-1/+1
2016-02-08unit_tests: fix blockchain unit test after hard fork import fixmoneromooo-monero1-1/+10
2015-12-31updated copyright yearRiccardo Spagni1-1/+1
2015-11-03unit_tests: fix build without berkeleydbmoneromooo-monero1-1/+7
2015-05-31cleaning up, removing redundant files, renaming, fixing incorrect licensesRiccardo Spagni1-0/+325