Skip to content

Commit

Permalink
Update faq.md
Browse files Browse the repository at this point in the history
  • Loading branch information
nikolasburk committed Sep 24, 2019
1 parent 1483e54 commit 5d5872c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
- [How do schema migrations work with Photon.js?](#how-do-schema-migrations-work-with-photonjs)
- [Is Photon.js production-ready? Should I start using it?](#is-photonjs-production-ready-should-i-start-using-it)
- [Does Photon.js support GraphQL schema delegation and GraphQL binding?](#does-photonjs-support-graphql-schema-delegation-and-graphql-binding)
- [How does Photon.js handle connection pooling?](#how-does-photonjs-handle-connection-pooling)
- [How to handle connection pooling for Photon.js in serverless environments?](#how-to-handle-connection-pooling-for-photonjs-in-serverless-environments)
- Lift
- [Am I locked-in when using Lift? Is it easy to migrate off it?](#am-i-locked-in-when-using-lift-is-it-easy-to-migrate-off-it)
- [How do I see details about how Lift migrates my database schema?](#how-do-i-see-details-about-how-lift-migrates-my-database-schema)
Expand Down Expand Up @@ -58,9 +58,9 @@ Prisma 1 officially supports both schema delegation and GraphQL binding as it ex

With Prisma 2, Prisma's query engine doesn't expose a [spec](https://graphql.github.io/graphql-spec/June2018/)-compliant GraphQL endpoint any more, so usage of schema delegation and GraphQL binding with Prisma 2 is not officially supported. To build GraphQL servers with Prisma 2, be sure to check out [GraphQL Nexus](https://nexus.js.org/) and its [`nexus-prisma`](https://nexus.js.org/docs/database-access-with-prisma-v2) integration. GraphQL Nexus provides a code-first and type-safe way to build GraphQL servers in a scalable way.

### How does Photon.js handle connection pooling?
### How to handle connection pooling for Photon.js in serverless environments?

Photon.js currently [doesn't support connection pooling](https://github.com/prisma/photonjs/issues/228). If you're intested in learning how to manage database connections in serverless environments, check out the [docs](./photon/deployment.md).
The query engine that's powering the Photon.js API is maintaing a database connection pool. In serverless environments (or when running your application in containers, e.g. using Kubernetes), this connection pool might loose its effectiveness due to the infrastructure it's being deployed on. You can read more about this topic in the [docs](./photon/deployment.md).

As of now, the recommended workaround is to use a tool like [PgBouncer](https://pgbouncer.github.io/faq.html). We are further exploring some options, such as [enabling a "DB proxy server"](https://github.com/prisma/prisma2/issues/370) (e.g. using a specific generator that generates a Docker image to host Photon's query engine) that manages the connection pool for you (similar to the the Prisma 1 architecture).

Expand Down

0 comments on commit 5d5872c

Please sign in to comment.