Skip to content

Parallelize independent wordpress-setup tasks - #1664

Draft
retlehs wants to merge 1 commit into
masterfrom
wordpress-setup-async-tags
Draft

Parallelize independent wordpress-setup tasks#1664
retlehs wants to merge 1 commit into
masterfrom
wordpress-setup-async-tags

Conversation

@retlehs

@retlehs retlehs commented Apr 27, 2026

Copy link
Copy Markdown
Member

This experiments with task-level parallelism in wordpress-setup for independent per-site work:

  • run local database creation asynchronously per site, then wait before DB grants
  • run self-signed certificate generation asynchronously per site, then wait before cleanup and Nginx config
  • build a unique client certificate download list and download client certs asynchronously
  • keep DB user grants, PHP-FPM config, and Nginx config serialized to avoid shared-resource conflicts

The goal is to reduce provision time for projects with multiple sites or SSL/client-cert work without changing the observable provisioning order of shared services

Notes

This intentionally avoids role-level parallelism. wordpress-setup still waits before touching shared Nginx/PHP-FPM state, and DB grants remain serial because multiple sites may share a DB user.

Async behavior is controlled by:

  • wordpress_setup_async_timeout
  • wordpress_setup_async_poll_delay
  • wordpress_setup_async_retries

Validation Needed

  • Run before/after benchmarks for local development provisioning
  • Run before/after benchmarks for production/server provisioning
  • Test against a fresh local VM
  • Test against a fresh remote server
  • Confirm repeat provisioning remains idempotent
  • Confirm multi-site configs behave correctly, especially with local DBs and self-signed SSL

@retlehs retlehs self-assigned this Apr 27, 2026
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.

1 participant