MCPcopy Create free account
hub / github.com/bytedance/bolt / addContextOnException

Function addContextOnException

bolt/exec/Driver.cpp:120–128  ·  view source on GitHub ↗

Used to generate context for exceptions that are thrown while executing an operator. Eg output: 'Operator: FilterProject(1) PlanNodeId: 1 TaskId: test_cursor 1 PipelineId: 0 DriverId: 0 OperatorAddress: 0x61a000003c80'

Source from the content-addressed store, hash-verified

118}
119
120// Used to generate context for exceptions that are thrown while executing an
121// operator. Eg output: 'Operator: FilterProject(1) PlanNodeId: 1 TaskId:
122// test_cursor 1 PipelineId: 0 DriverId: 0 OperatorAddress: 0x61a000003c80'
123std::string addContextOnException(
124 BoltException::Type exceptionType,
125 void* arg) {
126 if (exceptionType != BoltException::Type::kSystem) {
127 return "";
128 }
129 auto* op = static_cast<Operator*>(arg);
130 return fmt::format("Operator: {}", op->toString());
131}

Callers

nothing calls this directly

Calls 1

toStringMethod · 0.45

Tested by

no test coverage detected