/pʃ/
n. “A TCP control flag that instructs the receiving end to push buffered data to the application immediately.”
In the context of the Transmission Control Protocol (TCP), PSH (short for push) is a flag used to signal that the data being sent should be delivered to the receiving application immediately, without waiting to fill the buffer. This helps reduce latency for time-sensitive communication, ensuring data reaches the application as soon as possible.
Key characteristics of PSH include:
- Immediate Delivery: Bypasses standard buffering to send data directly to the application.
- Works with ACK: Often used alongside the ACK flag to maintain reliable delivery.
- Reduces Latency: Useful for real-time applications like chat, VoIP, or interactive services.
- Not Mandatory: The receiving side can still buffer data if desired; PSH is a hint rather than a strict command.
Conceptual example of PSH usage:
// TCP send sequence with PSH
Client sends data packet with PSH flag
Server receives packet
Server delivers data immediately to application buffer
Application processes data in real-timeConceptually, PSH is like tapping someone on the shoulder to say, “Handle this message now” instead of letting it sit in a pile of messages.