Skip to content

Commit

Permalink
Upgrade Apache Arrow version from 8.0.0 to 11.0.0 (oap-project#133)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhztheplayer authored and zhejiangxiaomai committed Apr 14, 2023
1 parent 4745c27 commit 2c700c6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions third_party/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,7 @@ if(VELOX_ENABLE_ARROW)
ExternalProject_Add(
arrow_ep
PREFIX ${ARROW_PREFIX}
URL ${VELOX_ARROW_SOURCE_URL}
URL_HASH ${VELOX_ARROW_BUILD_SHA256_CHECKSUM}
URL "https://dlcdn.apache.org/arrow/arrow-11.0.0/apache-arrow-11.0.0.tar.gz"
SOURCE_SUBDIR cpp
CMAKE_ARGS ${ARROW_CMAKE_ARGS}
BUILD_BYPRODUCTS ${ARROW_LIBDIR}/libarrow.a ${ARROW_LIBDIR}/libparquet.a
Expand Down
5 changes: 2 additions & 3 deletions velox/dwio/parquet/writer/Writer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,12 @@ void Writer::write(const RowVectorPtr& data) {
if (!arrowWriter_) {
stream_ = std::make_shared<DataBufferSink>(pool_);
auto arrowProperties = ::parquet::ArrowWriterProperties::Builder().build();
PARQUET_THROW_NOT_OK(::parquet::arrow::FileWriter::Open(
PARQUET_ASSIGN_OR_THROW(arrowWriter_, ::parquet::arrow::FileWriter::Open(
*recordBatch->schema(),
arrow::default_memory_pool(),
stream_,
properties_,
arrowProperties,
&arrowWriter_));
arrowProperties));
}

PARQUET_THROW_NOT_OK(arrowWriter_->WriteTable(*table, 10000));
Expand Down

0 comments on commit 2c700c6

Please sign in to comment.