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

[ftr/webdriver] retry on all errors, use Rx so that timers are canceled #72540

Merged

Conversation

spalger
Copy link
Contributor

@spalger spalger commented Jul 20, 2020

In an attempt to prevent webdriver startup errors caused by unexpected delays we auto-recreate the webdriver instance if it doesn't startup within 30 seconds. We see additional failures starting webdriver though, where chrome just doesn't start correctly as expected (example).

This PR updates the wrapping logic to use RxJS (primarily so that timers are canceled appropriately) and update the timeout logic to create errors, and then retry the webdriver creation any time we receive an error (after logging the error).

It will retry in a loop for serious failures until the two minute timeout is reached and then exit with a timeout error.

@spalger spalger added Team:Operations Team label for Operations Team v8.0.0 release_note:skip Skip the PR/issue when compiling release notes v7.10.0 v7.9.0 v7.8.1 labels Jul 20, 2020
@spalger spalger force-pushed the implement/catch-webdriver-build-errors branch from ecf812a to 8fcfc6f Compare July 20, 2020 21:39
@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Build metrics

✅ unchanged

History

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

@spalger spalger marked this pull request as ready for review July 21, 2020 03:32
@spalger spalger requested a review from a team as a code owner July 21, 2020 03:32
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-operations (Team:Operations)

@spalger spalger merged commit a1753ff into elastic:master Jul 21, 2020
spalger added a commit to spalger/kibana that referenced this pull request Jul 21, 2020
…ed (elastic#72540)

* [ftr/webdriver] retry on all errors, use Rx so that timers are canceled

* throw if attemptToCreateCommand() aborts by resolving to undefined

Co-authored-by: spalger <spalger@users.noreply.github.com>
spalger added a commit to spalger/kibana that referenced this pull request Jul 21, 2020
…ed (elastic#72540)

* [ftr/webdriver] retry on all errors, use Rx so that timers are canceled

* throw if attemptToCreateCommand() aborts by resolving to undefined

Co-authored-by: spalger <spalger@users.noreply.github.com>
spalger pushed a commit to spalger/kibana that referenced this pull request Jul 21, 2020
…ed (elastic#72540)

* [ftr/webdriver] retry on all errors, use Rx so that timers are canceled

* throw if attemptToCreateCommand() aborts by resolving to undefined

Co-authored-by: spalger <spalger@users.noreply.github.com>
# Conflicts:
#	test/functional/services/remote/webdriver.ts
spalger added a commit that referenced this pull request Jul 21, 2020
…canceled (#72540) (#72565)

Co-authored-by: spalger <spalger@users.noreply.github.com>
spalger added a commit that referenced this pull request Jul 21, 2020
…canceled (#72540) (#72566)

* [ftr/webdriver] retry on all errors, use Rx so that timers are canceled

* throw if attemptToCreateCommand() aborts by resolving to undefined

Co-authored-by: spalger <spalger@users.noreply.github.com>

Co-authored-by: spalger <spalger@users.noreply.github.com>
spalger pushed a commit that referenced this pull request Jul 21, 2020
…canceled (#72540) (#72567)

* [ftr/webdriver] retry on all errors, use Rx so that timers are canceled

* throw if attemptToCreateCommand() aborts by resolving to undefined

Co-authored-by: spalger <spalger@users.noreply.github.com>
# Conflicts:
#	test/functional/services/remote/webdriver.ts
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jul 21, 2020
* master: (28 commits)
  allow some env settings for ingest manager (elastic#72544)
  Add inspector for VEGA (elastic#70941)
  chore(NA): fix grunt task for test:coverage (elastic#72539)
  Archive e2e test results in ES (elastic#72575)
  preserve 401 errors from new es client (elastic#71248)
  [SIEM][Detections] Updates text for severity and risk_score overrides  (elastic#72244)
  fixing error occurences tooltip (elastic#72425)
  use KibanaClient interface instead of Client for new client interface (elastic#72388)
  [APM] Handle ML errors (elastic#72316)
  [Discover] Improve histogram tests (elastic#72235)
  [ftr/webdriver] retry on all errors, use Rx so that timers are canceled (elastic#72540)
  [pre-req] Move .storybook to storybook; standardize files (elastic#72384)
  [Security_Solution][Resolver][Bug]: Restore breadcrumb background (elastic#72538)
  [ML] Fix annotation detector linking & delayed_data(0) (elastic#72468)
  [Security Solution][Exceptions] - Make esTypes and subType available to index patterns (elastic#72336)
  [SIEM] Uses faster wait from testing-library and removes duplicate older wait idiom (elastic#72509)
  Fix long combo box items breaking out of flex item width (elastic#72512)
  [pipeline/commitStatus] update commit status in baseline-capture job (elastic#72366)
  [Security Solution][Resolver] Update the resolver element ref on scroll events if the position of the element has changed within the page (elastic#72461)
  [Maps] auto-fit to data bounds (elastic#72129)
  ...
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jul 21, 2020
…feature-privileges

* alerting/consumer-based-rbac: (30 commits)
  removed uneeded tests
  expclude security wrapper in SO client passed to ActionsClient
  allow some env settings for ingest manager (elastic#72544)
  Add inspector for VEGA (elastic#70941)
  chore(NA): fix grunt task for test:coverage (elastic#72539)
  Archive e2e test results in ES (elastic#72575)
  preserve 401 errors from new es client (elastic#71248)
  [SIEM][Detections] Updates text for severity and risk_score overrides  (elastic#72244)
  fixing error occurences tooltip (elastic#72425)
  use KibanaClient interface instead of Client for new client interface (elastic#72388)
  [APM] Handle ML errors (elastic#72316)
  [Discover] Improve histogram tests (elastic#72235)
  [ftr/webdriver] retry on all errors, use Rx so that timers are canceled (elastic#72540)
  [pre-req] Move .storybook to storybook; standardize files (elastic#72384)
  [Security_Solution][Resolver][Bug]: Restore breadcrumb background (elastic#72538)
  [ML] Fix annotation detector linking & delayed_data(0) (elastic#72468)
  [Security Solution][Exceptions] - Make esTypes and subType available to index patterns (elastic#72336)
  [SIEM] Uses faster wait from testing-library and removes duplicate older wait idiom (elastic#72509)
  Fix long combo box items breaking out of flex item width (elastic#72512)
  [pipeline/commitStatus] update commit status in baseline-capture job (elastic#72366)
  ...
@spalger spalger deleted the implement/catch-webdriver-build-errors branch August 18, 2020 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:skip Skip the PR/issue when compiling release notes Team:Operations Team label for Operations Team v7.8.1 v7.9.0 v7.10.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants