[FEAT MERGE] add direct load function

Co-authored-by: Monk-Liu <1152761042@qq.com>
Co-authored-by: saltonz <saltonzh@gmail.com>
Co-authored-by: yongshige <598633031@qq.com>
This commit is contained in:
obdev
2023-01-28 18:08:50 +08:00
committed by ob-robot
parent f27d2efc83
commit 81d28c0295
384 changed files with 55860 additions and 1239 deletions

View File

@ -351,6 +351,7 @@ public:
int64_t get_buffer_size() { return buffer_size_; }
int64_t *get_pos() { return &pos_; }
void reset() { pos_ = 0; }
TO_STRING_KV(K_(pos), K_(buffer_size));
private:
int64_t pos_;
int64_t buffer_size_;
@ -392,8 +393,8 @@ public:
int backup_incomplate_data(ObLoadFileBuffer &buffer, int64_t valid_data_len);
int recover_incomplate_data(ObLoadFileBuffer &buffer);
bool has_incomplate_data() { return incomplate_data_len_ > 0; }
int64_t get_lines_count() { return lines_cnt_; }
bool has_incomplate_data() const { return incomplate_data_len_ > 0; }
int64_t get_lines_count() const { return lines_cnt_; }
void commit_line_cnt(int64_t line_cnt) { lines_cnt_ += line_cnt; }
private:
ObCSVFormats formats_;//TODO [load data] change to ObInverseParser(formats)
@ -632,7 +633,7 @@ struct ObFileReadCursor {
read_size_ = 0;
is_end_file_ = false;
}
bool inline is_end_file() { return is_end_file_; }
bool inline is_end_file() const { return is_end_file_; }
int64_t inline get_total_read_MBs() { return file_offset_ >> 20; }
int64_t inline get_total_read_GBs() { return file_offset_ >> 30; }
void commit_read() {