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

[Improve][E2E] modify the method of obtaining JobId #7880

Merged
merged 2 commits into from
Oct 23, 2024

Conversation

hawk9821
Copy link
Contributor

Purpose of this pull request

modify the method of obtaining JobId

Pattern jobIdPattern = Pattern.compile(
                  ".*Init JobMaster for Job tidbcdc_to_tidb.conf \\(([0-9]*)\\).*",
                  Pattern.DOTALL);
Matcher matcher = jobIdPattern.matcher(container.getServerLogs());
String jobId;
if (matcher.matches()) {
    jobId = matcher.group(1);
} else {
    throw new RuntimeException("Can not find jobId");
}

change to

String jobId = JobIdGenerator.newJobId();
container.executeJob("/tidb/tidbcdc_to_tidb.conf", jobId);

Does this PR introduce any user-facing change?

How was this patch tested?

Check list

@github-actions github-actions bot added the e2e label Oct 21, 2024
@Hisoka-X Hisoka-X changed the title [Improve][E2E]modify the method of obtaining JobId [Improve][E2E] modify the method of obtaining JobId Oct 21, 2024
Hisoka-X
Hisoka-X previously approved these changes Oct 21, 2024
Copy link
Member

@Hisoka-X Hisoka-X left a comment

Choose a reason for hiding this comment

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

LGTM if ci passes. Thanks @hawk9821 !

Hisoka-X
Hisoka-X previously approved these changes Oct 22, 2024
Copy link
Member

@Hisoka-X Hisoka-X left a comment

Choose a reason for hiding this comment

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

LGTM.

[Improve][E2E]modify the method of obtaining JobId
@hailin0 hailin0 merged commit 13bd46b into apache:dev Oct 23, 2024
6 checks passed
@hawk9821 hawk9821 deleted the cancel_job branch November 14, 2024 04:40
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.

3 participants