Modernization of Medical equipment operational management
Optimizing global portal databases helping retailers and cities to monitor the recycling of 50 billion used bottles and cans a year in the world
Bonafide Medical Group
CUSTOMER SPOTLIGHT
DME Software from Bonafide Medical Group is the best business workflow management and facility portal available to the Durable Medical Equipment (DME) and Home Medical Equipment (HME) industries. It is the only DME/HME software that fully and seamlessly integrates into all of your management decisions. Bonafide’s total DME/HME software solution can help you maximize efficiency, productivity and profitability in your business. Our single platform solution delivers every DME software advantage available to maximize your margins as reimbursement rates continue to shrink.
Project Challenge
The customer, a SaaS provider with a growing client base, had recently migrated their database layer from an on-premise SQL Server environment to AWS RDS for SQL Server. The platform followed a multi-tenant architecture, where each tenant had a dedicated database, supplemented by a few shared databases for common services and metadata.
Following the migration, the customer experienced severe performance degradation. Key challenges included:
- Long-running transactions with hundreds of CRUD operations and nested sub-transactions
- Poor indexing strategies, including missing, duplicate, or overlapping indexes
- Locking and concurrency issues, including blocking and frequent deadlocks
- Lack of query optimization and inefficient server configuration for the current workload
- Performance bottlenecks in tenant-specific and shared workloads, especially in reporting and dashboard queries
Given the criticality of performance to their application and customer experience, the customer engaged us to stabilize and enhance the system through both immediate and long-term improvements.
Solution
We adopted a two-tiered strategy focusing on quick wins for immediate performance relief and long-term architectural improvements to ensure ongoing scalability and stability.
Immediate Actions
Our goal was to quickly reduce the most painful performance issues without requiring major architectural changes. Key activities included:
- RDS instance configuration review and tuning: We audited and optimized database parameters to better match the transactional workload, reducing query latency and improving throughput.
- Query performance profiling: We identified and optimized critical queries within large transactions, reducing overall execution time.
- Report and dashboard query tuning: We focused on high-cost, frequently run queries that generated significant load, refactoring them for better performance with minimal application changes.
- Deadlock and blocking analysis: We analyzed deadlock graphs and execution plans to identify root causes and implemented mitigations, such as index adjustments and query refactoring.
Long-Term Improvements
To ensure sustainable performance and support future growth, we implemented several architectural and operational enhancements:
- Connection pooling: Introduced connection pooling at the application level to reduce connection overhead and improve concurrency handling.
- Read replicas and horizontal scaling: Added read replicas to offload reporting and manual ad-hoc query workloads, isolating transactional systems from analytics.
- Indexing strategy redesign:
- Audited each tenant's database to remove duplicate and unused indexes
- Introduced missing indexes based on actual workload and access patterns
- Tuned indexing to balance write and read performance
- Concurrency improvements:
- Refined transaction structure to reduce lock durations
Implemented conflict resolution logic to reduce deadlocks and data integrity issues
- Refined transaction structure to reduce lock durations
- Observability and monitoring: Designed and deployed metrics dashboards to track query performance, blocking, replication lag, and overall system health.
- Ongoing expert support: Provided consistent guidance and troubleshooting support to help the customer identify and resolve recurring bottlenecks.
- Maintenance automation: Implemented rationalized maintenance plans for index defragmentation, statistics updates, and health checks.
- Instance right-sizing and tenant isolation: Performed workload analysis and split high-traffic tenants into dedicated RDS instances to balance resource usage and improve isolation.
By combining tactical performance tuning with strategic architectural improvements, we helped the customer transform their database environment into a scalable, performant foundation for their SaaS platform.
Key results included:
- Significant reduction in transaction and query latency, improving application responsiveness
- Fewer deadlocks and blocking incidents, leading to improved concurrency and stability
- Lower operational overhead through automated maintenance and better observability
- Improved scalability via read replicas and tenant isolation
- Better developer and customer experience due to faster, more predictable performance
This engagement not only stabilized the customer’s post-migration environment but also equipped them with a scalable, maintainable database architecture built to support continued business growth.