Setting PostgreSQL application_name on Heroku
问题 application_name is a PostgreSQL specific connection parameter which each client can (and should) set when connecting. It later on helps DBAs and operations staff correlate misbehaving queries with a particular bit of application code. This SO question explains how to set application_name using SQLAlchemy, but unfortunately, it doesn't work on Heroku, because setting application_name was added on the PostgreSQL 8.5 branch (which was only released as 9.0 ) whereas the version of PostgreSQL