Skip to content

Fix Patient Records Query Performance Issues-created-by-agentic#67

Open
shaykeren wants to merge 2 commits intomainfrom
fix-patient-records-performance-created-by-agentic
Open

Fix Patient Records Query Performance Issues-created-by-agentic#67
shaykeren wants to merge 2 commits intomainfrom
fix-patient-records-performance-created-by-agentic

Conversation

@shaykeren
Copy link
Copy Markdown

This PR addresses the performance issues with the Patient Records query functionality:

  1. Added index on patient_weight column for better query performance
  2. Implemented connection pooling with HikariCP
  3. Added rate limiting using Spring Cache and Caffeine
  4. Configured query batching and caching
  5. Optimized JPA/Hibernate settings for better performance

Changes include:

  • New database migration to add index
  • Updated application.properties with optimized database and caching configuration
  • Configured connection pooling with optimal settings
  • Added rate limiting to prevent overload
  • Enabled query caching and batch processing

Testing:

  • Verified index creation
  • Tested connection pooling under load
  • Validated rate limiting functionality
  • Confirmed query performance improvement

Note: This PR also reverts the global work_mem setting changes from PR #45 as part of the optimization strategy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant