Move license constants from /server to /common#32723
Move license constants from /server to /common#32723jen-huang merged 4 commits intoelastic:masterfrom
/server to /common#32723Conversation
|
Pinging @elastic/es-ui |
cjcenizal
left a comment
There was a problem hiding this comment.
Code LGTM! Didn't test locally.
| * you may not use this file except in compliance with the Elastic License. | ||
| */ | ||
|
|
||
| export const LICENSE_TYPE_OSS = 'oss'; |
There was a problem hiding this comment.
Just out of curiosity, how is it possible for there to be an OSS license type if the OSS distribution ships without X-Pack?
There was a problem hiding this comment.
I don't think it is possible 🙂 I added this for the sake of completeness, and because I saw oss included in a similar export from beats management
There was a problem hiding this comment.
👍 I think it might be worth checking in with them and making sure that wasn't a mistake, so we can avoid propagating it if it was.
There was a problem hiding this comment.
I just checked with @mattapperson and oss was included intentionally at the time to support a "read only" mode if the user downgrades. however, plans for that support haven't really moved, so it's not necessary to declare oss here for the time being. we can always add it when it's actually needed. thanks for calling this out, @cjcenizal, I've pushed an update that removes the oss declaration
| export const LICENSE_TYPE_PLATINUM = 'platinum'; | ||
| export const LICENSE_TYPE_TRIAL = 'trial'; | ||
|
|
||
| export type LicenseType = |
There was a problem hiding this comment.
This is cool! I just learned something new.
💚 Build Succeeded |
💔 Build Failed |
💚 Build Succeeded |
* Move license constants to /common * Fix export * Use constant for required license type * Remove OSS from license types
This PR moves license constants from
serverdirectory tocommonand exports a new typing,LicenseType. I used the new typing for the new snapshot and restore plugin boilerplate, but it felt disjointed from the rest of the license constants, and it felt wrong to import fromserverfor non-server usages. Moving everything tocommonwill let us use license exports everywhere.