Skip to content

[Guided onboarding] Change the saved objects' type to hidden#148983

Merged
yuliacech merged 7 commits intoelastic:mainfrom
yuliacech:guided_onboarding/8.7/hidden_saved_objects
Feb 6, 2023
Merged

[Guided onboarding] Change the saved objects' type to hidden#148983
yuliacech merged 7 commits intoelastic:mainfrom
yuliacech:guided_onboarding/8.7/hidden_saved_objects

Conversation

@yuliacech
Copy link
Contributor

@yuliacech yuliacech commented Jan 16, 2023

Summary

Making the saved objects hidden will prevent other plugins accidentally updating the guided onboarding data directly via the SO client. This was recommended by the Core team and I think it should be safe to change the type since there should not be any existing SO in deployments prior to 8.7 yet.

@yuliacech yuliacech requested a review from a team as a code owner January 16, 2023 16:08
@yuliacech yuliacech added release_note:skip Skip the PR/issue when compiling release notes Team:Journey/Onboarding Platform Journey Onboarding team v8.7.0 labels Jan 16, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/platform-onboarding (Team:Journey/Onboarding)

@yuliacech
Copy link
Contributor Author

I'm putting this PR in draft because we can't currently create/update SO with the test client in functional tests, but a PR for this issue might be a solution for that.

@yuliacech yuliacech marked this pull request as draft January 19, 2023 11:30
@TinaHeiligers
Copy link
Contributor

can't currently create/update SO with the test client in functional tests

FWIW, right now, you can use es directly in your tests. Take a look at the testing setup other SO type owners use when their types are hidden. For example: cases.

Oh, and now you also have the option of only hiding a type from the HTTP APIs if you won't really benefit from implementing your own SO client.

@yuliacech
Copy link
Contributor Author

Thanks for the info, @TinaHeiligers! It looks like the new plugin merged in #149188 did the trick though, I run the tests locally and everything passed, will see if the CI does the same.

@yuliacech yuliacech marked this pull request as ready for review January 26, 2023 14:39
@yuliacech yuliacech requested review from a team and claracruz January 26, 2023 15:14
@yuliacech
Copy link
Contributor Author

@elastic/kibana-core hey team, could someone please confirm that it's safe to change saved objects used in the guided onboarding plugin to hidden: true? The plugin has not been released yet, so I don't think there should be any issues with migration.

Copy link
Contributor

@TinaHeiligers TinaHeiligers left a comment

Choose a reason for hiding this comment

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

Code LGTM. There shouldn't be an issue ith migrations. Changing saved object type to hidden is what we're recommending.
The issue with migrations comes when you want to change an existing saved object attribute, although it's best to confirm with @rudolf

@yuliacech yuliacech enabled auto-merge (squash) January 30, 2023 11:23
@kibana-ci
Copy link

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

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

@yuliacech yuliacech merged commit 867a552 into elastic:main Feb 6, 2023
@kibanamachine kibanamachine added the backport:skip This PR does not require backporting label Feb 6, 2023
@yuliacech yuliacech deleted the guided_onboarding/8.7/hidden_saved_objects branch February 15, 2024 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Journey/Onboarding Platform Journey Onboarding team v8.7.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants