Skip to content

Documentation: mention bootstrap file for workers #201

Description

@vikingjs

It would have saved me a significant amount of time in development if I had known that I could supply a bootstrap file for workers. The documentation AND ERROR MESSAGES use "MUST be loadable by the composer class loader", which is not true. That guidance caused me to go through hoops when a simple one-line bootstrap file importing my autoloader would have sufficed.

Instead, all I had to do was:

	$workerFactory = new ContextWorkerFactory(__DIR__ . '/../Task/bootstrap.php');
	$this->workerPool ??= new ContextWorkerPool(50, $workerFactory);

I shouldn't have to stumble upon an important feature like that while reverse-engineering your library for another reason.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions