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

openapi(dm): add task config template releated openapi #3656

Merged
merged 7 commits into from
Dec 21, 2021
Merged

openapi(dm): add task config template releated openapi #3656

merged 7 commits into from
Dec 21, 2021

Conversation

Ehco1996
Copy link
Contributor

@Ehco1996 Ehco1996 commented Nov 29, 2021

What problem does this PR solve?

subtask of https://github.com/pingcap/ticdc/issues/3583

What is changed and how it works?

as title, need https://github.com/pingcap/ticdc/pull/3620 merged first

Check List

Tests

  • Unit test

Code changes

  • Has exported function/method change

Side effects

  • Possible performance regression
  • Increased code complexity

Related changes

  • Need to update the documentation

Release note

`add task config releated openapi`.

@Ehco1996 Ehco1996 added the area/dm Issues or PRs related to DM. label Nov 29, 2021
@ti-chi-bot
Copy link
Member

ti-chi-bot commented Nov 29, 2021

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • lichunzhu
  • okJiang

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 29, 2021
@Ehco1996 Ehco1996 mentioned this pull request Nov 29, 2021
14 tasks
@Ehco1996 Ehco1996 marked this pull request as ready for review December 14, 2021 07:47
@ti-chi-bot ti-chi-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Dec 14, 2021
@Ehco1996
Copy link
Contributor Author

/hold

need add new batch import api after meeting with PM😅

@ti-chi-bot ti-chi-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 14, 2021
@@ -822,6 +823,123 @@ func (s *Server) DMAPIOperateTableStructure(c *gin.Context, taskName string, sou
}
}

// DMAPIBatchImportTaskConfig create task_config_template url is: (POST /api/v1/task_configs/batch_import).
func (s *Server) DMAPIBatchImportTaskConfig(c *gin.Context) {
Copy link
Contributor Author

@Ehco1996 Ehco1996 Dec 14, 2021

Choose a reason for hiding this comment

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

this api is for this feature

schema:
$ref: "#/components/schemas/ErrorWithMessage"

/api/v1/task_configs:
Copy link
Contributor Author

@Ehco1996 Ehco1996 Dec 14, 2021

Choose a reason for hiding this comment

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

maybe use this path pattern ? 🤔

  • list/create api/vi/tasks/configs?
  • batch_import api/vi/tasks/configs/batch_import
  • delete/get/update api/vi/tasks/{task-name}/configs

need suggestion from other reviewers

Copy link
Contributor

Choose a reason for hiding this comment

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

My point:
list/create api/vi/tasks/configs?
batch_import api/vi/tasks/configs/import
delete/get/update api/vi/tasks/configs/{task-name}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

addressed in f585588
ptal

@Ehco1996
Copy link
Contributor Author

/unhold

could you please take another look for this pr ? thanks 🧡🧡🧡

/cc @glorv @okJiang @lance6716

@ti-chi-bot ti-chi-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 14, 2021
@Ehco1996
Copy link
Contributor Author

please check this api spec of task config if the api is sufficient for webui

/cc @zoubingwu

@ti-chi-bot
Copy link
Member

@Ehco1996: GitHub didn't allow me to request PR reviews from the following users: zoubingwu.

Note that only pingcap members and repo collaborators can review this PR, and authors cannot review their own PRs.

In response to this:

please check this api spec of task config if the api is sufficient for webui

/cc @zoubingwu

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@codecov-commenter
Copy link

codecov-commenter commented Dec 15, 2021

Codecov Report

Merging #3656 (f585588) into master (3873d39) will decrease coverage by 2.1798%.
The diff coverage is 61.8644%.

Flag Coverage Δ
cdc 58.2864% <61.8644%> (+0.0498%) ⬆️
dm 52.0561% <ø> (-3.9785%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

@@               Coverage Diff                @@
##             master      #3656        +/-   ##
================================================
- Coverage   57.0741%   54.8943%   -2.1799%     
================================================
  Files           478        484         +6     
  Lines         56551      59671      +3120     
================================================
+ Hits          32276      32756       +480     
- Misses        20978      23596      +2618     
- Partials       3297       3319        +22     

Copy link
Member

@okJiang okJiang left a comment

Choose a reason for hiding this comment

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

rest lgtm

@ti-chi-bot ti-chi-bot added status/LGT1 Indicates that a PR has LGTM 1. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Dec 16, 2021
@ti-chi-bot ti-chi-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Dec 20, 2021
@Ehco1996 Ehco1996 added the status/ptal Could you please take a look? label Dec 20, 2021
@Ehco1996
Copy link
Contributor Author

could you please take another look for this pr ? thanks 🧡🧡🧡

@glorv @lichunzhu @GMHDBJD

Copy link
Contributor

@lichunzhu lichunzhu left a comment

Choose a reason for hiding this comment

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

Rest LGTM

schema:
$ref: "#/components/schemas/ErrorWithMessage"

/api/v1/task_configs:
Copy link
Contributor

Choose a reason for hiding this comment

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

My point:
list/create api/vi/tasks/configs?
batch_import api/vi/tasks/configs/import
delete/get/update api/vi/tasks/configs/{task-name}

Copy link
Contributor

@lichunzhu lichunzhu left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Dec 21, 2021
@Ehco1996
Copy link
Contributor Author

/merge

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 6634f5f

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Dec 21, 2021
@lance6716
Copy link
Contributor

/run-integration-test
/run-kafka-integration-test

@Ehco1996
Copy link
Contributor Author

/run-integration-test
/run-kafka-integration-test

@Ehco1996
Copy link
Contributor Author

/run-kafka-integration-test

@Ehco1996
Copy link
Contributor Author

/run-integration-test

@Ehco1996
Copy link
Contributor Author

/run-kafka-integration-test

@Ehco1996
Copy link
Contributor Author

/run-kafka-integration-test /tidb=pr/30773
/run-integration-tests /tidb=pr/30773

@ti-chi-bot ti-chi-bot merged commit 9ef831f into pingcap:master Dec 21, 2021
zhaoxinyu pushed a commit to zhaoxinyu/ticdc that referenced this pull request Dec 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dm Issues or PRs related to DM. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. status/ptal Could you please take a look?
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants