Description
Hi again, fantix and the team!
I'm thinking of the best way of having two engines with the same models (e.g. one engine for a rw- and one for ro- database replica). It seems to me, that if I create two Gino objects, I'll have to fully redeclare models, like this:
db = Gino()
db_ro = Gino()
class MyModel(db.Model):
attr = db.Column(...)
class MyModelRo(db_ro.Model):
attr = db_ro.Column(...)
Is there a more elegant way to do this?
Description
Hi again, fantix and the team!
I'm thinking of the best way of having two engines with the same models (e.g. one engine for a rw- and one for ro- database replica). It seems to me, that if I create two Gino objects, I'll have to fully redeclare models, like this:
Is there a more elegant way to do this?