Custom Data Proxy Fetch Implementation

Open
#11,614 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
nodejs, typescript
Domain
api, backend

Research direction

Start with packages/engine-core/src/data-proxy/utils/request.ts at the referenced fetch selection, then trace how Prisma Client options reach the Data Proxy engine. Define the supported custom-fetch configuration and verify that Data Proxy requests use it without breaking platform defaults; the payload names no tests, so identify the relevant request or client tests before implementation.

Written by the indexing model from the issue text.

Description

kind/feature topic: Cloudflare Workers topic: data proxy topic: pdp/accelerate

Problem

Suggested solution

Alternatives

  • An alternative would be allowing the user to call Prisma's Data Proxy by themselves (i.e. over HTTPS), with their own fetch implementation.

Additional context

  • This entire idea came about because of slow query times with Prisma's Data Proxy (somewhere in the neighborhood of 1.5 seconds for a single query). Allowing a custom fetch to be provided would simplify analytics for Prisma Data Proxy queries.
Dominant language
TypeScript
Stars
47.6k
Forks
2.5k
Avg merge
21h 59m
Merged PRs (30d)
95

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from prisma/orm

All issues in prisma/orm

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.