MCPcopy Create free account
hub / github.com/apache/impala / AsyncWriteRange

Method AsyncWriteRange

be/src/runtime/tmp-file-mgr.cc:506–518  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

504}
505
506Status TmpFileMgr::AsyncWriteRange(WriteRange* write_range, TmpFile* tmp_file) {
507 if (write_range->disk_file()->disk_type() == io::DiskFileType::LOCAL) {
508 DCHECK(write_range != nullptr);
509 DCHECK(write_range->io_ctx() != nullptr);
510 return write_range->io_ctx()->AddWriteRange(write_range);
511 }
512 // If spill to a remote directory, TmpFileBufferPool is helping to send the writes to
513 // the DiskQueue because the local buffer for the remote file may be used up and it may
514 // need to wait in the pool before the writes can be sent to the DiskQueue.
515 DCHECK(tmp_dirs_remote_ctrl_.tmp_file_pool_ != nullptr);
516 DCHECK(tmp_file != nullptr);
517 return tmp_dirs_remote_ctrl_.tmp_file_pool_->EnqueueWriteRange(write_range, tmp_file);
518}
519
520void TmpFileMgr::EnqueueTmpFilesPoolDummyFile() {
521 EnqueueTmpFilesPool(tmp_dirs_remote_ctrl_.tmp_file_pool_->tmp_file_dummy_, true);

Callers 3

WriteMethod · 0.80
TEST_FFunction · 0.80

Calls 5

disk_fileMethod · 0.80
io_ctxMethod · 0.80
EnqueueWriteRangeMethod · 0.80
disk_typeMethod · 0.45
AddWriteRangeMethod · 0.45

Tested by 2

TEST_FFunction · 0.64