EXPERIMENTAL: Workers allows you to register a worker.
| 7 | |
| 8 | // EXPERIMENTAL: Workers allows you to register a worker. |
| 9 | type Workers interface { |
| 10 | // SendRequest calls the closure passed to frankenphp_handle_request() and updates the PHP context . |
| 11 | // The generated HTTP response will be written through the provided writer. |
| 12 | SendRequest(rw http.ResponseWriter, r *http.Request) error |
| 13 | // SendMessage calls the closure passed to frankenphp_handle_request(), passes message as a parameter, and returns the value produced by the closure. |
| 14 | SendMessage(ctx context.Context, message any, rw http.ResponseWriter) (any, error) |
| 15 | // NumThreads returns the number of available threads. |
| 16 | NumThreads() int |
| 17 | } |
| 18 | |
| 19 | type extensionWorkers struct { |
| 20 | name string |
no outgoing calls
no test coverage detected