Skip to content

[http][manager] Add manager related http interface.#6396

Merged
morningman merged 2 commits intoapache:masterfrom
luozenglin:manager_interface
Aug 10, 2021
Merged

[http][manager] Add manager related http interface.#6396
morningman merged 2 commits intoapache:masterfrom
luozenglin:manager_interface

Conversation

@luozenglin
Copy link
Contributor

Proposed changes

Encapsulate some http interfaces for better management and maintenance of doris clusters.

The http interface includes getting cluster connection information, node information, node configuration information, batch modifying node configuration, and getting query profile.

For details, please refer to the document:
docs/zh-CN/administrator-guide/http-actions/fe/manager/

Types of changes

What types of changes does your code introduce to Doris?
Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices apply)
  • Code refactor (Modify the code structure, format the code, etc...)
  • Optimization. Including functional usability improvements and performance improvements.
  • Dependency. Such as changes related to third-party components.
  • Other.

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have created an issue on (Fix #ISSUE) and described the bug/feature there in detail
  • Compiling and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • If these changes need document changes, I have updated the document
  • Any dependent changes have been merged

Further comments

If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...

The http interface includes getting cluster connection information, node information, node configuration information, batch modifying node configuration, and getting query profile.
@morningman morningman added api-review Categorizes an issue or PR as actively needing an API review. area/manager kind/feature Categorizes issue or PR as related to a new feature. labels Aug 7, 2021

package org.apache.doris.common.profile;

import com.fasterxml.jackson.annotation.JsonProperty;
Copy link
Contributor

Choose a reason for hiding this comment

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

import order

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.

.collect(Collectors.toList());
}

static String concatUrl (Pair<String, Integer> ipPort, String path, Map<String, String> arguments) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
static String concatUrl (Pair<String, Integer> ipPort, String path, Map<String, String> arguments) {
static String concatUrl(Pair<String, Integer> ipPort, String path, Map<String, String> arguments) {

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.


package org.apache.doris.httpv2.rest.manager;

import com.fasterxml.jackson.annotation.JsonProperty;
Copy link
Contributor

Choose a reason for hiding this comment

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

import order

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.

public static final String AUTHORIZATION = "Authorization";
private static final int HTTP_WAIT_TIME_SECONDS = 2;

public static final String CONFIG = "配置项";
Copy link
Contributor

Choose a reason for hiding this comment

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

We should only return column name in English. The multilanguage support should be done in Manager Frontend.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe we can change it to English in a later version.


package org.apache.doris.httpv2.rest.manager;

import com.google.common.base.Strings;
Copy link
Contributor

Choose a reason for hiding this comment

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

import order

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.

Copy link
Contributor

@morningman morningman left a comment

Choose a reason for hiding this comment

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

LGTM

@github-actions
Copy link
Contributor

github-actions bot commented Aug 9, 2021

PR approved by at least one committer and no changes requested.

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Aug 9, 2021
@github-actions
Copy link
Contributor

github-actions bot commented Aug 9, 2021

PR approved by anyone and no changes requested.

@morningman morningman merged commit 0930e89 into apache:master Aug 10, 2021
EmmyMiao87 pushed a commit to EmmyMiao87/incubator-doris that referenced this pull request Nov 10, 2021
Encapsulate some http interfaces for better management and maintenance of doris clusters.

The http interface includes getting cluster connection information, node information, node configuration information, batch modifying node configuration, and getting query profile.

For details, please refer to the document:
`docs/zh-CN/administrator-guide/http-actions/fe/manager/`

Change-Id: I784eaeb572ecf1466bcfb7c540de8e0d06ff2842
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api-review Categorizes an issue or PR as actively needing an API review. approved Indicates a PR has been approved by one committer. area/manager kind/feature Categorizes issue or PR as related to a new feature. reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants