Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
您如何对 DjangoUser模型进行分片,以便用户记录位于不同的数据库/表中?
User
哪些模块、模型和视图需要修改?我是否需要创建自定义身份验证后端?有没有相对无痛的方法来做到这一点?
谢谢。
不幸的是,由于 Django 的设计方式,它相当困难。
我猜您关心一个数据库可以容纳的实体数量?否则,如果考虑扩展,请使用普通负载平衡器 - Web 服务器 - 连接池 - 数据库集群设置。