(worker *worker)
| 74 | } |
| 75 | |
| 76 | func addWorkerThread(worker *worker) (*phpThread, error) { |
| 77 | thread := getInactivePHPThread() |
| 78 | if thread == nil { |
| 79 | return nil, ErrMaxThreadsReached |
| 80 | } |
| 81 | convertToWorkerThread(thread, worker) |
| 82 | thread.state.WaitFor(state.Ready, state.ShuttingDown, state.Reserved) |
| 83 | return thread, nil |
| 84 | } |
| 85 | |
| 86 | // scaleWorkerThread adds a worker PHP thread automatically |
| 87 | func scaleWorkerThread(worker *worker, done chan struct{}, mstate *state.ThreadState) { |
no test coverage detected