PostgreSQL at low level: stay curious
Kind of unrelated and very high level thoughts, but I wish postgres had a scripting model a bit like redis. Where functions are cached under their sha1 hash and can be executed by specifying that hash. cached functions would then be evicted after not being run for a certain time.
From the application side I'd just always try executing the hash of the function and create it on the fly when that errors (because doesn't exist on the db side yet). 
a model similar to this one would completely convert me to defining most of my app logic in plsql functions.