Declare model before create connection in ming
问题 I want delcare my models before make connection with database (for some reason like multi-threading, and dynamic load of database config uri). Documentation say to use like that: from ming import create_datastore from ming.odm import ThreadLocalODMSession from ming import schema from ming.odm import FieldProperty from ming.odm.declarative import MappedClass session = ThreadLocalODMSession( bind=create_datastore('odm_welcome') ) class WikiPage(MappedClass): class __mongometa__: session =