Here is another library I extensively use in my Lua projects.
It's very simple and maybe hard to see how useful it can be. It's an abstraction layer on top of Lua coroutines to express asynchronous tasks in a simpler way (at least for me).
Coroutines are amazing and prevent stuff like callbacks hell; Luaseq exploits that and helps to write messy asynchronous dependencies.
For example, if we need to download a resource before being able to use it and multiple elements require it, they may wait on the same task to complete.
Project and documentation: https://github.com/ImagicTheCat/Luaseq
Luaseq - Asynchronous helper library
Re: Luaseq - Asynchronous helper library
This might be confused with luasec
- Guard13007
- Party member
- Posts: 134
- Joined: Sat Oct 25, 2014 3:42 am
- Location: Internet, USA
- Contact:
Re: Luaseq - Asynchronous helper library
I literally only opened this because I thought it was for this. Author, please consider renaming it
Re: Luaseq - Asynchronous helper library
I had interesting names for the library, but all were already taken. Similar is better than identical, at least computers understand the difference. Also, changing a project's name requires more than a little inconvenience.
Re: Luaseq - Asynchronous helper library
you could use uppercase
Re: Luaseq - Asynchronous helper library
Released version 1.1.
It features better error propagation and mutexes.
It features better error propagation and mutexes.
Re: Luaseq - Asynchronous helper library
"Real" doesn't mean much. Lua coroutines are VM threads, and what are commonly called threads are system threads.
Those mutexes are for VM threads, where there is concurrency, but not at the same level. E.g. think about a computer where there are system threads, but a single core, no instruction parallelism: it is still concurrent, scheduled by the kernel. Mutexes are a synchronization mechanism, in this case for the VM, at a higher level of abstraction.
Those mutexes are for VM threads, where there is concurrency, but not at the same level. E.g. think about a computer where there are system threads, but a single core, no instruction parallelism: it is still concurrent, scheduled by the kernel. Mutexes are a synchronization mechanism, in this case for the VM, at a higher level of abstraction.
Re: Luaseq - Asynchronous helper library
Maybe I should have been clearer with my question. I looked at the code and I understand that it's not usable with preemptive threads.
Re: Luaseq - Asynchronous helper library
For preemptive thread mutexes there's already https://github.com/slime73/love-mutex
Who is online
Users browsing this forum: Bing [Bot], Google [Bot] and 1 guest