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

fix the multi-level subgroup issue #23831

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

yhwang
Copy link
Member

@yhwang yhwang commented Oct 15, 2024

Description

Update the ResourceGroupView component
to properly display a subgroup that is in
3rd or more level deep.

fix: #23829

Motivation and Context

fix the issue #23829

Impact

be able to show a subgroup in 3rd or more level deep.

Test Plan

Create a resource group settings:

{
  "rootGroups": [
    {
      "name": "global",
      "softMemoryLimit": "80%",
      "hardConcurrencyLimit": 100,
      "maxQueued": 1000,
      "schedulingPolicy": "weighted",
      "jmxExport": true,
      "subGroups": [
        {
          "name": "data_definition",
          "softMemoryLimit": "10%",
          "hardConcurrencyLimit": 5,
          "maxQueued": 100,
          "schedulingWeight": 1
        },
        {
          "name": "adhoc",
          "softMemoryLimit": "10%",
          "hardConcurrencyLimit": 50,
          "maxQueued": 1,
          "schedulingWeight": 10,
          "subGroups": [
            {
              "name": "other",
              "softMemoryLimit": "10%",
              "hardConcurrencyLimit": 2,
              "maxQueued": 1,
              "schedulingWeight": 10,
              "schedulingPolicy": "weighted_fair",
              "subGroups": [
                {
                  "name": "${USER}",
                  "softMemoryLimit": "10%",
                  "hardConcurrencyLimit": 1,
                  "maxQueued": 100
                }
              ]
            },
            {
              "name": "console",
              "softMemoryLimit": "10%",
              "hardConcurrencyLimit": 10,
              "maxQueued": 100,
              "schedulingWeight": 10,
              "schedulingPolicy": "weighted_fair"
            }
          ]
        }
      ]
    },
    {
      "name": "admin",
      "softMemoryLimit": "100%",
      "hardConcurrencyLimit": 50,
      "maxQueued": 100,
      "schedulingPolicy": "query_priority",
      "jmxExport": true
    }
  ],
  "selectors": [
    {
      "user": "bob",
      "group": "admin"
    },
    {
      "source": "presto-js-client",
      "user": "prestoui",
      "group": "global.adhoc.console"
    },
    {
      "group": "global.adhoc.other.${USER}"
    }
  ],
  "cpuQuotaPeriod": "1h"
}

use the `SQL Client` to run some queries. those queries are categorized as the `global.adhoc.console` resource group. When checking the `console` subgroup. it shall show the statistics.

Contributor checklist

  • Please make sure your submission complies with our development, formatting, commit message, and attribution guidelines.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

Please follow release notes guidelines and fill in the release notes below.

== NO RELEASE NOTE ==

Update the `ResourceGroupView` component
to properly display a subgroup which is in
3rd or more level.

Signed-off-by: Yihong Wang <yh.wang@ibm.com>
@yhwang yhwang requested a review from a team as a code owner October 15, 2024 03:19
@yhwang
Copy link
Member Author

yhwang commented Oct 15, 2024

Before the fix:
image

After the fix, it can show the console subgroup:
image

@tdcmeehan tdcmeehan merged commit bee3c6e into prestodb:master Oct 15, 2024
56 checks passed
@yhwang yhwang deleted the fix-subgroup-resource-group-page branch October 15, 2024 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The RESOURCE GROUPS page can't access subgroup defined in 3rd or more depth level
2 participants