git-updater: GitLab Webhook Timeout Issues
Following the wiki at restful-endpoints-for-remote-management everything works as described (eg. curl related calls). When I push (test or not) to the Gitlab repository the webhook/integration trigger is triggered I get the above mentioned error: Hook execution failed: Net::ReadTimeout
Request URL: POST http://www.domainame.com/wp-admin/admin-ajax.php?action=github-updater-update&key=76bb2b7c819c36ee37292b6978a4ad61&theme=theme-name [internal error]
Trigger: Push Hook
Elapsed time: 3.29 sec
instead using this testing REST endpoint
Request URL: POST http://webhook.site/d6eb13a3-82a5-4385-abc6-91822f508b35 [200]
Trigger: Tag Push Hook
Elapsed time: 0.35 sec
from the GitLab documentation about webhooks, I read:
Your endpoint should send its HTTP response as fast as possible. If you wait too long, GitLab may decide the hook failed and retry it.
Surfing the net i found this other similiar issue (which makes me think that there is a timeout after 3 seconds…)
Is it possible that this is also due to wordpress performance limits? (eg. minimum response time) if so, it would be almost impossible to use this feature with the online version of GitLab…
Any way, thanks for the effort!
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 44 (43 by maintainers)
Commits related to this issue
- add function log_exit() append $response to debug.log and wp_die() — committed to afragen/git-updater by afragen 6 years ago
- Added FAQ tab — committed to Raruto/github-updater by Raruto 6 years ago
To test, I edited “sample_file.txt” within gitlab.com editor.
Request details
Request URL: <domain_name>?action=github-updater-update&key=<key>&theme=<name>
Trigger: Push Hook
Elapsed time: 3.33 sec
Net::ReadTimeout
Request Headers
Request Body
Response headers:
<no info>
Response body:<no info>
debug.log
After this, I can successfully see the updated file within wordpress.