Skip to content

Commit

Permalink
remove real paths in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
taiyang-li committed Oct 31, 2024
1 parent 3bc9519 commit 4085908
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions cpp-ch/local-engine/examples/splittable_bzip2_read_buffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,19 +34,14 @@ int main()
{
local_engine::LoggerExtend::initConsoleLogger("debug");

// setenv("LIBHDFS3_CONF", "/path/to/hdfs/config", true); /// NOLINT
// String hdfs_uri = "hdfs://cluster";
// String hdfs_file_path = "/path/to/bzip2/file";
setenv("LIBHDFS3_CONF", "/data1/clickhouse_official/conf/hdfs-site.bigocluster.xml", true); /// NOLINT
String hdfs_uri = "hdfs://bigocluster";
String hdfs_file_path = "/data/apps/imo_us/imo_data_logs_etl/data/imo_data_logs/Room.leave_room_event/day=2024-04-17/part-00000.bz2";
setenv("LIBHDFS3_CONF", "/path/to/hdfs/config", true); /// NOLINT
String hdfs_uri = "hdfs://cluster";
String hdfs_file_path = "/path/to/bzip2/file";
ConfigurationPtr config = Poco::AutoPtr(new Poco::Util::MapConfiguration());
ReadSettings read_settings;
std::unique_ptr<SeekableReadBuffer> in = std::make_unique<ReadBufferFromHDFS>(hdfs_uri, hdfs_file_path, *config, read_settings, 0, true);

std::unique_ptr<SeekableReadBuffer> bounded_in = std::make_unique<BoundedReadBuffer>(std::move(in));
// size_t start = 805306368;
// size_t end = 1073900813;
size_t start = 0;
size_t end = 268660564;
bounded_in->seek(start, SEEK_SET);
Expand Down

0 comments on commit 4085908

Please sign in to comment.