Best Practices for Managing Schema Changes Dynamically with libpq

From: Sasmit Utkarsh <utkarshsasmit(at)gmail(dot)com>
To: pgsql-general <pgsql-general(at)postgresql(dot)org>, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Best Practices for Managing Schema Changes Dynamically with libpq
Date: 2024-12-03 17:43:46
Message-ID: CAM-5MT2gc+=tm5ErdoEyHDef3NzNL2UbAkrykdca9=1VJZi4fg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dear PostgreSQL Community Team,

I am working on a project that uses libpq along with C language to interact
with PostgreSQL, and we face challenges with managing schema changes
dynamically in production while avoiding downtime. Specifically, we need
guidance on handling table structure changes/additions without tightly
coupling these changes to application updates.

*Current Approach:*
Schema changes are deployed first, followed by application updates to align
with the new structure.

*Challenges:*
Ensuring application stability during the transitional phase when the
schema and code are not fully in sync.
Handling table structure changes (e.g., adding new columns) dynamically
without requiring immediate code changes.

*Questions:*
Are there recommended best practices for managing such schema changes with
libpq?
How can we efficiently handle table additions/updates while keeping the
application and database in sync dynamically?

I would appreciate any guidance, patterns, or examples that can help us
implement a robust solution.

Thank you for your time and support!

Regards,
Sasmit Utkarsh
+91-7674022625

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Ron Johnson 2024-12-03 17:57:28 Re: Autovacuum and visibility maps
Previous Message Adrian Klaver 2024-12-03 16:57:26 Re: Autovacuum and visibility maps