| 57 | } |
| 58 | |
| 59 | Status TupleCacheNode::Prepare(RuntimeState* state) { |
| 60 | RETURN_IF_ERROR(ExecNode::Prepare(state)); |
| 61 | num_hits_counter_ = ADD_COUNTER(runtime_profile(), "NumTupleCacheHits", TUnit::UNIT); |
| 62 | num_halted_counter_ = |
| 63 | ADD_COUNTER(runtime_profile(), "NumTupleCacheHalted", TUnit::UNIT); |
| 64 | num_backpressure_halted_counter_ = |
| 65 | ADD_COUNTER(runtime_profile(), "NumTupleCacheBackpressureHalted", TUnit::UNIT); |
| 66 | num_skipped_counter_ = |
| 67 | ADD_COUNTER(runtime_profile(), "NumTupleCacheSkipped", TUnit::UNIT); |
| 68 | // If correctness verification is enabled, add a counter to indicate whether it was |
| 69 | // actually performing correctness verification. |
| 70 | if (TupleCacheVerificationEnabled(state)) { |
| 71 | num_correctness_verification_counter_ = |
| 72 | ADD_COUNTER(runtime_profile(), "NumTupleCacheCorrectnessVerification", TUnit::UNIT); |
| 73 | } |
| 74 | // Compute the combined cache key by computing the fragment instance key and |
| 75 | // fusing it with the compile time key. |
| 76 | ComputeFragmentInstanceKey(state); |
| 77 | combined_key_ = plan_node().tnode_->tuple_cache_node.compile_time_key + "_" + |
| 78 | std::to_string(fragment_instance_key_); |
| 79 | skip_correctness_verification_ = |
| 80 | plan_node().tnode_->tuple_cache_node.skip_correctness_verification; |
| 81 | runtime_profile()->AddInfoString("Combined Key", combined_key_); |
| 82 | |
| 83 | return Status::OK(); |
| 84 | } |
| 85 | |
| 86 | Status TupleCacheNode::Open(RuntimeState* state) { |
| 87 | SCOPED_TIMER(runtime_profile()->total_time_counter()); |
nothing calls this directly
no test coverage detected