Communicating sequential processes (CSP) model concurrency as isolated sequential executions that exchange messages through synchronized channels. Each execution keeps its own state instead of sharing memory directly, reducing interference and many race conditions. section 9.1.2 section 1.5.2
Go applies CSP ideas with goroutines and channels. Channels are synchronized and unbuffered by default, while Go additionally treats channels as first-class objects that can move through function calls or other channels. section 9.1.2 section 7.0
CSP-style programming supports several practical communication structures:
- Connect goroutines by passing messages rather than allowing direct interference through shared memory. section 9.0
- Use a quit channel to notify goroutines that they should stop executing. section 9.4
- Build pipelines in which goroutines accept input channels and return output channels. section 9.4
- Use fan-in to merge inputs, fan-out to load-balance work when order does not matter, and broadcast to replicate messages. section 9.4
A concurrent Go application using CSP
A concurrent application can model separate executions as goroutines and coordinate them by sending messages over channels. Because channels are first-class objects, the program can create, pass, and rearrange communication paths while it runs. section 9.1.2

