5 ms·
> You can't quite stash the condition in a database and wait until everyone returns from the holiday to resume progress, but that's merely a technical limitatio
by phoe-krk 6y ago
> You can't quite stash the condition in a database and wait until everyone returns from the holiday to resume progress, but that's merely a technical limitation of the normal lisp compilers that are currently available.
I think that in a multithreaded environment you can try to hang a particular thread by forcing it into the debugger in order to preserve all stack information inside it, but I don't know if that is feasible in the long run on production systems since it opens a gate to possibly DoSing the machine.
- db48x 6y agoOr just have it wait for an RPC message. A thread waiting on IO doesn't cost much, and you can always spin up more to do the work it was supposed to be doing. But yea, conditions weren't designed from the start with distributed systems in mind, so you almost need a runtime that can save a whole thread to disk and recover it later. Back in the day though you could just open a window and ask the user what to do directly.
- phoe-krk 6y ago> and you can always spin up more I think it depends on your OS. IIRC, on Windows, it was fairly easy to destabilize the OS by spawning threads in a loop and starving other processes on the system. I haven't used Windows in a long while though, so I cannot say for sure.
- lonjil 6y agoMaybe that would be feasible with lighter weight green threads. I do this with threads but my system is just a chat bot, so it doesn't really ever turn into a problem.
- phoe-krk 6y agoThat would definitely be very feasible with Erlang-style processes, but contemporary Common Lisp implementations do not come equipped with those.