Skip to content

[Reporting] Convert plugin setup and start to synchronous#68326

Merged
tsullivan merged 13 commits intoelastic:masterfrom
tsullivan:reporting/setup-nsyncified
Jun 11, 2020
Merged

[Reporting] Convert plugin setup and start to synchronous#68326
tsullivan merged 13 commits intoelastic:masterfrom
tsullivan:reporting/setup-nsyncified

Conversation

@tsullivan
Copy link
Copy Markdown
Member

@tsullivan tsullivan commented Jun 4, 2020

Summary

Close #68292

  • Removes x-pack/plugins/reporting/server/browsers/create_browser_driver_factory.ts. The function had to be broken up. Afterwards, it's not useful as a wrapper helper function.

Checklist

Delete any items that are not applicable to this PR.

For maintainers

@tsullivan tsullivan changed the title make downstream not depend on installBrowser [Reporting] prevent installBrowser from blocking setup Jun 4, 2020
Copy link
Copy Markdown
Member Author

@tsullivan tsullivan Jun 4, 2020

Choose a reason for hiding this comment

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

Previously, the BrowserDownload interface wasn't being instantiated anywhere. Once I instantiated a variable as this interface, adding this createDriverFactory field was necessary.

@tsullivan tsullivan force-pushed the reporting/setup-nsyncified branch 2 times, most recently from 8657ab2 to 5f6c6a6 Compare June 4, 2020 23:31
@tsullivan tsullivan changed the title [Reporting] prevent installBrowser from blocking setup [Reporting] Convert plugin setup and start to synchronous Jun 4, 2020
@tsullivan tsullivan force-pushed the reporting/setup-nsyncified branch 4 times, most recently from 294bc3a to af636ab Compare June 5, 2020 00:09
@tsullivan tsullivan force-pushed the reporting/setup-nsyncified branch from af636ab to 9e654f1 Compare June 5, 2020 02:00
@tsullivan tsullivan requested review from a team June 5, 2020 21:45
@tsullivan
Copy link
Copy Markdown
Member Author

There is still a TODO for testing on this, but it is ready for review

@tsullivan tsullivan marked this pull request as ready for review June 6, 2020 01:06
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/kibana-reporting-services (Team:Reporting Services)

@tsullivan
Copy link
Copy Markdown
Member Author

@elasticmachine merge upstream

Copy link
Copy Markdown
Contributor

@spalger spalger left a comment

Choose a reason for hiding this comment

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

Not quite sure what to verify here, but I don't see any obvious issues from an operations perspective.

@joelgriffith
Copy link
Copy Markdown
Contributor

I'm happy with the changes here, let's let platform folks give final approval and then we should be good to merge

@tsullivan tsullivan requested a review from jbudz June 10, 2020 20:53
@tsullivan
Copy link
Copy Markdown
Member Author

@elasticmachine merge upstream

@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

History

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

runValidations(config, elasticsearch, browserDriverFactory, this.logger);

this.logger.debug('Start complete');
this.start$.next(true);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Does someone read them?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This is just for a unit test

@tsullivan tsullivan merged commit ebff420 into elastic:master Jun 11, 2020
@tsullivan tsullivan deleted the reporting/setup-nsyncified branch June 11, 2020 17:53
tsullivan added a commit to tsullivan/kibana that referenced this pull request Jun 11, 2020
)

* [Reporting] Convert plugin setup and start to synchronous

* revert class conversion

* diff prettify

* Fix test mocks + add some plugin async helpers where needed

* no setupReady startReady needed

* Add plugin test for sync/error cases

* PR feedback on tests/setup logs

* rename symbol

Co-authored-by: Joel Griffith <joel.griffith@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
tsullivan added a commit that referenced this pull request Jun 11, 2020
…68932)

* [Reporting] Convert plugin setup and start to synchronous

* revert class conversion

* diff prettify

* Fix test mocks + add some plugin async helpers where needed

* no setupReady startReady needed

* Add plugin test for sync/error cases

* PR feedback on tests/setup logs

* rename symbol

Co-authored-by: Joel Griffith <joel.griffith@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

Co-authored-by: Joel Griffith <joel.griffith@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
@sophiec20 sophiec20 added the zDeprecated Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead label Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature:NP Migration release_note:skip Skip the PR/issue when compiling release notes v7.9.0 v8.0.0 zDeprecated Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Reporting] Plugin lifecycle setup step needs to be synchronous

7 participants