diff --git a/NEWS.md b/NEWS.md index cf384bed..7738547f 100644 --- a/NEWS.md +++ b/NEWS.md @@ -6,6 +6,10 @@ New features: - Add support for log_filename directive - Reopen log file on SIGHUP, for better logrotate integration +Enhancements: + + - Set default PostgreSQL application name to "cartodb_tiler" + 1.10.2 -- 2014-04-08 -------------------- diff --git a/lib/cartodb/cartodb_windshaft.js b/lib/cartodb/cartodb_windshaft.js index 23878a7f..291dff26 100644 --- a/lib/cartodb/cartodb_windshaft.js +++ b/lib/cartodb/cartodb_windshaft.js @@ -11,6 +11,9 @@ var _ = require('underscore') , os = require('os') ; +if ( ! process.env['PGAPPNAME'] ) + process.env['PGAPPNAME']='cartodb_tiler'; + var CartodbWindshaft = function(serverOptions) { var debug = global.environment.debug; diff --git a/run_tests.sh b/run_tests.sh index 888060d5..9790b7e6 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -5,6 +5,8 @@ OPT_CREATE_PGSQL=yes # create the PostgreSQL test environment OPT_DROP_REDIS=yes # drop the redis test environment OPT_DROP_PGSQL=yes # drop the PostgreSQL test environment +export PGAPPNAME=cartodb_tiler_tester + cd $(dirname $0) BASEDIR=$(pwd) cd -