Use psycogreen for PG backend
Change-Id: Ia2037cf26614cb4091a5c57a94a3c3a0af0ed70c Closes-bug: #1546976
This commit is contained in:
parent
302affe6aa
commit
300798c8f2
@ -55,6 +55,8 @@
|
||||
- tox
|
||||
- riak
|
||||
- pbr
|
||||
# for pg backend
|
||||
- psycogreen
|
||||
|
||||
# pre install solare requirements
|
||||
- shell: pip install -r https://raw.githubusercontent.com/openstack/solar/master/requirements.txt
|
||||
|
@ -29,6 +29,7 @@ wrapt
|
||||
peewee
|
||||
# if you want to use sql + postgresql then
|
||||
# psycopg2
|
||||
# psycogreen
|
||||
|
||||
# if you want to use lua computable inputs
|
||||
# lupa
|
||||
|
@ -64,7 +64,11 @@ elif _connection.mode == 'riak':
|
||||
|
||||
elif _connection.mode == 'postgresql':
|
||||
# TODO: collation has to be `C`
|
||||
import psycogreen.gevent
|
||||
psycogreen.gevent.patch_psycopg()
|
||||
|
||||
from solar.dblayer.sql_client import SqlClient
|
||||
|
||||
opts = {'autocommit': False}
|
||||
opts.update(_connection_details.toDict())
|
||||
if _connection.port:
|
||||
|
Loading…
Reference in New Issue
Block a user