hexo-util icon indicating copy to clipboard operation
hexo-util copied to clipboard

feat(workerpool): bring up

Open SukkaW opened this issue 4 years ago • 5 comments

The PR is a part of hexojs/hexo#4355.

Bring up a utility to manage workers and job queue.

SukkaW avatar Jun 12 '20 06:06 SukkaW

Coverage Status

Coverage decreased (-0.9%) to 96.058% when pulling eab4d622548453bf8c98057e97f6fa176b6571f1 on SukkaW:worker-pool into f9694976ad9642213545f42dcf4f44cae2f8efbc on hexojs:master.

coveralls avatar Jun 12 '20 06:06 coveralls

Minimum required Node.js version has bumped to 12.13, which is the first LTS version of Node.js 12: https://nodejs.org/en/blog/release/v12.13.0/

SukkaW avatar Jun 20 '20 10:06 SukkaW

@curbengh We might not bring up Worker Threads during Hexo 5.0.0 development. So we can leave this PR here until we officially drop Node.js 12.

SukkaW avatar Jul 23 '20 07:07 SukkaW

Any updates on this thread?

stevenjoezhang avatar Nov 25 '22 12:11 stevenjoezhang

After some benchmarking, multi-thread could actually hurt the performance for most of the hexo site, as serializing objects between the main thread and the worker thread would introduce too much overhead.

SukkaW avatar Nov 25 '22 12:11 SukkaW

There are already many worker pool implementations out there that are better than my home-baked one. Even if Hexo is going to adapt multi-thread, we will use those libraries instead.

SukkaW avatar Apr 24 '24 09:04 SukkaW