Effect of B-Tree and Composite Indexes on Read Latency, Write Cost, and Storage in PostgreSQL Under Concurrent Load
Secondary database indexes accelerate selective retrieval queries but introduce write maintenance overhead and additional storage consumption. This empirical study evaluates the trade-offs between read latency, write throughput, and disk footprint across three indexing configurations in PostgreSQL 18.6 using a 1 ,000,000-row synthetic event dataset. Three configurations were benchmarked: a baseline primary-key-only schema, a single-column B-tree index on user identifier, and a two-column composite B-tree index on user identifier and creation timestamp. Using the standard PostgreSQL benchmarking utility under 10, 50, and 100 concurrent client connections across read-only, write-only, and 90% read / 10% write mixed workloads, 105 timed 30second trials were executed. Relative to the unindexed baseline, both secondary indexes reduced mean read latency by more than 99.8% across all concurrency levels and improved mixedworkload throughput by over 115,600%. The composite index eliminated explicit sorting and outperformed the single-column index by 15.7% in mean read latency at 10 clients and 8.2% at 50 clients. Conversely, single-column and composite indexes reduced write throughput by 8.3% and 11 .1 % at 10 clients and consumed 15.3% and 52.4% of base table storage, respectively. These results quantify concurrency-dependent indexing tradeoffs for time-ordered event workloads.
Authors
- Manoj H K2
- Likith H S1
- Manoj M T3
- Mukthikanth P4
Publication Details
- Journal
- Zenodo (CERN European Organization for Nuclear Research)
- Published
- 2026-12-02
- DOI
- https://doi.org/10.5281/zenodo.24738950
- Primary Topic
- Advanced Database Systems and Queries
- Type
- article
- Field-Weighted Citation Impact
- 0.00