[Libwebsockets] CPU-intensive and I/O-intensive job in LWS

Xi Chen leon6827chix at gmail.com
Thu Oct 4 08:14:06 CEST 2018


Hi, Andy

I need help with dealing the following scenarios:

[Server case - CPU]
- With mbedtls, the crypto job might be CPU-intensive, which will block the
LWS thread. This affects the concurrency capability supported by LWS,
right? Is it by design of LWS?

[Server case - I/O]
- Suppose server receives a POST request and need to save the data on
flash. I believe the flash write is blocking most likely, and is not
recommended to run in LWS callbacks. In this case, what is the recommended
way to deal with flash write in efficient way?

Thanks
-Xi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://libwebsockets.org/pipermail/libwebsockets/attachments/20181003/14a090d6/attachment.html>


More information about the Libwebsockets mailing list