Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: refactoring fetching result #214

Merged
merged 7 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions load-testing/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ async def lifespan(app: FastAPI):


@app.get("/select")
async def test():
async def select():
try:
await manager.execute(MySimplestModel.select())
except Exception as e:
Expand All @@ -105,7 +105,7 @@ async def nested_atomic():


@app.get("/transaction")
async def test():
async def transaction():
try:
async with manager.transaction():
await manager.execute(MySimplestModel.update(id=1))
Expand All @@ -117,7 +117,7 @@ async def test():


@app.get("/atomic")
async def test():
async def atomic():
try:
async with manager.atomic():
await manager.execute(MySimplestModel.update(id=1))
Expand All @@ -129,7 +129,7 @@ async def test():


@app.get("/recreate_pool")
async def test():
async def atomic():
await manager.database.close_async()
await manager.database.connect_async()

Expand Down
Loading
Loading