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

Method SerializeToBuffer

be/src/rpc/thrift-util.h:105–117  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

103 /// is serialized.
104 template <class T>
105 Status SerializeToBuffer(const T* obj, uint32_t* len, uint8_t** buffer) {
106 try {
107 mem_buffer_->resetBuffer();
108 obj->write(protocol_.get());
109 } catch (std::exception& e) {
110 std::stringstream msg;
111 msg << "Couldn't serialize thrift object beyond "
112 << mem_buffer_->getBufferSize() << " bytes:\n" << e.what();
113 return Status(msg.str());
114 }
115 mem_buffer_->getBuffer(buffer, len);
116 return Status::OK();
117 }
118
119 template <class T>
120 Status SerializeToString(const T* obj, std::string* result) {

Callers 14

FlushMethod · 0.80
FinalizeCurrentPageMethod · 0.80
FlushCurrentRowGroupMethod · 0.80
WritePageIndexMethod · 0.80
WriteFileFooterMethod · 0.80
TESTFunction · 0.80
SerializeToSidecarMethod · 0.80
SetFaststringSidecarFunction · 0.80
CompressThriftFunction · 0.80
SerializeThriftMsgFunction · 0.80
StartBackendExecMethod · 0.80

Calls 5

OKFunction · 0.85
getMethod · 0.65
StatusClass · 0.50
writeMethod · 0.45
strMethod · 0.45

Tested by 1

TESTFunction · 0.64