Get ledger acquire work off the main thread and out of the master lock.

Prioritize ledger acquire work appripriately. This should help prevent the
server from becoming overly sluggish while acquiring ledgers. Still todo:
Finish all pending receive operations before sending out any data requests.
This commit is contained in:
JoelKatz
2013-03-15 22:34:55 -07:00
parent 7a76cfe7da
commit e392366c63
6 changed files with 45 additions and 30 deletions

View File

@@ -25,16 +25,17 @@ enum JobType
jtVALIDATION_ut = 2, // A validation from an untrusted source
jtPROOFWORK = 3, // A proof of work demand from another server
jtPROPOSAL_ut = 4, // A proposal from an untrusted source
jtCLIENT = 5, // A websocket command from the client
jtTRANSACTION = 6, // A transaction received from the network
jtPUBLEDGER = 7, // Publish a fully-accepted ledger
jtWAL = 8, // Write-ahead logging
jtVALIDATION_t = 9, // A validation from a trusted source
jtWRITE = 10, // Write out hashed objects
jtTRANSACTION_l = 11, // A local transaction
jtPROPOSAL_t = 12, // A proposal from a trusted source
jtADMIN = 13, // An administrative operation
jtDEATH = 14, // job of death, used internally
jtLEDGER_DATA = 5, // Received data for a ledger we're acquiring
jtCLIENT = 6, // A websocket command from the client
jtTRANSACTION = 7, // A transaction received from the network
jtPUBLEDGER = 8, // Publish a fully-accepted ledger
jtWAL = 9, // Write-ahead logging
jtVALIDATION_t = 10, // A validation from a trusted source
jtWRITE = 11, // Write out hashed objects
jtTRANSACTION_l = 12, // A local transaction
jtPROPOSAL_t = 13, // A proposal from a trusted source
jtADMIN = 14, // An administrative operation
jtDEATH = 15, // job of death, used internally
// special types not dispatched by the job pool
jtPEER = 24,