22#include "data/BackendInterface.hpp"
24#include "etl/impl/LedgerLoader.hpp"
25#include "etlng/AmendmentBlockHandlerInterface.hpp"
26#include "etlng/InitialLoadObserverInterface.hpp"
27#include "etlng/LoaderInterface.hpp"
28#include "etlng/Models.hpp"
29#include "etlng/RegistryInterface.hpp"
30#include "util/log/Logger.hpp"
32#include <org/xrpl/rpc/v1/ledger.pb.h>
33#include <xrpl/basics/Slice.h>
34#include <xrpl/basics/base_uint.h>
35#include <xrpl/basics/strHex.h>
36#include <xrpl/proto/org/xrpl/rpc/v1/get_ledger.pb.h>
37#include <xrpl/protocol/LedgerHeader.h>
38#include <xrpl/protocol/STTx.h>
39#include <xrpl/protocol/Serializer.h>
40#include <xrpl/protocol/TxMeta.h>
49namespace etlng::impl {
52 std::shared_ptr<BackendInterface> backend_;
53 std::shared_ptr<etl::LedgerFetcherInterface> fetcher_;
54 std::shared_ptr<RegistryInterface> registry_;
55 std::shared_ptr<AmendmentBlockHandlerInterface> amendmentBlockHandler_;
60 using RawLedgerObjectType = org::xrpl::rpc::v1::RawLedgerObject;
61 using GetLedgerResponseType = org::xrpl::rpc::v1::GetLedgerResponse;
62 using OptionalGetLedgerResponseType = std::optional<GetLedgerResponseType>;
65 std::shared_ptr<BackendInterface> backend,
66 std::shared_ptr<etl::LedgerFetcherInterface> fetcher,
67 std::shared_ptr<RegistryInterface> registry,
68 std::shared_ptr<AmendmentBlockHandlerInterface> amendmentBlockHandler
77 std::vector<model::Object>
const&
data,
78 std::optional<std::string> lastKey
81 std::optional<ripple::LedgerHeader>
Definition Loading.hpp:51
void load(model::LedgerData const &data) override
Load ledger data.
Definition Loading.cpp:61
void onInitialLoadGotMoreObjects(uint32_t seq, std::vector< model::Object > const &data, std::optional< std::string > lastKey) override
Callback for each incoming batch of objects during initial ledger load.
Definition Loading.cpp:78
std::optional< ripple::LedgerHeader > loadInitialLedger(model::LedgerData const &data) override
Load the initial ledger.
Definition Loading.cpp:91
A simple thread-safe logger for the channel specified in the constructor.
Definition Logger.hpp:110
This namespace implements the data access layer and related components.
Definition AmendmentCenter.cpp:70
The interface for observing the initial ledger load.
Definition InitialLoadObserverInterface.hpp:36
An interface for a ETL Loader.
Definition LoaderInterface.hpp:33
Represents an entire ledger diff worth of transactions and objects.
Definition Models.hpp:143