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

scheduler: fix panic in system jobs when nodes filtered by class #11565

Merged
merged 1 commit into from
Nov 24, 2021

Commits on Nov 24, 2021

  1. scheduler: fix panic in system jobs when nodes filtered by class

    In the system scheduler, if a subset of clients are filtered by class,
    we hit a code path where the `AllocMetric` has been copied, but the
    `Copy` method does not instantiate the various maps. This leads to an
    assignment to a nil map. This changeset ensures that the maps are
    non-nil before continuing.
    
    The `Copy` method relies on functions in the `helper` package that all
    return nil slices or maps when passed zero-length inputs. This
    changeset to fix the panic bug intentionally defers updating those
    functions because it'll have potential impact on memory usage. See
    #11564 for more details.
    tgross committed Nov 24, 2021
    Configuration menu
    Copy the full SHA
    6adc0b9 View commit details
    Browse the repository at this point in the history