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

Connection timeout + check API integration #108

Merged
merged 4 commits into from
Sep 14, 2023

Conversation

matthewhilton
Copy link
Contributor

@matthewhilton matthewhilton commented Sep 7, 2023

TLDR

Changes

  • Configurable Guzzle http timeout set to default 5 seconds.
  • Refactored the engine status check to provide better error messages (e.g. URL gave http code XYZ)
  • Implemented check API https://moodledev.io/docs/apis/subsystems/check
  • Created admin setting which takes in a check class and displays it nicely. (Note this will eventually be integrated a bit nicer likely with ajax in core https://tracker.moodle.org/browse/MDL-67898)
  • This check now only runs when you are viewing the full tree (i.e. not searching) and when you are on the elasticsearch config page. Since it can take up to the timeout (5 seconds default) - we don't want this running when viewing other pages, etc...

Screenshots

See #108 (comment)

@matthewhilton matthewhilton marked this pull request as draft September 7, 2023 05:22
@matthewhilton matthewhilton force-pushed the settings-check-api-310 branch 2 times, most recently from 95baffc to bfc72e8 Compare September 8, 2023 00:55
@matthewhilton matthewhilton changed the title WIP - check API with check api admin setting Connection timeout + check API integration Sep 8, 2023
@matthewhilton matthewhilton marked this pull request as ready for review September 8, 2023 02:05
@matthewhilton matthewhilton merged commit 4c2e4db into MOODLE_310_STABLE Sep 14, 2023
14 checks passed
@matthewhilton matthewhilton deleted the settings-check-api-310 branch September 14, 2023 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The status check should only occur on the settings page itself Add timeout for requests
2 participants