Commit Graph

281 Commits

Author SHA1 Message Date
Riccardo Spagni 8005a0c7a1 Merge pull request #269
641d824 Keep memory pool consistent when stuck tx removed (warptangent)
b76857f Add mempool output to daemon via command and RPC (warptangent)
2015-05-06 08:09:31 +02:00
Thomas Winget 385d7c0495 Sort txs by per-kb-fee for miners 2015-04-30 01:02:12 -04:00
Thomas Winget 1b2614ba83 When removing 'stuck' transactions, don't ignore the first tx in the pool 2015-04-30 00:23:00 -04:00
warptangent 641d824f37 Keep memory pool consistent when stuck tx removed
When a stuck tx is removed from memory pool, first remove the associated
spent key images.
2015-04-23 07:04:36 -07:00
warptangent b76857f9d9 Add mempool output to daemon via command and RPC
This is for the "print_pool" command and "get_transaction_pool" RPC
method.

Add mempool's spent key images to the results.
2015-04-23 07:04:36 -07:00
Thomas Winget 2717883dba DNS Checkpoint updating-related fixes/changes
Only one thread will be doing the updating.

Two valid responses must match, and the first two that match will be
used.
2015-04-22 04:36:39 -04:00
Thomas Winget ae08be5394 Disable DNS checkpoint updating on testnet 2015-04-08 18:07:46 -04:00
Thomas Winget a8bc7182ea Merge BlockchainDB into upstream 2015-04-07 17:56:18 -04:00
Thomas Winget 9519526224 Only compile BerkeleyDB as an option in non-static 2015-04-07 15:02:20 -04:00
Javier Smooth 83ddc942c1 handle unlikely rounding up after sqrt 2015-04-05 04:39:09 -07:00
Javier Smooth f2e8348be0 triangular distribution to choose recent outputs more often for mixins 2015-04-05 04:01:00 -07:00
rfree2monero c511abf005 remerged; commands JSON. logging upgrade. doxygen 2015-04-01 19:00:45 +02:00
rfree2monero 3cbdf198f1 Merge remote-tracking branch 'monero-official/master' into network-1.6-work1 2015-04-01 18:24:45 +02:00
Thomas Winget 94cb295db4 Merge upstream into blockchain 2015-03-29 09:58:18 -04:00
Riccardo Spagni 65d6d36449 Merge pull request #244
e6740ee Enforce DNSSEC for checkpoint updates (Thomas Winget)
dbf46a7 DNSSEC added (hardcoded key) (Thomas Winget)
2015-03-26 13:50:06 +02:00
Riccardo Spagni c1187fabcf Merge pull request #242
b43716c Do store transaction's blob size in transaction_chain_entry (Sergey Kazenyuk)
3be518f Use single get_transaction_hash to get both id and blob size (Sergey Kazenyuk)
2015-03-26 13:47:36 +02:00
Thomas Winget 7b14d4a17f Steps toward multiple dbs available -- working
There will need to be some more refactoring for these changes to be
considered complete/correct, but for now it's working.

new daemon cli argument "--db-type", works for LMDB and BerkeleyDB.

A good deal of refactoring is also present in this commit, namely
Blockchain no longer instantiates BlockchainDB, but rather is passed a
pointer to an already-instantiated BlockchainDB on init().
2015-03-25 12:09:44 -04:00
Thomas Winget 5c0bc0050c Merge upstream updates into blockchain branch 2015-03-25 05:56:36 -04:00
Thomas Winget e6740ee103 Enforce DNSSEC for checkpoint updates 2015-03-24 06:59:38 -04:00
Thomas Winget 8855a32044 Merge upstream to daemonize changes
Preparation for PR
2015-03-24 02:47:15 -04:00
warptangent 4bedd68d2c Update Blockchain::get_db() to return reference instead of pointer
Where this method is used, a BlockchainDB object is always expected, so
a pointer is unnecessary and less safe.
2015-03-22 15:45:36 -07:00
warptangent 275cbd4348 Add support for database open with flags
Add support to:
  - BlockchainDB, BlockchainLMDB
  - blockchain_import utility to open LMDB database with one or more
    LMDB flags.

Sample use:
  $ blockchain_import --database lmdb#nosync
  $ blockchain_import --database lmdb#nosync,nometasync
2015-03-16 00:26:59 -07:00
warptangent ca75b4789c Blockchain: add get_db() accessor, needed for blockchain_import
This handling may be changed in the future.
2015-03-15 13:22:52 -07:00
Sergey Kazenyuk b43716c756 Do store transaction's blob size in transaction_chain_entry 2015-03-15 04:35:34 +03:00
Sergey Kazenyuk 3be518ff40 Use single get_transaction_hash to get both id and blob size 2015-03-15 04:33:34 +03:00
Thomas Winget eee3ee7073 BlockchainDB implementations have names now
In order to make things more general, BlockchainDB now has get_db_name()
which should return a string with the "name" of that type of db.
This "name" will be the subfolder name that holds that db type's files
within the monero folder.

Small bugfix: blockchain_converter was not correctly appending this in
the prior hard-coded-string implementation of the subfolder data
directory concept.
2015-03-13 21:39:27 -04:00
Thomas Winget 5eab480cb1 Moved BlockchainDB into its own src/ subfolder
Ostensibly janitorial work, but should be more relevant later down the
line.  Things that depend on core cryptonote things (i.e.
    cryptonote_core) don't necessarily depend on BlockchainDB and thus
have no need to have BlockchainDB baked in with them.
2015-03-06 15:20:45 -05:00
smooth 7e72e943db update checkpoint 2015-03-06 02:38:06 -08:00
smooth 41a95e7b11 add comment about avoiding overflow 2015-03-05 00:45:54 -08:00
smooth 754a785ee1 minimum subsidy for mining incentives, remove unused LEGACY_FEE define 2015-03-04 23:35:04 -08:00
Thomas Winget 9dab105e2e DNS checkpoint loading for testnet should now be correct 2015-03-01 03:36:46 -05:00
Thomas Winget 96cbecffd7 RPC calls for background daemon added in
The RPC calls the daemon executable uses to talk to the running daemon
instance have mostly been added back in.  Rate limiting has not been
added in upstream, but is on its way in a separate effort, so those
calls are still NOPed out.
2015-02-24 00:44:36 -05:00
Thomas Winget 9193d6fb5b Daemonize changes pulled in -- daemon builds
many RPC functions added by the daemonize changes
(and related changes on the upstream dev branch that were not merged)
were commented out (apart from return).  Other than that, this *should*
work...at any rate, it builds, and that's something.
2015-02-24 00:05:19 -05:00
Thomas Winget 0ad0784f46 Changed log level of debug message -- too spammy 2015-02-23 18:28:20 -05:00
warptangent 6485dacc2f BlockchainLMDB: Add profiling to tx_exists() 2015-02-23 00:33:39 -08:00
warptangent 83fb6d8d07 BlockchainLMDB: Add batch transaction support to tx_exists() 2015-02-23 00:33:38 -08:00
warptangent 8529c0ea9a BlockchainDB, BlockchainLMDB: Add profiling for DB commits 2015-02-23 00:33:38 -08:00
warptangent 7a66b8bbcf BlockchainDB: Add virtual function declarations for batch transactions 2015-02-23 00:33:38 -08:00
warptangent b7a2d84919 BlockchainLMDB: Add check for open database to two functions 2015-02-23 00:33:38 -08:00
warptangent 58ecc58be1 BlockchainLMDB: Add support for batch transactions 2015-02-23 00:33:37 -08:00
warptangent 8909d7d82e Improve block and tx processing efficiency by less repeat hashing
BlockchainLMDB::add_block()
  BlockchainLMDB::add_transaction_data()

  BlockchainDB::add_transaction()
2015-02-23 00:33:37 -08:00
warptangent 3676ac5841 Add profiling to block and tx processing 2015-02-23 00:33:37 -08:00
warptangent ce71abd0fe Move LMDB storage to subfolder 2015-02-23 00:33:37 -08:00
warptangent 42f8fe5c7f Fix formatting 2015-02-23 00:33:36 -08:00
warptangent aa82f786c7 Fix log statement 2015-02-23 00:33:36 -08:00
warptangent 26873db199 Remove unused variable 2015-02-23 00:33:36 -08:00
warptangent 4b90fd389d Add log statement 2015-02-23 00:33:36 -08:00
warptangent 2531aa31f8 Add and extend log statements 2015-02-23 00:33:35 -08:00
warptangent 59305d3137 Blockchain: match original function declaration from blockchain_storage 2015-02-23 00:33:35 -08:00
warptangent b88ab643ca Fix Blockchain::get_tail_id() to set parameter to last block number instead of height
This reflects the behavior of blockchain_storage::get_tail_id().

Fixes #27 so that RPC method getlastblockheader works.
2015-02-22 10:41:41 -08:00