| 340 | } |
| 341 | |
| 342 | Status QueryState::InitBufferPoolState() { |
| 343 | ExecEnv* exec_env = ExecEnv::GetInstance(); |
| 344 | int64_t max_reservation = GetMaxReservation(); |
| 345 | VLOG(2) << "Buffer pool limit for " << PrintId(query_id()) << ": " << max_reservation; |
| 346 | |
| 347 | buffer_reservation_ = obj_pool_.Add(new ReservationTracker); |
| 348 | buffer_reservation_->InitChildTracker( |
| 349 | NULL, exec_env->buffer_reservation(), query_mem_tracker_, max_reservation); |
| 350 | |
| 351 | if (query_options().scratch_limit != 0 && !query_ctx_.disable_spilling) { |
| 352 | file_group_ = obj_pool_.Add( |
| 353 | new TmpFileGroup(exec_env->tmp_file_mgr(), exec_env->disk_io_mgr(), |
| 354 | host_profile_, query_id(), query_options().scratch_limit)); |
| 355 | if (!query_options().debug_action.empty()) { |
| 356 | file_group_->SetDebugAction(query_options().debug_action); |
| 357 | } |
| 358 | } |
| 359 | return Status::OK(); |
| 360 | } |
| 361 | |
| 362 | // Verifies the filters produced by all instances on the same backend are the same. |
| 363 | bool VerifyFiltersProduced(const vector<TPlanFragmentInstanceCtx>& instance_ctxs) { |
nothing calls this directly
no test coverage detected