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

[ML] Fixing licensing after server NP cutover #59275

Conversation

jgowdyelastic
Copy link
Member

@jgowdyelastic jgowdyelastic commented Mar 4, 2020

A new version of #58853 which had to be reverted due to issues with licensing in functional tests.

Reenables the license checking for server and client sides after server side cutover (#58680)

A shared common mlLicense class has been added which listens to the licensing updates from the licensing plugin.
The server and client then have specialised derived classes which add on checks specific to their needs
Server side

  • API guards for basic and full (trial, platinum or enterprise) license types.
    Basic enabled endpoints:
    /api/ml/fields_service/time_field_range
    /api/ml/file_data_visualizer/analyze_file
    /api/ml/file_data_visualizer/import
    /api/ml/_has_privileges
    /api/ml/ml_capabilities
    /api/ml/ml_node_count
    /api/ml/info
    /api/ml/data_visualizer/get_field_stats/{indexPatternTitle}
    /api/ml/data_visualizer/get_overall_stats/{indexPatternTitle}

Client side:

  • Router resolver checks which are called when rendering each page. All pages related to the file and index datavisualizers require a minimum of a basic license.
  • hasLicenseExpired and isFullLicense general functions which are used in a few places throughout our UI.

Also fixes the management plugin which was being disabled due to its licensing check.

Checklist

Delete any items that are not applicable to this PR.

For maintainers

@jgowdyelastic jgowdyelastic added :ml non-issue Indicates to automation that a pull request should not appear in the release notes release_note:skip Skip the PR/issue when compiling release notes review v7.7.0 v8.0.0 labels Mar 4, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@jgowdyelastic jgowdyelastic marked this pull request as ready for review March 4, 2020 08:21
@jgowdyelastic jgowdyelastic requested a review from a team as a code owner March 4, 2020 08:21
@jgowdyelastic jgowdyelastic self-assigned this Mar 4, 2020
Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@walterra walterra left a comment

Choose a reason for hiding this comment

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

LGTM

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:ml non-issue Indicates to automation that a pull request should not appear in the release notes release_note:skip Skip the PR/issue when compiling release notes review v7.7.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants