add missing finalize calls in buffers

This commit is contained in:
Sema Checherinda 2023-06-27 16:54:14 +02:00
parent d4d85d9fe9
commit fe97021929
2 changed files with 3 additions and 0 deletions

View File

@ -239,6 +239,7 @@ QueryPipeline ExternalDictionaryLibraryBridgeHelper::loadKeys(const Block & requ
WriteBufferFromOStream out_buffer(os); WriteBufferFromOStream out_buffer(os);
auto output_format = getContext()->getOutputFormat(ExternalDictionaryLibraryBridgeHelper::DEFAULT_FORMAT, out_buffer, requested_block.cloneEmpty()); auto output_format = getContext()->getOutputFormat(ExternalDictionaryLibraryBridgeHelper::DEFAULT_FORMAT, out_buffer, requested_block.cloneEmpty());
formatBlock(output_format, requested_block); formatBlock(output_format, requested_block);
out_buffer.finalize();
}; };
return QueryPipeline(loadBase(uri, out_stream_callback)); return QueryPipeline(loadBase(uri, out_stream_callback));
} }

View File

@ -135,6 +135,7 @@ QueryPipeline HTTPDictionarySource::loadIds(const std::vector<UInt64> & ids)
WriteBufferFromOStream out_buffer(ostr); WriteBufferFromOStream out_buffer(ostr);
auto output_format = context->getOutputFormatParallelIfPossible(configuration.format, out_buffer, block.cloneEmpty()); auto output_format = context->getOutputFormatParallelIfPossible(configuration.format, out_buffer, block.cloneEmpty());
formatBlock(output_format, block); formatBlock(output_format, block);
out_buffer.finalize();
}; };
Poco::URI uri(configuration.url); Poco::URI uri(configuration.url);
@ -164,6 +165,7 @@ QueryPipeline HTTPDictionarySource::loadKeys(const Columns & key_columns, const
WriteBufferFromOStream out_buffer(ostr); WriteBufferFromOStream out_buffer(ostr);
auto output_format = context->getOutputFormatParallelIfPossible(configuration.format, out_buffer, block.cloneEmpty()); auto output_format = context->getOutputFormatParallelIfPossible(configuration.format, out_buffer, block.cloneEmpty());
formatBlock(output_format, block); formatBlock(output_format, block);
out_buffer.finalize();
}; };
Poco::URI uri(configuration.url); Poco::URI uri(configuration.url);