|
virtual void | run ()=0 |
| Run subscriptions loop of the source.
|
|
virtual void | stop (boost::asio::yield_context yield)=0 |
| Stop Source.
|
|
virtual bool | isConnected () const =0 |
| Check if source is connected.
|
|
virtual void | setForwarding (bool isForwarding)=0 |
| Set the forwarding state of the source.
|
|
virtual boost::json::object | toJson () const =0 |
| Represent the source as a JSON object.
|
|
virtual std::string | toString () const =0 |
|
virtual bool | hasLedger (uint32_t sequence) const =0 |
| Check if ledger is known by this source.
|
|
virtual std::pair< grpc::Status, org::xrpl::rpc::v1::GetLedgerResponse > | fetchLedger (uint32_t sequence, bool getObjects=true, bool getObjectNeighbors=false)=0 |
| Fetch data for a specific ledger.
|
|
virtual std::pair< std::vector< std::string >, bool > | loadInitialLedger (uint32_t sequence, std::uint32_t numMarkers)=0 |
| Download a ledger in full.
|
|
virtual std::expected< boost::json::object, rpc::ClioError > | forwardToRippled (boost::json::object const &request, std::optional< std::string > const &forwardToRippledClientIp, std::string_view xUserValue, boost::asio::yield_context yield) const =0 |
| Forward a request to rippled.
|
|
Provides an implementation of a ETL source.
virtual std::pair< grpc::Status, org::xrpl::rpc::v1::GetLedgerResponse > etl::SourceBase::fetchLedger |
( |
uint32_t | sequence, |
|
|
bool | getObjects = true, |
|
|
bool | getObjectNeighbors = false ) |
|
pure virtual |
Fetch data for a specific ledger.
This function will continuously try to fetch data for the specified ledger until the fetch succeeds, the ledger is found in the database, or the server is shutting down.
- Parameters
-
sequence | Sequence of the ledger to fetch |
getObjects | Whether to get the account state diff between this ledger and the prior one; defaults to true |
getObjectNeighbors | Whether to request object neighbors; defaults to false |
- Returns
- A std::pair of the response status and the response itself
Implemented in etl::impl::SourceImpl< GrpcSourceType, SubscriptionSourceTypePtr, ForwardingSourceType >.