# Overview This package is a dependable thread pool package for chez scheme. I hacked chez-a-sync(https://github.com/ChrisVine/chez-a-sync) and simplified it. And my purpose is making this library easily imported into other code. This package is published with Akku(https://akkuscm.org/), which is a language package manager for Scheme. This package has been tested with Chez Scheme versions 9.4 and 9.5. # Requirement This package uses chez scheme's FFI to call up the pipe() and poll() system calls. It therefore requires a UNIX-like operating system to function correctly. It has been tested with linux and should work on the BSDs and on Mac OS X. If using OS X, the glibtool package will be required. This package also requires chez scheme to have been compiled with the --threads option. # API Usage please refer to tests/test-ufo-thread-pool.sps. 1. (init-thread-pool [size] [blocked]) =>thread-pool >NOTE: (init-tread-pool) with auto-confiured pool size is only available to Linux. 2. (thread-pool? value)=>#t/#f 3. (thread-pool-blocked?-ref pool)=>#t/#f 4. (thread-pool-blocked?-change pool #f/#t)=>#t/#f 5. (thread-pool-thread-number-ref pool)=>thread-number 6. (thread-pool-job-number-ref pool)=>job-number 7. (thread-pool-size-ref pool)=>size 8. (thread-pool-size-add pool value)=>size 9. (thread-pool-add-job pool job [fail-handler])=>result 10. (thread-pool-stop! pool) 11. (with-thread-pool-increment pool body0 body1 ...) # Test > bash test.sh
ufo5260987423/ufo-thread-pool
This package is a dependable thread pool package for chez scheme.
SchemeNOASSERTION