Skip to content

Commit

Permalink
Few tweaks.
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomek Kopczuk committed Jul 7, 2011
1 parent 0887445 commit 1aef636
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 9 deletions.
22 changes: 22 additions & 0 deletions ATP_Performance_Test/misc/middleware.py
@@ -1,3 +1,25 @@
# Copyright (C) 2011 by Blade Polska s.c.
# Full rights belong to Tomek Kopczuk (@tkopczuk).
# www.askthepony.com
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.

from datetime import datetime
import cProfile
import os
Expand Down
12 changes: 6 additions & 6 deletions ATP_Performance_Test/settings.py
Expand Up @@ -25,12 +25,12 @@
'USER': 'atp_performance_test', # Not used with sqlite3.
'PASSWORD': 'atp_performance_test', # Not used with sqlite3.
'HOST': 'localhost', # Set to empty string for localhost. Not used with sqlite3.
# 'PORT': '9999', # Default pgpool
# 'PORT': '5432', # Default PostgreSQL
'PORT': '6432', # Default pgBouncer
'OPTIONS': {
'autocommit': True,
}
# 'PORT': '5433', # Default pgpool
'PORT': '5432', # Default PostgreSQL
# 'PORT': '6432', # Default pgBouncer
# 'OPTIONS': {
# 'autocommit': True, # Uncomment if on PostgreSQL 9.0, even more performance boost! Beware, it will not wrap every request in transaction by default.
# }
}
}

Expand Down
5 changes: 2 additions & 3 deletions install_pgbouncer.sh
Expand Up @@ -8,6 +8,5 @@ cd pgbouncer-1.4.2
./configure --prefix=/usr/local
make
make install
cp etc/pgbouncer.ini /usr/local/etc/pgbouncer.ini
cp etc/userlist.txt /usr/local/etc/userlist.txt
pgbouncer /usr/local/etc/pgbouncer.ini -q
mkdir -p /var/log/pgbouncer/
chown postgres /var/log/pgbouncer

0 comments on commit 1aef636

Please sign in to comment.