Skip to content

How to multiplex named pipe / fifo #1227

@ORESoftware

Description

@ORESoftware

https://stackoverflow.com/questions/49937798/how-to-multiplex-named-pipe-fifo

this doesn't exactly have to do with Node.js, but hoping I can get some answers here..

Say we have a named pipe:

mkfifo my_named_pipe

say there are multiple writers writing to this named pipe:

node x.js > ${my_named_pipe} &
node y.js > ${my_named_pipe} &
node z.js > ${my_named_pipe} &

something like that - is there a reliable way to multiplex it, so that one whole message gets through each time, or can a named pipe reliable read from only one writer?

It leads me to wonder how we multiplex ports/sockets etc, I don't know how it's done.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions