Class CacheDataLocalFile

Inheritance Relationships

Base Type

Class Documentation

class ral::cache::CacheDataLocalFile : public ral::cache::CacheData

A CacheData that stores is data in an ORC file. This allows us to cache onto filesystems to allow larger queries to run on limited resources. This is the least performant cache in most instances.

Public Functions

CacheDataLocalFile(std::unique_ptr<ral::frame::BlazingTable> table, std::string orc_files_path, std::string ctx_token)

Constructor

Parameters
  • table: The BlazingTable that is converted into an ORC file and stored on disk. @ param orc_files_path The path where the file should be stored. @ param ctx_id The context token to identify the query that generated the file.

virtual std::unique_ptr<ral::frame::BlazingTable> decache() override

Constructor

Parameters
  • table: The BlazingTable that is converted into an ORC file and stored on disk. @ param orc_files_path The path where the file should be stored.

virtual size_t sizeInBytes() const override

Get the amount of GPU memory that the decached BlazingTable WOULD consume. Having this function allows us to have one api for seeing how much GPU memory is necessary to decache the file from disk.

Return

The number of bytes needed for the BlazingTable decache would generate.

size_t fileSizeInBytes() const

Get the amount of disk space consumed by this CacheData Having this function allows us to have one api for seeing the consumption of all the CacheData objects that are currently in Caches.

Return

The number of bytes the ORC file consumes.

inline virtual void set_names(const std::vector<std::string> &names) override

Set the names of the columns to pass when decache if needed.

Parameters
  • names: a vector of the column names.

inline virtual ~CacheDataLocalFile()

Destructor

inline std::string filePath() const

Get the file path of the ORC file.

Return

The path to the ORC file.