This plan outlines the steps to update all project dependencies to their latest versions.
| Category | Files Affected | Priority |
|---|---|---|
| Python Core Dependencies | pyproject.toml, requirements.txt |
High |
| Python Dev Dependencies | pyproject.toml, requirements-dev.txt |
Medium |
| Frontend Dependencies | web-ui-dashboard/package.json |
High |
| Docker Base Images | Dockerfile, docker-compose.yml |
High |
| CI/CD Actions | .github/workflows/*.yml |
Medium |
| Helm Chart Dependencies | helm/spark-optimizer/Chart.yaml, values.yaml |
Critical |
Note: Bitnami charts are being deprecated (August 2025) and require paid subscription ($50K+/year). Phase 5 covers migration to free, open-source alternatives (CloudNativePG, OT-ContainerKit Redis).
| Package | Current | Latest | Breaking Changes |
|---|---|---|---|
| pyspark | >=3.0.0 | 3.5.x | Minor API changes in 3.5 |
| pandas | >=1.3.0 | 2.2.x | Yes - significant changes in 2.0 |
| numpy | >=1.21.0 | 2.1.x | Yes - some dtype changes |
| scikit-learn | >=1.0.0 | 1.6.x | Minor deprecations |
| sqlalchemy | >=1.4.0 | 2.0.x | Yes - major rewrite |
| alembic | >=1.7.0 | 1.14.x | Minor |
| psycopg2-binary | >=2.9.0 | 2.9.x | None |
| flask | >=2.0.0 | 3.1.x | Yes - some breaking changes |
| flask-restful | >=0.3.9 | 0.3.x | None (consider Flask-RESTX) |
| flask-cors | >=3.0.10 | 5.0.x | Minor |
| pyyaml | >=5.4.0 | 6.0.x | Minor |
| python-dotenv | >=0.19.0 | 1.0.x | Minor |
| loguru | >=0.6.0 | 0.7.x | None |
| pydantic | >=1.9.0 | 2.10.x | Yes - major rewrite |
| requests | >=2.27.0 | 2.32.x | None |
| click | >=8.0.0 | 8.1.x | None |
| tabulate | >=0.9.0 | 0.9.x | None |
| python-dateutil | >=2.8.0 | 2.9.x | None |
Recommended Actions:
- Update pandas to
>=2.0.0- requires code review for deprecated APIs - Update numpy to
>=1.26.0(compatible with pandas 2.x) - Update SQLAlchemy to
>=2.0.0- requires migration to 2.0 style queries - Update Flask to
>=3.0.0- review async support changes - Update Pydantic to
>=2.0.0- significant model syntax changes - Update all other packages to latest stable versions
| Package | Current | Latest | Notes |
|---|---|---|---|
| boto3 | >=1.26.0 | 1.35.x | Update for latest AWS API support |
| google-cloud-dataproc | >=5.0.0 | 5.14.x | Update for latest GCP features |
| google-cloud-monitoring | >=2.11.0 | 2.24.x | Minor updates |
| Package | Current | Latest | Notes |
|---|---|---|---|
| pytest | >=7.0.0 | 8.3.x | Some fixture changes |
| pytest-cov | >=4.0.0 | 6.0.x | Minor |
| pytest-mock | >=3.10.0 | 3.14.x | Minor |
| pytest-asyncio | >=0.20.0 | 0.25.x | Mode changes |
| black | >=22.0.0 | 24.10.x | Style updates |
| flake8 | >=5.0.0 | 7.1.x | Rule updates |
| isort | >=5.11.0 | 5.13.x | Minor |
| mypy | >=0.990 | 1.13.x | Stricter type checking |
| pylint | >=2.15.0 | 3.3.x | Breaking changes in config |
| pre-commit | >=2.20.0 | 4.0.x | Hook format changes |
| sphinx | >=5.0.0 | 8.1.x | Theme compatibility |
| sphinx-rtd-theme | >=1.1.0 | 3.0.x | Sphinx 8 compatibility |
| ipython | >=8.0.0 | 8.30.x | Minor |
| ipdb | >=0.13.0 | 0.13.x | None |
The frontend is already on Angular 21 which is very recent. Updates needed:
| Package | Current | Latest | Notes |
|---|---|---|---|
| @angular/* | ^21.0.0 | 21.0.x | Already latest major |
| chart.js | ^4.5.1 | 4.4.x | Current is ahead of stable |
| ng2-charts | ^8.0.0 | 8.0.x | Latest |
| rxjs | ~7.8.0 | 7.8.x | Latest 7.x |
| typescript | ~5.9.2 | 5.7.x | Angular 21 requirement |
| tailwindcss | ^4.1.12 | 4.x | Latest |
| @playwright/test | ^1.57.0 | 1.49.x | Current is ahead |
Recommended Actions:
- Frontend dependencies appear to be already up-to-date or ahead
- Verify compatibility and run
pnpm update - Regenerate
pnpm-lock.yaml
| Image | Current | Latest | Notes |
|---|---|---|---|
| python | 3.11-slim | 3.13-slim | Python 3.13 is latest stable |
| postgres | 15-alpine | 17-alpine | PostgreSQL 17 released |
| redis | 7-alpine | 7.4-alpine | Latest 7.x |
| bitnami/spark | 3.5.0 | 3.5.4 | Latest 3.5.x |
| prom/prometheus | latest | v3.0.x | Pin to specific version |
| grafana/grafana | latest | 11.4.x | Pin to specific version |
| dpage/pgadmin4 | latest | 8.14 | Pin to specific version |
Recommended Actions:
- Update Python base image to 3.13-slim (or 3.12-slim for stability)
- Update PostgreSQL to 17-alpine
- Pin all
latesttags to specific versions for reproducibility - Update Spark to 3.5.4
- Consider using
uvinstead ofpipfor faster dependency installation - Add health check instructions
| Action | Current | Latest | Notes |
|---|---|---|---|
| actions/checkout | v4 | v4 | Latest |
| actions/setup-python | v6 | v5 | v6 doesn't exist, verify |
| actions/setup-node | v6 | v4 | v6 doesn't exist, verify |
| docker/setup-buildx-action | v3 | v3 | Latest |
| docker/build-push-action | v6 | v6 | Latest |
| docker/login-action | v3 | v3 | Latest |
| actions/upload-artifact | v6 | v4 | v6 doesn't exist, verify |
| actions/cache | v5 | v4 | v5 doesn't exist, verify |
| pnpm/action-setup | v4 | v4 | Latest |
| codecov/codecov-action | v4 | v5 | Update available |
| aquasecurity/trivy-action | 0.33.1 | 0.29.x | Current ahead |
| github/codeql-action | v4 | v3 | v4 doesn't exist, verify |
Note: Some actions show versions that don't exist yet. These may be from recent Dependabot updates or need verification.
Recommended Actions:
- Audit all workflow files for action version accuracy
- Update codecov/codecov-action to v5
- Ensure all actions use latest stable versions
- Current: 3.10, 3.11, 3.12, 3.13
- Add Python 3.14 when available (currently in alpha)
- Consider dropping 3.10 if moving minimum to 3.11
Bitnami (now owned by Broadcom) is deprecating free container images as of August 28, 2025. The new "Bitnami Secure" subscription costs $50,000-$72,000/year. We must migrate to free, open-source alternatives.
| Solution | Type | Repository | Recommendation |
|---|---|---|---|
| CloudNativePG | Operator | https://cloudnative-pg.github.io/charts |
⭐ Recommended for production |
| Crunchy PGO | Operator | https://artifacthub.io/packages/olm/community-operators/postgresql |
Enterprise-ready |
| Zalando Postgres Operator | Operator | https://opensource.zalando.com/postgres-operator/ |
Feature-rich, multi-DB per cluster |
| Percona PG Operator | Operator | https://artifacthub.io/packages/olm/community-operators/percona-postgresql-operator |
Percona flavor |
Recommended: CloudNativePG
- Kubernetes-native PostgreSQL operator
- Simple architecture (1 DB per cluster)
- Active community, regular updates
- Built-in backup/restore, replication, failover
- Chart:
cloudnative-pg/cloudnative-pg(operator) +cloudnative-pg/cluster(database)
| Solution | Type | Repository | Recommendation |
|---|---|---|---|
| OT-ContainerKit Redis Operator | Operator | https://ot-container-kit.github.io/helm-charts/ |
⭐ Recommended |
| Spotahome Redis Operator | Operator | https://artifacthub.io/packages/helm/redis-operator/redis-operator |
Popular historical alternative |
| DandyDeveloper redis-ha | Chart | https://dandydeveloper.github.io/charts/ |
Mature community chart |
Recommended: OT-ContainerKit Redis Operator
- Supports standalone, cluster, and sentinel modes
- Data migration support
- Active maintenance
- Charts:
redis-operator(operator) +redis/redis-cluster(instances)
dependencies:
- name: postgresql
version: "13.x.x"
repository: https://charts.bitnami.com/bitnami # ❌ Remove
condition: postgresql.enabled
- name: redis
version: "18.x.x"
repository: https://charts.bitnami.com/bitnami # ❌ Remove
condition: redis.enableddependencies:
- name: cloudnative-pg
version: "0.23.x"
repository: https://cloudnative-pg.github.io/charts
condition: postgresql.enabled
- name: redis-operator
version: "0.18.x"
repository: https://ot-container-kit.github.io/helm-charts/
condition: redis.enabledCurrent (Bitnami):
postgresql:
enabled: true
auth:
username: spark_optimizer
password: ""
database: spark_optimizer
primary:
persistence:
enabled: true
size: 10GiNew (CloudNativePG):
postgresql:
enabled: true
cluster:
name: spark-optimizer-db
instances: 2 # HA setup
storage:
size: 10Gi
postgresql:
parameters:
max_connections: "200"
bootstrap:
initdb:
database: spark_optimizer
owner: spark_optimizer
secret:
name: spark-optimizer-db-credentialsCurrent (Bitnami):
redis:
enabled: false
auth:
enabled: true
password: ""
master:
persistence:
enabled: true
size: 1GiNew (OT-ContainerKit):
redis:
enabled: false
mode: standalone # or "cluster" or "sentinel"
redisStandalone:
storage:
volumeClaimTemplate:
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 1Gi
kubernetesConfig:
image: redis:7-alpine
imagePullPolicy: IfNotPresent
# Note: Redis Operator requires deploying the operator first,
# then creating Redis/RedisCluster CRs-
Deploy Operators First (cluster-wide, one-time setup):
# CloudNativePG Operator helm repo add cnpg https://cloudnative-pg.github.io/charts helm install cnpg cnpg/cloudnative-pg -n cnpg-system --create-namespace # Redis Operator (if needed) helm repo add ot-helm https://ot-container-kit.github.io/helm-charts/ helm install redis-operator ot-helm/redis-operator -n redis-operator --create-namespace
-
Update Application Chart:
- Remove Bitnami dependencies from
Chart.yaml - Add CRD templates for PostgreSQL Cluster and Redis
- Update
values.yamlwith new structure - Update application database connection logic
- Remove Bitnami dependencies from
-
Data Migration (if upgrading existing deployment):
- Backup existing PostgreSQL data:
pg_dump - Deploy new CloudNativePG cluster
- Restore data:
pg_restore - Update connection strings
- Verify application connectivity
- Backup existing PostgreSQL data:
-
Testing:
- Deploy to staging environment
- Verify database connectivity
- Test failover scenarios
- Validate backup/restore procedures
For production, consider using managed databases instead of in-cluster:
- AWS RDS PostgreSQL / ElastiCache Redis
- GCP Cloud SQL / Memorystore
- Azure Database for PostgreSQL / Azure Cache for Redis
This simplifies Kubernetes deployment and provides enterprise features (backups, HA, scaling).
To use external databases, set in values.yaml:
database:
external: true
host: "your-rds-endpoint.amazonaws.com"
port: 5432
name: spark_optimizer
username: spark_optimizer
password: "" # Use secret reference
postgresql:
enabled: false # Disable in-cluster PostgreSQLgit checkout -b feature/dependency-updates- Update pyproject.toml with new version constraints
- Run tests after each major package update:
- SQLAlchemy 2.0 migration (most complex)
- Pydantic 2.0 migration
- Pandas 2.0 migration
- Flask 3.0 migration
- Update requirements.txt and requirements-dev.txt
- Run full test suite:
pytest tests/ -v
- Update
package.jsondependencies - Run
pnpm install - Run
pnpm buildto verify build - Run E2E tests:
pnpm test:e2e
- Update base images in
Dockerfile - Update service images in
docker-compose.yml - Build and test:
docker compose build && docker compose up - Run integration tests
- Update GitHub Actions versions in all workflow files
- Test workflows on feature branch
- Update
Chart.yamldependencies - Run
helm dependency update - Test deployment in staging environment
| Update | Risk Level | Mitigation |
|---|---|---|
| Bitnami → CloudNativePG/Redis Operator | Critical | Test in staging, backup data, phased rollout |
| SQLAlchemy 1.4 → 2.0 | High | Gradual migration, use compatibility mode |
| Pydantic 1.x → 2.x | High | Use pydantic.v1 compatibility imports first |
| Pandas 1.x → 2.x | Medium | Review deprecated API usage |
| Flask 2.x → 3.x | Medium | Test all endpoints |
| Python 3.11 → 3.13 | Low | Good backward compatibility |
| PostgreSQL 15 → 17 | Low | Mostly compatible |
Critical Note: The Bitnami migration has a hard deadline of August 28, 2025. After this date, Bitnami images will no longer receive updates and may be removed from public registries.
- All unit tests pass
- All integration tests pass
- Docker build succeeds
- Docker Compose stack starts correctly
- API endpoints respond correctly
- Frontend builds and runs
- E2E tests pass
- CI/CD pipelines succeed
- Helm chart deploys successfully
If issues are discovered after deployment:
- Revert to previous dependency versions
- Use git tags for version tracking
- Keep previous Docker images tagged and available
| Phase | Complexity | Description |
|---|---|---|
| Python Core | High | SQLAlchemy, Pydantic, Pandas migrations |
| Python Dev | Low | Mostly compatible updates |
| Frontend | Low | Already up-to-date |
| Docker | Medium | Image updates and testing |
| CI/CD | Low | Version bumps |
| Helm (Bitnami Migration) | High | Operator deployment, CRD templates, values restructure, data migration |
- Review this plan and prioritize phases
- Decide on Python version target (3.12 or 3.13)
- Create tracking issues for each phase
- Prioritize Helm/Bitnami migration due to August 2025 deadline
- Begin with Phase 1 (Python) as it has the most impact
- helm-unbitnami: Curated alternatives to Bitnami Helm charts
- Broadcom Ends Free Bitnami Images
- Bitnami Deprecation: Migration Steps and Alternatives
- Bitnami Helm Charts Deprecated: Migrate to Secure Alternative
- CloudNativePG - Kubernetes PostgreSQL Operator
- OT-ContainerKit Redis Operator
- Spotahome Redis Operator
- DandyDeveloper redis-ha Chart