a Practical Postgres Protocol Primer
Will has been building Postgres infrastructure for the last half dozen years.
It's unlikely that you will need to implement the Postgres wire protocol yourself, but understanding it will give you insight into how Postgres operates you'll not get otherwise. And as far as binary protocols go, this one is surprisingly not awful! In this talk we'll cover - motivations for using the raw protocol vs linking libpq - (and some protocol features not available in libpq!) - authentication and ssl negotiation - the flow for the two different query protocol and the tradeoffs between them - how asynchronous events fit in - and finally, miscellaneous features such as backend termination All of the examples will be with real, but (hopefully) simple code. A clear, working implementation makes good complement to the reference documentation, and should help you should you ever need to work with the raw protocol.
- 50 min
- PGConf US 2017