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

SavedObjectAttribute allow array of primitives #47317

Merged
merged 2 commits into from
Oct 8, 2019

Conversation

rudolf
Copy link
Contributor

@rudolf rudolf commented Oct 4, 2019

Summary

Changes the SavedObjectAttribute type to be more useful for other API's which accept method paramaters of the form (key: string, value: SavedObjectAttribute) see #47018 (comment)

Checklist

Use strikethroughs to remove checklist items you don't feel are applicable to this PR.

For maintainers

@rudolf rudolf added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Feature:New Platform labels Oct 4, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-platform (Team:Platform)

@rudolf rudolf force-pushed the saved-object-attribute-type branch from ce9cf7f to f4245e0 Compare October 4, 2019 10:20
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

@rudolf rudolf marked this pull request as ready for review October 4, 2019 15:20
@rudolf rudolf requested a review from a team as a code owner October 4, 2019 15:20
@rudolf rudolf added the release_note:skip Skip the PR/issue when compiling release notes label Oct 4, 2019
Copy link
Contributor

@eliperelman eliperelman left a comment

Choose a reason for hiding this comment

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

Looks good.

@@ -43,26 +43,33 @@ export interface SavedObjectsMigrationVersion {
}

/**
* Don't use this type, it's simply a helper type for {@link SavedObjectAttribute}
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to remove the @public annotation to assist with this?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah that was my first attempt, but then it also gets excluded from our generated docs and in effect a user reading the docs is left with just export type SavedObjectAttribute = SavedObjectAttributeSingle | SavedObjectAttributeSingle[]; which isn't very useful :(

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

@rudolf rudolf merged commit f0f75fc into elastic:master Oct 8, 2019
@rudolf rudolf deleted the saved-object-attribute-type branch October 8, 2019 14:41
rudolf added a commit to rudolf/kibana that referenced this pull request Oct 8, 2019
cqliu1 pushed a commit to cqliu1/kibana that referenced this pull request Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:New Platform release_note:skip Skip the PR/issue when compiling release notes Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v7.5.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants