C++ YT Wrapper
C++ library for working with YT clusters
Loading...
Searching...
No Matches
NYT::TRawTableReader Class Referenceabstract

Low-level interface to read YT table with retries. More...

#include <io.h>

Inheritance diagram for NYT::TRawTableReader:
NYT::IAbortableInputStream

Public Member Functions

virtual bool Retry (const TMaybe< ui32 > &rangeIndex, const TMaybe< ui64 > &rowIndex, const std::exception_ptr &error)=0
 Retry table read starting from the specified rangeIndex and rowIndex.
virtual void ResetRetries ()=0
 Resets retry attempt count to the initial value (then Retry() can be called again).
virtual bool HasRangeIndices () const =0
 May the input stream contain table ranges?
Public Member Functions inherited from NYT::IAbortableInputStream
virtual void Abort ()
 Immediately abort the stream, cancelling current and future reads.
virtual bool IsAborted () const
 Check whether the stream has been aborted.

Additional Inherited Members

Static Public Member Functions inherited from NYT::IAbortableInputStream
static bool IsAbortedError (const std::exception_ptr &error)

Detailed Description

Low-level interface to read YT table with retries.

Member Function Documentation

◆ HasRangeIndices()

virtual bool NYT::TRawTableReader::HasRangeIndices ( ) const
pure virtual

May the input stream contain table ranges?

In the case when it is true the TRawTableReader user is responsible to track active range index in order to pass it to Retry().

◆ Retry()

virtual bool NYT::TRawTableReader::Retry ( const TMaybe< ui32 > & rangeIndex,
const TMaybe< ui64 > & rowIndex,
const std::exception_ptr & error )
pure virtual

Retry table read starting from the specified rangeIndex and rowIndex.

Parameters
rangeIndexIndex of first range to read
rowIndexIndex of first row to read; if rowIndex == Nothing entire request will be retried.
Returns
true on successful request retry, false if no retry attempts are left (then Retry() shouldn't be called any more).

rowIndex must be inside the range with index rangeIndex if the latter is specified.

After successful retry the user should reset rangeIndex / rowIndex values and read new ones from the stream.


The documentation for this class was generated from the following file:
  • yt/cpp/mapreduce/interface/io.h