Skip to content

fix: intended DB connection pool size not applied in default deployment #393

@NotYuSheng

Description

@NotYuSheng

Problem

The default Docker deployment runs with SPRING_PROFILES_ACTIVE: dev (see docker-compose.yml). The dev profile (application-dev.yml) does not override the datasource, so the effective HikariCP pool comes from base application.yml:

spring.datasource.hikari:
  maximum-pool-size: 10
  minimum-idle: 5

The intended production sizing in application-prod.yml:

spring.datasource.hikari:
  maximum-pool-size: 20

…is never applied in the shipped deployment.

Impact

With tracepcap.analysis.max-concurrent-analyses: 3 each running batched saveAll inserts (jdbc.batch_size: 1000), plus request-serving traffic, a 10-connection pool is tight under concurrent analysis load.

Proposed fix

Make the default deployment use the intended pool size — either:

  • set the pool size for the dev profile / via env var in docker-compose.yml, or
  • run the prod profile in the default compose, or
  • raise the base maximum-pool-size.

Confirm Postgres max_connections (default 100) comfortably covers the chosen pool size.

Acceptance

  • Effective HikariCP maximum-pool-size in the default docker compose up deployment matches the intended value (verifiable via /actuator/metrics or Hikari logs).

Research context: #365

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdatabaseDatabase schema or queriesscalabilityPerformance and scalability

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions