Skip to content

Commit

Permalink
feat: workerId (#30)
Browse files Browse the repository at this point in the history
* add workerId

* fix: workerId=undefined

* fix: node v18 ci

* docs
  • Loading branch information
Aslemammad committed Jun 23, 2022
1 parent f89283d commit ed5347e
Show file tree
Hide file tree
Showing 8 changed files with 3,985 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
node-version: [14.x, 16.x, 17.x]
node-version: [14.x, 16.x, 18.x]
runs-on: ${{matrix.os}}
steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ We have a similar API to Piscina, so for more information, you can read Piscina'
###### Additional Options
- `isolateWorkers`: Default to `false`. Always starts with a fresh worker when running tasks to isolate the environment.
- `workerId`: Each worker now has an id ( <= `maxThreads`) that can be imported
from `tinypool` in the worker itself (or `process.__tinypool_state__.workerId`)
## Credits
Expand Down

0 comments on commit ed5347e

Please sign in to comment.