Adding the db:generate command to package.json. I could not get the shortcut working that is demoed in the video I had to use drizzle-kit generate --dialect=postgresql --schema=./src/db/schema.ts just in case you run into the same issue great video tutorial
Thanks for watching! If you have any questions, feel free to reach out in the Neon Discord neon.tech/discord Check out the documentation for the create-app CLI command: neon.tech/docs/reference/cli-create-app
Ip filter is not enough, cant even know the ip especially when deploying with ecs. Better vpc peering if you can do that also dont put it behind paywall ar atleast enable it with $19 dollar option
Great stuff! It was really informative. I had a slightly different question. 😅 The editor folder icons and theme, which extension are you using? I really liked em! Would be glad if you could share it.
Hi, I have a suggestion with the Neon authorization 3rd party APPs part. I found that you authorized Cloudflare to read the Neon project, and then Cloudflare could fetch the DB password with such permissions. I think it's necessary to add a explicit hint at the authorization page, that the Read permission can see your DB password.
Is there a way to integrate this with the automatic CI/CD integration you have with Vercel? I believe the integration automatically creates new branches for every preview deployment. Is it possible to anonymize the data in those automatically created branches?
This example app isn't using Vercel as the deployment provider, it's using Fly.io. If the example app was using Vercel, then the using the Vercel integration would make more sense :) - Mahmoud
Try Neon at neon.tech/youtube and instantly spin up a Postgres database for free 🚀 - Point In Time Restore in Neon under the hood: neon.tech/blog/point-in-time-recovery-in-postgres - Documentation: neon.tech/docs/introduction/point-in-time-restore
An video with example to making a migration with a breaking change on the db would be awesome. There are not many good examples to do so with prisma migrations
What would be the right way to handle the db initialisation? Do I write the two lines in every single api single I need the env variables (since we are using hono)? Do I create the db in a middleware and then add that to hono context? What is the right way here?
Hello, was a good video and I appreciate all the work that has been done on the project. Just a quick heads up, in case someone isn't using the usual database name "neondb", you will need to provide the your database name on your workflow otherwise it will fail. env: NEON_DATABASE_NAME: ${{ secrets.NEON_DATABASE_NAME }} # change this to your database name jobs: name: Create Neon Branch with: database: ${{ env.NEON_DATABASE_NAME }} Also, this secret will need to be added to your github actions secrets. Appreciate your guides Neon, looking forward to the next features
do i need to write this every endpoint need query/insert to db? const client = new Client({ connectionString: c.env.DATABASE_URL }); const db = drizzle(client); await client.connect();
Yes. In serverless environments such as Vercel Edge Functions or Cloudflare Workers, WebSocket connections can't outlive a single request. That means Pool or Client objects must be connected, used and closed within a single request handler. Don't create them outside a request handler; don't create them in one handler and try to reuse them in another; and to avoid exhausting available connections, don't forget to close them. Here's a code example github.com/neondatabase/serverless?tab=readme-ov-file#example-nodejs-with-poolconnect - Mahmoud
ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-hIYNOiZXQ7Y.htmlfeature=shared check out our drizzle video and our documentation neon.tech/docs/guides/drizzle-migrations We go over running migrations Don't hesitate to reach out in the Neon Discord community if you need any help :) neon.tech/discord
Pool and Client - in the edge environment doesn't make any difference let alone make any sense. Very confusing to use Pool - but not actually mean or get a Pool!! :( Why not EdgeClient? Clear in what it does and the mental model is gracefully guided to remember to close the connection.
The reason for using Pool and Client is for the driver to be fully compatible with node-postgres. >Why not EdgeClient? Clear in what it does and the mental model is gracefully guided to remember to close the connection I'll share your feedback with the team. Thank you so much for letting us know :)