MCPcopy Create free account
hub / github.com/ClickHouse/ClickHouse / loadKeys

Method loadKeys

src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:238–252  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

236
237
238QueryPipeline ExternalDictionaryLibraryBridgeHelper::loadKeys(const Block & requested_block)
239{
240 startBridgeSync();
241 auto uri = createRequestURI(EXT_DICT_LOAD_KEYS_METHOD);
242 /// Sample block to parse block from callback
243 uri.addQueryParameter("requested_block_sample", requested_block.getNamesAndTypesList().toString());
244 ReadWriteBufferFromHTTP::OutStreamCallback out_stream_callback = [requested_block, this](std::ostream & os)
245 {
246 WriteBufferFromOStream out_buffer(os);
247 auto output_format = getContext()->getOutputFormat(ExternalDictionaryLibraryBridgeHelper::DEFAULT_FORMAT, out_buffer, requested_block.cloneEmpty());
248 formatBlock(output_format, requested_block);
249 out_buffer.finalize();
250 };
251 return QueryPipeline(loadBase(uri, out_stream_callback));
252}
253
254
255bool ExternalDictionaryLibraryBridgeHelper::executeRequest(const Poco::URI & uri, ReadWriteBufferFromHTTP::OutStreamCallback out_stream_callback) const

Callers

nothing calls this directly

Calls 9

formatBlockFunction · 0.85
addQueryParameterMethod · 0.80
getContextFunction · 0.50
QueryPipelineClass · 0.50
toStringMethod · 0.45
getNamesAndTypesListMethod · 0.45
getOutputFormatMethod · 0.45
cloneEmptyMethod · 0.45
finalizeMethod · 0.45

Tested by

no test coverage detected