Nicolas Martyanoff on Nostr: An unexpected problem with event-based IO in #CommonLisp is that it breaks the ...
An unexpected problem with event-based IO in #CommonLisp is that it breaks the condition/restart system. E.g. you upload a file using HTTP and a non-blocking client. The state machine to handle the flow (send request, read HTTP 100 response, send body, read reponse, execute callback) is running in the IO thread. If anything signals a condition, it has to be handled in the IO thread, completely decorrelated from the code that initiated the HTTP request.
Extrapolate that to a server running multiple complex IO flows in parallel. This is really not good, the language just does not match the problem.
Published at
2024-02-17 11:31:18Event JSON
{
"id": "9af011f6d3dc6d0e91245b28203d77d0b426f0be19915d96d1a1c45911db763c",
"pubkey": "f320bdda416aa99f2ae0949dca56c3bf58a9815c9de7ba950ad1fa568da2b816",
"created_at": 1708169478,
"kind": 1,
"tags": [
[
"t",
"commonlisp"
],
[
"proxy",
"https://emacs.ch/users/galdor/statuses/111946594968922559",
"activitypub"
]
],
"content": "An unexpected problem with event-based IO in #CommonLisp is that it breaks the condition/restart system. E.g. you upload a file using HTTP and a non-blocking client. The state machine to handle the flow (send request, read HTTP 100 response, send body, read reponse, execute callback) is running in the IO thread. If anything signals a condition, it has to be handled in the IO thread, completely decorrelated from the code that initiated the HTTP request. \n\nExtrapolate that to a server running multiple complex IO flows in parallel. This is really not good, the language just does not match the problem.",
"sig": "5f4730cbc34ab35c652daab3f72baaeadcc09bd86248cea64fef1a0761c9d0f7ee41ffd2f664994ca7aabe2905a230c2ed66842a592a485b39ddbd5755e75f9b"
}