Use the pooled mysql database.
This commit is contained in:
parent
4af2a30a45
commit
feb7ad8dd1
1 changed files with 2 additions and 1 deletions
|
@ -5,6 +5,7 @@ import uuid
|
|||
from random import SystemRandom
|
||||
from datetime import datetime
|
||||
from peewee import *
|
||||
from playhouse.pool import PooledMySQLDatabase
|
||||
from sqlalchemy.engine.url import make_url
|
||||
from urlparse import urlparse
|
||||
|
||||
|
@ -15,7 +16,7 @@ logger = logging.getLogger(__name__)
|
|||
|
||||
|
||||
SCHEME_DRIVERS = {
|
||||
'mysql': MySQLDatabase,
|
||||
'mysql': PooledMySQLDatabase,
|
||||
'sqlite': SqliteDatabase,
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue