-
Notifications
You must be signed in to change notification settings - Fork 209
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
[Miniflare 3] Re-implement D1 gateway using new storage system #563
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refactor looks great
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
@@ -3,7 +3,7 @@ import fs from "fs/promises"; | |||
import os from "os"; | |||
import path from "path"; | |||
import { performance } from "perf_hooks"; | |||
import { Database as DatabaseType, Statement } from "better-sqlite3"; | |||
import { Database as DatabaseType } from "better-sqlite3"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import type
packages/tre/src/storage2/sql.ts
Outdated
@@ -13,7 +13,7 @@ export type TypedStatement< | |||
}; | |||
|
|||
export type TypedDatabase = Omit<Database, "prepare"> & { | |||
prepare<Params, SingleResult = unknown>( | |||
prepare<Params = any[], SingleResult = unknown>( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unknown[]
?
This PR builds on #555, and re-implements the D1 gateway using the new storage system. This also brings forward changes #533 and #544 from Miniflare 2, fixing those issues in Miniflare 3 as well. 🙂
Closes DEVX-591