kriszyp / msgpackr

Ultra-fast MessagePack implementation with extension for record and structural cloning / msgpack.org[JavaScript/NodeJS]
MIT License
479 stars 51 forks source link

is it thread safe when use threads_worker #121

Closed introspection3 closed 2 months ago

introspection3 commented 11 months ago

is it thread safe when use threads_worker

kriszyp commented 11 months ago

Yes, it is safe to use with worker_threads.

introspection3 commented 11 months ago

Yes, it is safe to use with worker_threads.

can we use it async??

kriszyp commented 11 months ago

You can use msgpackr with asynchronous code. The msgpackr functions themselves do not have asynchronous APIs, they immediately execute, and there is no meaningful off-thread work that they can do asynchronously.