xbzhang <xbzhang(at)kingbase(dot)com(dot)cn> writes:
> Why the size (PQ_BUFFER_SIZE) of backend send buffers is 8192 ?
Traditionally, at least, that was the size of pipe buffers in Unix
machines, so in principle this is the most optimal chunk size for
sending data across a Unix socket. I have no idea though if that's
still true in kernels in common use today. For TCP communication
it might be marginally better to find out the MTU size and use that;
but it's unclear that it's worth the trouble, or indeed that we can
know the end-to-end MTU size with any reliability.
regards, tom lane