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

Explore: Compiling Blueprints to independent PHP files #55

Open
adamziel opened this issue Feb 29, 2024 · 0 comments
Open

Explore: Compiling Blueprints to independent PHP files #55

adamziel opened this issue Feb 29, 2024 · 0 comments

Comments

@adamziel
Copy link
Collaborator

Executing Blueprint steps often involves spawning subprocesses, e.g. to activate a WordPress plugin in an independent environment that can crash without crashing the main PHP process.

However, in runtime like Playground, spawning a PHP sub-process might be expensive as it would require allocating twice the HEAP inside the browser and potentially require downloading PHP.wasm again.

Let's test the performance of in-browser sub-processes, and if it's bad, then Blueprints could be compiled as follows:

  1. Run PHP to turn a Blueprint into a series of smaller PHP files like step0.php, step1.php etc.
  2. Each file is an isolated container and is free to, e.g., include wp-load.php
  3. TypeScript runtime would run those files one by one. The PHP runtime would do the same thing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant