Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using subdirectory to dave data in ICEBERG. #10327

Open
moweonlee opened this issue May 13, 2024 · 0 comments
Open

Using subdirectory to dave data in ICEBERG. #10327

moweonlee opened this issue May 13, 2024 · 0 comments
Labels
question Further information is requested

Comments

@moweonlee
Copy link

Query engine

Spark - pyspark

Question

We have stored our data in HDFS into subdirecties for every hour with batch processing .

Here are the examples to show how we write data in HDFS for every hours.

  • hdfs://team/data/logtype_a/2024/05/01/00
  • hdfs://team/data/logtype_b/2024/05/01/01

We have many data applications that uses that directories as input for long time.
And it's practically hard to change input directory in applications that uses directories.

But anyway I'd like to use ICEBERG with that data with metadata location "hdfs://team/data/rawlog/metadata".
Because we'd like to read whole data as single table. ( from Starrocks )

So my question is "Can I load data for every hours with single metadata location"

We uses PySpark to load data.

And here is example code that loads data.

df\
  .writeTo(tableName) \
  .tableProperty("write.data.path"    ,"hdfs://team/data/logtype_a/" + datePath + "/" + hour + "/") \
  .tableProperty("write.metadata.path"    ,"hdfs://team/data/logtype_a/" ) \
  .option("mergeSchema","true") \
  .append()
@moweonlee moweonlee added the question Further information is requested label May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant