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

[ISSUE#12988] Develop naming admin api #13019

Merged

Conversation

MatthewAden
Copy link
Contributor

Please do not create a Pull Request without creating an issue first.

What is the purpose of the change

closes #12988

Brief changelog

XX

Verifying this change

XXXX

Follow this checklist to help us incorporate your contribution quickly and easily:

  • Make sure there is a Github issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a Github issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
  • Format the pull request title like [ISSUE #123] Fix UnknownException when host config not exist. Each commit in the pull request should have a meaningful subject line and body.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit-test to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
  • Run mvn -B clean package apache-rat:check findbugs:findbugs -Dmaven.test.skip=true to make sure basic checks pass. Run mvn clean install -DskipITs to make sure unit-test pass. Run mvn clean test-compile failsafe:integration-test to make sure integration-test pass.

Copy link

github-actions bot commented Jan 7, 2025

Thanks for your this PR. 🙏
Please check again for your PR changes whether contains any usage/api/configuration change such as Add new API , Add new configuration, Change default value of configuration.
If so, please add or update documents(markdown type) in docs/next/ for repository nacos-group/nacos-group.github.io


感谢您提交的PR。 🙏
请再次查看您的PR内容,确认是否包含任何使用方式/API/配置参数的变更,如:新增API新增配置参数修改默认配置等操作。
如果是,请确保在提交之前,在仓库nacos-group/nacos-group.github.io中的docs/next/目录下添加或更新文档(markdown格式)。

Copy link
Collaborator

@KomachiSion KomachiSion left a comment

Choose a reason for hiding this comment

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

在老API上加一下Compatibility注释

可以参考Core和Console的API

@GetMapping()
@Secured(resource = UtilsAndCommons.CLIENT_CONTROLLER_V3_ADMIN_PATH, action = ActionTypes.READ, apiType = ApiType.ADMIN_API)
public Result<ObjectNode> getClientDetail(@RequestParam("clientId") String clientId) throws NacosApiException {
checkClientId(clientId);
Copy link
Collaborator

Choose a reason for hiding this comment

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

是否把实际执行的逻辑抽象到一个Service里, 替换掉现在V2的Controller, 然后V3的Controller也是用抽象的Service

Copy link
Collaborator

Choose a reason for hiding this comment

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

下面的接口也相同的逻辑。

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

*/
@PutMapping
@Secured(resource = UtilsAndCommons.CLUSTER_CONTROLLER_V3_ADMIN_PATH, action = ActionTypes.WRITE, apiType = ApiType.ADMIN_API)
public Result<String> update(HttpServletRequest request) throws Exception {
Copy link
Collaborator

Choose a reason for hiding this comment

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

能否走一下NacosForm的改造

Choose a reason for hiding this comment

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

0x5be0a207aa4829a9e925117a041287872cba44c56a60297ebb1270361be9cfe2این هش را نگاه کنید من تماس گرفتم ولی چیزی دریافت نکردم

Choose a reason for hiding this comment

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

دوست عزیز از ای پی قدیم وجدید من استفاده شده وتمام مخازن مرا خالی کردند

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@GetMapping("/list")
@TpsControl(pointName = "NamingServiceListQuery", name = "HttpNamingServiceListQuery")
@Secured(resource = UtilsAndCommons.SERVICE_CONTROLLER_V3_ADMIN_PATH, action = ActionTypes.READ, apiType = ApiType.ADMIN_API)
public Result<ServiceNameView> list(
Copy link
Collaborator

Choose a reason for hiding this comment

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

是否也能做一下NacosForm改造?

Choose a reason for hiding this comment

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

دوست عزیز تا الان من فقط خرید کردم و به گیرنده انتقال دادم وچیزی دریافت نکردم

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@alibaba alibaba deleted a comment from Majidrazaee Jan 7, 2025
@MatthewAden MatthewAden marked this pull request as ready for review January 7, 2025 08:58
@MatthewAden
Copy link
Contributor Author

在老API上加一下Compatibility注释

可以参考Core和Console的API

👌

@Dario-s-j
Copy link

Dario-s-j commented Jan 7, 2025 via email

@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
Majidrazaee

This comment was marked as off-topic.

@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 8, 2025
@KomachiSion
Copy link
Collaborator

@Majidrazaee If you want to discuss or comment this PR. Please use English.

@MatthewAden
Copy link
Contributor Author

在老API上加一下Compatibility注释
可以参考Core和Console的API

👌

done

@Majidrazaee
Copy link

Majidrazaee commented Jan 8, 2025

Dear friend, it's been almost 9 months now that I just bought and transferred and until now I haven't received anything. If I called or claimed too much because the person I was depositing to asked me to do this and this caused the operator to malfunction. slow

@Majidrazaee
Copy link

Mr. Alibaba, what is your problem with me, why don't you allow me to comment, why don't you allow my property to be returned to Kiev

@Majidrazaee
Copy link

My old and new IP have been used and all my assets have been lost. Why is no one helping me?

@Majidrazaee
Copy link

If I made a large amount for a call or a claim, because the person I was depositing asked me to do so

@KomachiSion
Copy link
Collaborator

Mr. Alibaba, what is your problem with me, why don't you allow me to comment, why don't you allow my property to be returned to Kiev

If you has problem, please submit issue with English, This PR is others code commit, your comment is not relative with this PR.
And the before comment is not English so no one can understand and frequently, so that we mistakenly thought it was a response from a robot.

@KomachiSion
Copy link
Collaborator

@Majidrazaee You comment is not relative about nacos, I will delete all your comments.

Please don't submit comment and issue again, thanks.

@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@alibaba alibaba deleted a comment from Majidrazaee Jan 10, 2025
@MatthewAden MatthewAden force-pushed the develop-naming-admin-api branch from 9662cf3 to 45a3759 Compare January 10, 2025 07:10
@KomachiSion
Copy link
Collaborator

Can you guide me what to do?

Maybe you should submit support tickets to github.

*/
@PutMapping
@Secured(resource = UtilsAndCommons.CLUSTER_CONTROLLER_V3_ADMIN_PATH, action = ActionTypes.WRITE, apiType = ApiType.ADMIN_API)
public Result<String> update(HttpServletRequest request) throws Exception {

Choose a reason for hiding this comment

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

دوست عزیز از ای پی قدیم وجدید من استفاده شده وتمام مخازن مرا خالی کردند

@GetMapping("/list")
@TpsControl(pointName = "NamingServiceListQuery", name = "HttpNamingServiceListQuery")
@Secured(resource = UtilsAndCommons.SERVICE_CONTROLLER_V3_ADMIN_PATH, action = ActionTypes.READ, apiType = ApiType.ADMIN_API)
public Result<ServiceNameView> list(

Choose a reason for hiding this comment

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

دوست عزیز تا الان من فقط خرید کردم و به گیرنده انتقال دادم وچیزی دریافت نکردم

@@ -63,7 +64,7 @@ public class CatalogController {
*/
@Secured(action = ActionTypes.READ)
@GetMapping("/service")
@Compatibility(apiType = ApiType.CONSOLE_API, alternatives = "GET ${contextPath:nacos}/v3/console/ns/service")
@Compatibility(apiType = ApiType.ADMIN_API, alternatives = "GET ${contextPath:nacos}/v3/admin/ns/service")
Copy link
Collaborator

Choose a reason for hiding this comment

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

左边的API确实是console的API, 已经上Compatibility且不是ADMIN的API不需要再添加了。

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@@ -112,7 +113,7 @@ public InstanceController() {
@PostMapping
@TpsControl(pointName = "NamingInstanceRegister", name = "HttpNamingInstanceRegister")
@Secured(action = ActionTypes.WRITE)
@Compatibility(apiType = ApiType.OPEN_API)
@Compatibility(apiType = ApiType.ADMIN_API, alternatives = "POST ${contextPath:nacos}/v3/admin/ns/instance")
Copy link
Collaborator

Choose a reason for hiding this comment

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

这个应该是OPEN_API吧

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@KomachiSion KomachiSion merged commit 42a7110 into alibaba:v3.0-develop Jan 14, 2025
1 check passed
@KomachiSion KomachiSion added the Nacos3.0 Nacos 3.0 Architecture Evolution label Jan 14, 2025
@KomachiSion KomachiSion modified the milestones: 2.5.0, 3.0.0 Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Nacos3.0 Nacos 3.0 Architecture Evolution
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants