https://github.com/yetanotherclown/threadpool
A library for creating Thread Pools to improve performance and reduce latency on Roblox.
https://github.com/yetanotherclown/threadpool
luau roblox roblox-library roblox-lua
Last synced: 3 months ago
JSON representation
A library for creating Thread Pools to improve performance and reduce latency on Roblox.
- Host: GitHub
- URL: https://github.com/yetanotherclown/threadpool
- Owner: YetAnotherClown
- License: mit
- Created: 2023-03-12T07:40:37.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-06-16T06:22:09.000Z (over 2 years ago)
- Last Synced: 2025-02-06T16:59:19.153Z (8 months ago)
- Topics: luau, roblox, roblox-library, roblox-lua
- Language: Lua
- Homepage: https://yetanotherclown.github.io/ThreadPool/
- Size: 615 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ThreadPool
A library for creating Thread Pools to improve performance and reduce latency.
---
#### Thread Pooling
Thread Pooling reuses already existing threads instead of creating new threads every time you need to use one.#### Why use this?
You shouldn't need to, unless you are creating multiple threads at a given time.#### Usage
```lua
local ThreadPool = Require(ReplicatedStorage.Packages.ThreadPool)local myThreadPool = ThreadPool.new()
myThreadPool:spawn(function(...)
print(...) -- Prints "Hello World"
end, "Hello, world!")
```---
#### Installing
Within your ``wally.toml`` file:
```toml
[dependences]
ThreadPool = "yetanotherclown/threadpool@1.0.0"
```#### Building with Rojo
To build yourself, use:
```bash
rojo build -o "ThreadPool.rbxm"
```For more help, check out [the Rojo documentation](https://rojo.space/docs).