This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/orc.git


The following commit(s) were added to refs/heads/main by this push:
     new cea0629ef ORC-1669: [C++] Deprecate HDFS support
cea0629ef is described below

commit cea0629efd15749d9f2d8734d4837a85eaf03eb7
Author: Gang Wu <ust...@gmail.com>
AuthorDate: Sat Apr 13 16:58:58 2024 -0700

    ORC-1669: [C++] Deprecate HDFS support
    
    ### What changes were proposed in this pull request?
    Mark readHdfsFile as deprecated.
    
    ### Why are the changes needed?
    Reading ORC on HDFS was introduced in 
https://github.com/apache/orc/pull/134 without any test. It has not been 
updated for 7 years and updating libhdfspp will result in extra dependency like 
boost library. Staying at an old version of libhdfspp will also prohibit us 
from updating other libraries like protobuf.
    
    ### How was this patch tested?
    It does not need test.
    
    ### Was this patch authored or co-authored using generative AI tooling?
    No.
    
    Closes #1885 from wgtmac/ORC-1669.
    
    Authored-by: Gang Wu <ust...@gmail.com>
    Signed-off-by: Dongjoon Hyun <dongj...@apache.org>
---
 CMakeLists.txt             | 2 +-
 c++/include/orc/OrcFile.hh | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1fb0e755d..af5b9f406 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -42,7 +42,7 @@ option (ANALYZE_JAVA
 
 option (BUILD_LIBHDFSPP
     "Include LIBHDFSPP library in the build process"
-     ON)
+     OFF)
 
 option(BUILD_CPP_TESTS
     "Build the googletest unit tests"
diff --git a/c++/include/orc/OrcFile.hh b/c++/include/orc/OrcFile.hh
index 6e4a07bf7..a9ad692d4 100644
--- a/c++/include/orc/OrcFile.hh
+++ b/c++/include/orc/OrcFile.hh
@@ -127,8 +127,8 @@ namespace orc {
    * @param path the uri of the file in HDFS
    * @param metrics the metrics of the reader
    */
-  std::unique_ptr<InputStream> readHdfsFile(const std::string& path,
-                                            ReaderMetrics* metrics = nullptr);
+  [[deprecated("readHdfsFile is deprecated in 2.0.1")]] 
std::unique_ptr<InputStream> readHdfsFile(
+      const std::string& path, ReaderMetrics* metrics = nullptr);
 
   /**
    * Create a reader to read the ORC file.

Reply via email to