multithreading or multiprocessing

后端 未结 8 994
野的像风
野的像风 2021-02-02 03:14

I am designing a dedicated syslog-processing daemon for Linux that needs to be robust and scalable and I\'m debating multithread vs. multiprocess.

The obvious objection

8条回答
  •  没有蜡笔的小新
    2021-02-02 04:04

    Thanks everyone for your feedback.

    I have decided on a multi-process architecture, similar to the Apache web server. The processes will scale nicely on multi-processor/core systems. Communications will be performed with pipes or sockets.

    Processes will be ready to use in a process-pool so there's no process spawning cost.

    The performance hit will be negligible in comparison to the robustness I'll gain.

提交回复
热议问题