Migrate Spring Boot Banking Application from MySQL 8 to PostgreSQL 15 #31
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Migrate Spring Boot Banking Application from MySQL 8 to PostgreSQL 15
Summary
Complete database migration from MySQL 8.0 to PostgreSQL 15 across all deployment configurations (Docker Compose, Kubernetes, and Helm charts). This migration updates:
mysql-connector-javawith PostgreSQL driverpostgres:15image, updated env vars (POSTGRES_*), health checks (pg_isready), and volume pathsKey changes:
mysql:8.0→postgres:153306→5432mysql-svc→postgres-svcMYSQL_*→POSTGRES_*/var/lib/mysql→/var/lib/postgresql/datamysqladmin ping→pg_isready -U postgresjdbc:mysql://...→jdbc:postgresql://...Preserved:
BankDBTest@123(Base64:VGVzdEAxMjM=)Review & Testing Checklist for Human
Deploy and test using Docker Compose - Run
docker-compose upand verify:Deploy and test on Kubernetes - Apply all manifests and verify:
postgresdeployment starts successfullypostgres-svcservice is accessible on port 5432jdbc:postgresql://postgres-svc.bankapp-namespace.svc.cluster.local:5432/BankDBpostgres-secretcontainsPOSTGRES_PASSWORDkey/var/lib/postgresql/dataDeploy and test using Helm - Run
helm installand verify:postgres:15imagepg_isready -U postgres) work for liveness and readiness probespostgres-headlessresolves correctlypostgres-0.postgres-headless...Verify Maven dependency resolution - Run
mvn dependency:treeand confirm:Verify data persistence - After successful deployment:
Test Plan
Notes
mysql-deployment.yml) to minimize changes - optional to rename laterroottopostgres(PostgreSQL default)Requested by: Satwik Bebortha (@satwik-cog)
Devin run: https://app.devin.ai/sessions/7eed8ba1c24542939f702bd8fbb1f2be