Skip to content

[Bug] Version 2.0.4 Unable to export empty data to hdfs / S3 #30600

@zxealous

Description

@zxealous

Search before asking

  • I had searched in the issues and found no similar issues.

Version

master、2.0.4

What's Wrong?

Unable to export empty data to hdfs / S3, this behavior is inconsistent with version 1.2.7, version 1.2.7 can export empty data to hdfs/ S3, and there will be exported files on S3/HDFS.

Here is the behavior on version 2.0.4:

  1. If export empty data to s3, it will return success, but there are no exported files on S3.
    Reproduction method:
select * from test_tb where id=0 INTO OUTFILE  "s3://repo/test-outfile-empty/my_file_"
properties (
    "AWS_ENDPOINT" = "xxx",
    "AWS_ACCESS_KEY" = "xxx",
    "AWS_SECRET_KEY"="xxx",
    "AWS_REGION" = "bj"
)

image

  1. if export empty data to hdfs use broker, it will return failed because not open broker writer but close it.(if not use broker the behavior is same as export file to s3, exported files not exist)
    Reproduction method:
select * from test_tb where id = 0 INTO OUTFILE "hdfs://host:port/data/export/empty/label_23_20_48_26_453655_1336993759/label_23_20_48_26_453748_1090390474"  PROPERTIES ( "broker.fs.defaultFS" = "hdfs://host:port","broker.name"="hdfs","broker.username"="user","broker.password"="password");

image

What You Expected?

Behavior consistent with version 1.2.7

How to Reproduce?

No response

Anything Else?

No response

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions