Clio develop
The XRP Ledger API server.
Loading...
Searching...
No Matches
etlng::ETLServiceInterface Struct Referenceabstract

This is a base class for any ETL service implementations. More...

#include <ETLServiceInterface.hpp>

Inheritance diagram for etlng::ETLServiceInterface:

Public Member Functions

virtual void run ()=0
 Start all components to run ETL service.
 
virtual void stop ()=0
 Stop the ETL service.
 
virtual boost::json::object getInfo () const =0
 Get state of ETL as a JSON object.
 
virtual bool isAmendmentBlocked () const =0
 Check for the amendment blocked state.
 
virtual bool isCorruptionDetected () const =0
 Check whether Clio detected DB corruptions.
 
virtual std::optional< etl::ETLStategetETLState () const =0
 Get the etl nodes' state.
 
virtual std::uint32_t lastCloseAgeSeconds () const =0
 Get time passed since last ledger close, in seconds.
 

Detailed Description

This is a base class for any ETL service implementations.

Note
A ETL service is responsible for continuously extracting data from a p2p node, and writing that data to the databases.

Member Function Documentation

◆ getETLState()

virtual std::optional< etl::ETLState > etlng::ETLServiceInterface::getETLState ( ) const
nodiscardpure virtual

Get the etl nodes' state.

Returns
The etl nodes' state, nullopt if etl nodes are not connected

Implemented in etl::ETLService, and etlng::ETLService.

◆ getInfo()

virtual boost::json::object etlng::ETLServiceInterface::getInfo ( ) const
nodiscardpure virtual

Get state of ETL as a JSON object.

Returns
The state of ETL as a JSON object

Implemented in etl::ETLService, and etlng::ETLService.

◆ isAmendmentBlocked()

virtual bool etlng::ETLServiceInterface::isAmendmentBlocked ( ) const
nodiscardpure virtual

Check for the amendment blocked state.

Returns
true if currently amendment blocked; false otherwise

Implemented in etl::ETLService, and etlng::ETLService.

◆ isCorruptionDetected()

virtual bool etlng::ETLServiceInterface::isCorruptionDetected ( ) const
nodiscardpure virtual

Check whether Clio detected DB corruptions.

Returns
true if corruption of DB was detected and cache was stopped.

Implemented in etl::ETLService, and etlng::ETLService.

◆ lastCloseAgeSeconds()

virtual std::uint32_t etlng::ETLServiceInterface::lastCloseAgeSeconds ( ) const
nodiscardpure virtual

Get time passed since last ledger close, in seconds.

Returns
Time passed since last ledger close

Implemented in etl::ETLService, and etlng::ETLService.

◆ run()

virtual void etlng::ETLServiceInterface::run ( )
pure virtual

Start all components to run ETL service.

Implemented in etl::ETLService, and etlng::ETLService.

◆ stop()

virtual void etlng::ETLServiceInterface::stop ( )
pure virtual

Stop the ETL service.

Note
This method blocks until the ETL service has stopped.

Implemented in etl::ETLService, and etlng::ETLService.


The documentation for this struct was generated from the following file: