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

[INLONG-9925][Sort] Add if statement to solve continuously printing logs #9961

Merged
merged 4 commits into from
Apr 11, 2024

Conversation

XiaoYou201
Copy link
Contributor

@XiaoYou201 XiaoYou201 commented Apr 10, 2024

Prepare a Pull Request

Motivation

The log keeps printing the same message. This message should be printed when there is update or delete operation for ck and should not appear so many times.And because it continuously write log files, the disk will not has free space soon.

Modifications

I found that the program through JDBC module continuously batch write to clickhouse. But when batch count equals 0, the program still execute batch write command. So the log nonstop print. I add if statement. Only batch count greater than 0, it will execute batch write command.

aloyszhang
aloyszhang previously approved these changes Apr 11, 2024
Copy link
Contributor

@aloyszhang aloyszhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@aloyszhang aloyszhang added this to the 1.12.0 milestone Apr 11, 2024
Copy link
Contributor

@EMsnap EMsnap left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use guard code to reduce cyclomatic complexity https://en.wikipedia.org/wiki/Guard_(computer_science)

@dockerzhang dockerzhang merged commit bf8d1f7 into apache:master Apr 11, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug][Sort] Infinite log growth causes insufficient disk space on sort-flink-v1.13(Mysql to Clickhouse)
4 participants