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

[Fleet] Render extension component after initializing package policy #150096

Merged
merged 2 commits into from
Feb 1, 2023

Conversation

orouz
Copy link
Contributor

@orouz orouz commented Feb 1, 2023

Summary

extracted from #149137 (comment):

sometimes validationErrors and packagePolicy goes out of sync: Screen Shot 2023-01-30 at 19 46 02

this happens when our extension component fires an effect on mount to initialize the package policy before fleet's effect (init())

making this property stateful makes the extension component render only after fleet's effect has fired, which sorts out the ordering.

still kinda odd they are not in sync tho, even if fleet's effect fires last, i'd expect the policy to be changed as well. you can check the logs and reproduce this on env by going to the install page -> canceling and going in again

@nchaulet

Checklist

Delete any items that are not applicable to this PR.

Risk Matrix

Delete this section if it is not applicable to this PR.

Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.

When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:

Risk Probability Severity Mitigation/Notes
Multiple Spaces—unexpected behavior in non-default Kibana Space. Low High Integration tests will verify that all features are still supported in non-default Kibana Space and when user switches between spaces.
Multiple nodes—Elasticsearch polling might have race conditions when multiple Kibana nodes are polling for the same tasks. High Low Tasks are idempotent, so executing them multiple times will not result in logical error, but will degrade performance. To test for this case we add plenty of unit tests around this logic and document manual testing procedure.
Code should gracefully handle cases when feature X or plugin Y are disabled. Medium High Unit tests will verify that any feature flag or plugin combination still results in our service operational.
See more potential risk examples

For maintainers

@orouz orouz added release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting v8.7.0 labels Feb 1, 2023
@orouz orouz requested a review from nchaulet February 1, 2023 18:48
@orouz orouz marked this pull request as ready for review February 1, 2023 18:49
@orouz orouz requested a review from a team as a code owner February 1, 2023 18:49
Copy link
Member

@nchaulet nchaulet left a comment

Choose a reason for hiding this comment

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

LGTM! thanks for fixing that

@botelastic botelastic bot added the Team:Fleet Team label for Observability Data Collection Fleet team label Feb 1, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@orouz orouz enabled auto-merge (squash) February 1, 2023 19:50
@kibana-ci
Copy link
Collaborator

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #41 / Alerting eventLog alerts should generate expected alert events for normal operation
  • [job] [logs] FTR Configs #42 / Reporting APIs Usage Usage Counters API counters: management job info

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
fleet 925.4KB 925.5KB +29.0B

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
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v8.7.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants