Graybyt3 Was Here
Linux cloud.locucionar.com 3.10.0-1160.81.1.el7.x86_64 #1 SMP Fri Dec 16 17:29:43 UTC 2022 x86_64
Apache
91.191.211.241
/
opt
/
alt
/
python38
/
lib64
/
python3.8
/
site-packages
/
playhouse
/
__pycache__
[ HOME ]
Exec
Submit
File Name : read_slave.cpython-38.pyc
U S��W� � @ s d Z ddlT G dd� de�ZdS )ag Support for using a dedicated read-slave. The read database is specified as a Model.Meta option, and will be used for SELECT statements: master = PostgresqlDatabase('master') read_slave = PostgresqlDatabase('read_slave') class BaseModel(ReadSlaveModel): class Meta: database = master read_slaves = [read_slave] # This database will be used for SELECTs. # Now define your models as you would normally. class User(BaseModel): username = CharField() # To force a SELECT on the master database, you can instantiate the SelectQuery # by hand: master_select = SelectQuery(User).where(...) � )�*c s<