22#include "data/BackendInterface.hpp"
23#include "util/log/Logger.hpp"
25#include <grpcpp/support/status.h>
26#include <org/xrpl/rpc/v1/get_ledger.pb.h>
27#include <xrpl/proto/org/xrpl/rpc/v1/xrp_ledger.grpc.pb.h>
38 std::unique_ptr<org::xrpl::rpc::v1::XRPLedgerAPIService::Stub> stub_;
39 std::shared_ptr<BackendInterface> backend_;
42 GrpcSource(std::string
const& ip, std::string
const& grpcPort, std::shared_ptr<BackendInterface> backend);
55 std::pair<grpc::Status, org::xrpl::rpc::v1::GetLedgerResponse>
56 fetchLedger(uint32_t sequence,
bool getObjects =
true,
bool getObjectNeighbors =
false);
66 std::pair<std::vector<std::string>,
bool>
67 loadInitialLedger(uint32_t sequence, uint32_t numMarkers,
bool cacheOnly =
false);
Definition GrpcSource.hpp:36
std::pair< grpc::Status, org::xrpl::rpc::v1::GetLedgerResponse > fetchLedger(uint32_t sequence, bool getObjects=true, bool getObjectNeighbors=false)
Fetch data for a specific ledger.
Definition GrpcSource.cpp:73
std::pair< std::vector< std::string >, bool > loadInitialLedger(uint32_t sequence, uint32_t numMarkers, bool cacheOnly=false)
Download a ledger in full.
Definition GrpcSource.cpp:101
A simple thread-safe logger for the channel specified in the constructor.
Definition Logger.hpp:110