diff --git a/content/400-pulse/250-database-setup/100-general-database-instructions.mdx b/content/400-pulse/250-database-setup/100-general-database-instructions.mdx index 33f8799f06..2b62b84a10 100644 --- a/content/400-pulse/250-database-setup/100-general-database-instructions.mdx +++ b/content/400-pulse/250-database-setup/100-general-database-instructions.mdx @@ -7,11 +7,11 @@ toc_max_heading_level: 6 toc: true --- - +:::note Prisma Pulse requires a PostgreSQL (**version 12+**) database with logical replication enabled. To configure specific database providers for Prisma Pulse, visit [here](/pulse/database-setup#provider-specific-instructions). - +::: Database replication is the process of creating copies of a database and storing them across various on-premises or cloud destinations. Prisma Pulse uses logical replication to monitor your database for changes. @@ -69,7 +69,7 @@ ALTER TABLE public."User" REPLICA IDENTITY FULL; ## Manage your own publication slot -If you want to enable replication for _specific models_ or use a database provider that restricts superuser access for Prisma Pulse you can configure your own publication slot and use it to enable Pulse. +By default, Pulse monitors all tables for changes in your database. If you want to enable replication for *specific models* or if you use a database provider that restricts superuser access for Prisma Pulse, you can configure your own publication slot. If you want to configure your own publication slot and enable Pulse, you'll need to opt for one of [our paid plans](https://www.prisma.io/pricing#pulse). ### Creating a publication slot @@ -150,9 +150,17 @@ You can submit the publication name in the [Console](https://console.prisma.io/l SELECT * FROM pg_publication_tables; ``` -2. Then you can submit the desired publication name in the Console: +2. Navigate to [Prisma Data Platform](https://pris.ly/pdp) to enable Pulse. - ![Submit the publication name in the Console](/img/pulse/replication-slot-submission.png) +3. Submit the database connection string and region in the **Database connection** section. + +4. In your project environment configuration for Pulse, enter the publication name in the **Publication name** field. To access this, toggle the **Automatic setup** button in the **Database replication** section (available with a [paid plan](https://www.prisma.io/pricing#pulse)). + +5. After toggling **Automatic setup**, the button will transition to **Advanced setup**, and a textbox labeled **Publication name** will appear. + +6. Copy and paste the publication name from *step 2*. + +7. Click **Enable Pulse**. ### Removing publications diff --git a/content/400-pulse/250-database-setup/400-neon.mdx b/content/400-pulse/250-database-setup/400-neon.mdx index 93ce4268f2..4389fd4cc8 100644 --- a/content/400-pulse/250-database-setup/400-neon.mdx +++ b/content/400-pulse/250-database-setup/400-neon.mdx @@ -12,14 +12,10 @@ This section provides step-by-step instructions to make a [Neon](https://neon.te To enable logical replication on Neon, follow these steps: -1. Navigate to your project in the [Neon console](https://console.neon.tech/). -2. Go to the **Project settings** section from the Neon Dashboard. -3. Go to the **Beta** section in **Project Settings**. -4. Click on **Enable**. - - - You may be restricted from enabling logical replications due to an Enrollment Pause for the Neon logical replication beta phase. Learn more about enabling logical replication in Neon [here](https://neon.tech/docs/guides/logical-replication-neon#enabling-logical-replication-in-neon). - +1. Open your project in the [Neon console](https://console.neon.tech/). +2. In your project dashboard, go to the **Settings** section from the left panel. +3. Navigate to the **Logical Replication** tab in the **Settings** section. +4. Click the **Enable** button to enable logical replication. You have successfully enabled Logical replication for Neon. Now, follow the steps below to configure your Neon database to work with Pulse. @@ -27,17 +23,30 @@ You have successfully enabled Logical replication for Neon. Now, follow the step After enabling logical replication on Neon, follow these steps: -1. Create a publication to listen to database events from your Neon database. Use the **SQL Editor** in your Neon project to execute the SQL query to create a publication to listen to database change events from all tables: +1. Create a publication to track database change events in your Neon database. Open the **SQL Editor** from the left panel of your project dashboard in Neon, and run the following SQL query to create a publication that listens to events from all tables: + ```sql - CREATE Publication $PUBLICATION_NAME FOR ALL TABLES; + -- Replace $PUBLICATION_NAME with a custom name for your publication + CREATE PUBLICATION $PUBLICATION_NAME FOR ALL TABLES; ``` -
- - You can also create a publication to subscribe to database events from *specific tables*. To learn more on managing publications refer to [this](/pulse/database-setup/general-database-instructions#manage-your-own-publication-slot) section. - - -2. Before enabling Prisma Pulse, make sure to insert the publication name (e.g., `$PUBLICATION_NAME`) in the **Publication name** field in your project environment configuration for Pulse in the [Console](https://pris.ly/pdp): - - ![Submit the publication name in the Console](/img/pulse/replication-slot-submission.png) +
+ :::warning + To manage your own publication slot while enabling Prisma Pulse, you'll need to be on one of our paid plans. Since managing your own publication slot is required when using Neon, upgrading to a paid plan will allow you to seamlessly use Pulse with Neon. For more information, please visit our [pricing page](https://www.prisma.io/pricing#pulse). + ::: + :::info + You can also create a publication to subscribe to database events from *specific tables*. For more details on managing publications, refer to [this section](/pulse/database-setup/general-database-instructions#manage-your-own-publication-slot). + ::: + +2. Navigate to [Prisma Data Platform](https://pris.ly/pdp) to enable Pulse. + +3. Submit the database connection string and region in the **Database connection** section. + +4. In your project environment configuration for Pulse, enter the publication name (e.g., `$PUBLICATION_NAME`) in the **Publication name** field. To access this, toggle the **Automatic setup** button in the **Database replication** section (available with a [paid plan](https://www.prisma.io/pricing#pulse)). + +5. After toggling **Automatic setup**, the button will transition to **Advanced setup**, and a textbox labeled **Publication name** will appear. + +6. Paste the publication name you created in Neon in *step 1*. + +7. Click **Enable Pulse**. Your Neon database is now Pulse-ready! Follow our [getting started](/pulse/getting-started#21-install-the-pulse-client-extension) guide to see how to use Pulse in your application. \ No newline at end of file