Compare commits

..

54 Commits

Author SHA1 Message Date
Richard Holland
f914365c3f tagged cache reversion 2025-04-01 16:31:38 +11:00
Richard Holland
7e8436cb50 return rpc error instead of continuing when ledger header isn't read 2025-04-01 13:04:45 +11:00
RichardAH
0e19a4034d Merge branch 'dev' into catalogue 2025-04-01 11:52:43 +10:00
Richard Holland
fa640624f0 remove redundant setLedgerRangePresent 2025-04-01 12:51:59 +11:00
Richard Holland
bbdad4b2da change stream flushing to be byte-based 2025-04-01 12:48:43 +11:00
Richard Holland
58eb1b53f6 use proper close time on construction 2025-04-01 12:12:42 +11:00
Richard Holland
10b5507edd check the loaded ledger hash against computed 2025-04-01 12:10:45 +11:00
Richard Holland
626c8c06e0 debug builds 2025-03-31 12:38:20 +11:00
Richard Holland
b1086d6577 remove old friendclass ref 2025-03-28 15:43:03 +11:00
Richard Holland
f3cce20ea8 finish catalogue tests (good enough) 2025-03-28 15:32:49 +11:00
Richard Holland
334f380262 debug unit tests / fix serder polymorphism issue with templates 2025-03-28 15:11:51 +11:00
Richard Holland
065a94909f improved tests, fix template constexpr in getledger, some tests still failing 2025-03-26 16:37:59 +11:00
Richard Holland
06a9ce4f33 ensure pinned ledger range is updated as catalogue_load progresses 2025-03-25 14:55:37 +11:00
Richard Holland
af3d6bb421 mem leak 2025-03-24 21:35:46 +11:00
Richard Holland
24a9539095 add estimated remaining time to catalogue status 2025-03-24 13:04:35 +11:00
Richard Holland
f01364180b simplify compression_level json 2025-03-24 12:37:55 +11:00
Richard Holland
525dcc7e20 add filesize and hash to catalogue format/header. compiling not tested 2025-03-24 11:32:29 +11:00
Richard Holland
c5d298d6e8 add compression (untested) fix some build system issues 2025-03-23 14:22:54 +11:00
Richard Holland
63077ac753 fix for pinning 2025-03-21 16:31:41 +11:00
Richard Holland
e378ecb385 add ledger pinning 2025-03-14 14:17:34 +11:00
RichardAH
6f343f5d5e Merge branch 'dev' into catalogue 2025-03-14 10:25:00 +10:00
Richard Holland
a8f411d715 more cleanup 2025-03-07 10:56:50 +11:00
Richard Holland
5caa1cd472 clean up test cases 2025-03-07 10:51:28 +11:00
Richard Holland
c1d097f868 refactor to remove catalogue processor class 2025-03-07 10:26:02 +11:00
Richard Holland
7c33592a26 clean up debug logging 2025-03-06 14:14:11 +11:00
Richard Holland
008a0f78de workinggit add -u 2025-03-06 13:54:31 +11:00
Richard Holland
78bd570016 more debugging, getting closer 2025-03-05 23:08:59 +11:00
Richard Holland
b2d30104d4 ensure close times are serialized correctly 2025-03-05 22:15:14 +11:00
Richard Holland
76ffbffcd6 whoops. compiling and no longer crashes, more debugging to get ripple.rpc.Catalogue to pass 2025-03-05 20:56:17 +11:00
Richard Holland
a6f2f9f27a move away from using bare pointers, use Ledger const references where possible 2025-03-05 20:51:16 +11:00
Richard Holland
ac48b5a4dd move serder functionality into shamap class, rewrite format to be streaming friendly 2025-03-05 18:36:50 +11:00
Richard Holland
f5660c4d7d skiplist recalculation is unnecessary and breaking 2025-03-03 13:24:44 +11:00
Richard Holland
d7970346ae fix ledger drops, more debugging 2025-03-03 12:57:08 +11:00
Richard Holland
ea3ec6e532 reintroduce closeflags hack, close to working now 2025-03-03 12:09:44 +11:00
Richard Holland
589de50202 closer to working 2025-03-02 16:06:19 +11:00
Richard Holland
5aa15f0ddc better debugging/logging and FeatureBitset support 2025-03-02 14:42:51 +11:00
Richard Holland
55a94c400e change to serializeforwire 2025-03-02 12:30:16 +11:00
Richard Holland
90c2726cbd change approach to lower abstraction level using direct shamap nodes 2025-03-02 11:59:38 +11:00
Richard Holland
21d164b23b fix close flags (hacky) and more debug 2025-02-24 18:54:16 +11:00
Richard Holland
3a7e59c077 debugging 2025-02-19 18:59:32 +11:00
Richard Holland
5c4b1a8ce8 add first version of test suite 2025-02-19 11:59:09 +11:00
Richard Holland
6ebecd193b fix incorrect reapplication of old history when loading ledgers 2025-02-17 16:21:57 +11:00
Richard Holland
80cf986036 add debugging output to catalogue load 2025-02-17 16:04:36 +11:00
Richard Holland
99ebfd52ac first attempt at fixing catalogue_load 2025-02-17 15:27:06 +11:00
Richard Holland
a2a764fb16 clean up writing logic, appears to be correct now in preliminary testing 2025-02-17 15:06:10 +11:00
Richard Holland
de455e52e8 still debugging state writing 2025-02-17 14:17:34 +11:00
Richard Holland
84942ce125 more write debug 2025-02-17 13:58:25 +11:00
Richard Holland
1a8173f3df debug ledger seq 2025-02-17 13:23:28 +11:00
Richard Holland
4c39910576 revise parallel strat 2025-02-17 12:52:01 +11:00
Richard Holland
c2434e74a1 rework of loading routine, not compiling 2025-02-16 20:15:33 +11:00
Richard Holland
4327f06152 parallel creation 2025-02-16 17:46:05 +11:00
Richard Holland
250fedf45f code complete, compiling untested 2025-02-16 17:12:29 +11:00
Richard Holland
16b90fa826 fix bug add better rpc msg 2025-02-16 15:09:57 +11:00
Richard Holland
96be5cc0b0 first half of catalogue, untested compiling 2025-02-16 14:21:57 +11:00

View File

@@ -18,9 +18,7 @@
//==============================================================================
#include <ripple/app/ledger/Ledger.h>
#include <ripple/app/ledger/LedgerMaster.h>
#include <ripple/app/ledger/LedgerToJson.h>
#include <ripple/app/main/Application.h>
#include <ripple/app/tx/apply.h>
#include <ripple/basics/Log.h>
#include <ripple/basics/Slice.h>
@@ -551,8 +549,9 @@ doCatalogueCreate(RPC::JsonContext& context)
UPDATE_CATALOGUE_STATUS(ledgerUpto, min_ledger);
// Load the first ledger
if (auto error = RPC::getLedger(currLedger, min_ledger, context))
return rpcError(error.toErrorCode(), error.message());
auto status = RPC::getLedger(currLedger, min_ledger, context);
if (status.toErrorCode() != rpcSUCCESS)
return rpcError(status);
if (!currLedger)
return rpcError(rpcLEDGER_MISSING);
@@ -576,8 +575,9 @@ doCatalogueCreate(RPC::JsonContext& context)
// Load the next ledger
currLedger = nullptr; // Release any previous current ledger
if (auto error = RPC::getLedger(currLedger, ledger_seq, context))
return rpcError(error.toErrorCode(), error.message());
auto status = RPC::getLedger(currLedger, ledger_seq, context);
if (status.toErrorCode() != rpcSUCCESS)
return rpcError(status);
if (!currLedger)
return rpcError(rpcLEDGER_MISSING);