Distributed System Terminology – What is the Meaning of Fan-Out?

distributed-systemterminology

I see this word in many places but don't get it.

From the Wikipedia,

In message-oriented middleware solutions, fan-out is a messaging pattern used to model an information exchange that implies the delivery (or spreading) of a message to one or multiple destinations possibly in parallel, and not halting the process that executes the messaging to wait for any response to that message.

but I don't know what it means under other contexts, for example,

Can you please explain this term to me? Are there other places using this term? Thank you.

Best Answer

This term was originally from electronic components and defined the flow between their inputs and outputs. Fan-in refers to the number of higher-level modules that directly call the module, while fan-out refers to the number of lower-level modules directly called by the module.

AWS Kinesis enhanced fan-out feature

This refers to the shard being ingested (called) by a number of consumers (lower-level modules). The shard in Kinesis has a limited outbound throughput (2MB/second), it is shared by very limited clients. And this feature enables to achieve higher outbound throughput without having to provision more streams or shards in the same stream, so each consumer has that 2MB/s throughput.

Fanout load test on a distributed service

Sometimes larger requests may take longer to complete than smaller request. So it's worth testing whether the request handling can speed up if we turn one large request into a number of smaller requests instead. So here fan-out means split a large request payload into smaller batches and send out the request multiple times (lower-level modules) to the service.

Are there other places using this term?

One use case I can think of is fan-out write/read.

For example, if you tweet and Twitter delivers that to all the subscribers feeds as soon as it is written (fan-out write). Or a feed service that waits until users are actually consuming the feed, at that time it looks for posts that have been written that this user is eligible to read (fan-out read).