Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I wanted this when D1 was first teased, and before I figured out that D1 is a database product that happens to be built on SQLite rather than SQLite being the star of the D1 show. Nonetheless, what I want is to be able to point a CF tunnel at a local SQLite file and instantly be able to leverage all the benefits of D1.

I should be able to...

    1. Configure a CF tunnel through the config file or the dash, pointing it to a local path of an existing SQLite file.

        1a. On startup, the SQLite file should create and link a new D1 db.
    2. Configure a CF tunnel through the config file or the dash, pointing it to an existing D1 db.

        2a. On startup, the local sqlite db should be either overwritten or created.
    3. Create read replicates through CF tunnels on another server or the local computer/wrangler for development.

    4. Have automatic global read replicas on the edge, which is inherent to D1 no?

    5. Have automatic/rolling backups and export and import those backups automatically with S3/R2.

    6. Do a PITR through the dash or CF tunnel CLI.

        6a. PITR should be possible to either the existing live DB or restoring it into a separate new D1 copy.
    7. Leverage my SQlite files in workers, another automatic bonus of connecting it to D1.
There are likely plenty of more cool things that could be done if D1 could be exposed as a normal SQLite file. Ultimately, CF tunnels are just in the mix because it seems like the obvious choice for plumbing SQLite files into and out of the CF network/edge.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: