We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 10 months ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(1)
Beanie: https://beanie-odm.dev
首先,它是async(使用官方运动驱动程序,使用官方运动驱动程序,)如果您想使用 fastapi 的异步端点(大多数操作是I/O),则必须这是必须的。
Beanie允许我们在应用程序级别(使用Pydantic和Pydancticv2)定义模型并强制执行模式,并在FastAPI数据验证(都使用Pydantic)方面非常有用。
它还提供了与DB(例如Model.Intert(),model.get())进行交互的简单方法。
试一试! :)
Beanie: https://beanie-odm.dev
First, it is async (uses the official Motor driver), which is a must if you want to use async endpoints with FastAPI (most operations are I/O).
Beanie allows us to define models and enforce schemas at the application level (with Pydantic and PydancticV2) and works great with the FastAPI data validation (both are using Pydantic).
It also provides simple methods for interacting with the DB (e.g., model.insert(), model.get()).
Give it a shot ! :)