How many partitions? How many rows do they have when performance is slowing considerably? Does this table get many updates or is it insert only? What version of PostgreSQL? Are the inserts randomly distributed among the partitions or targeting one or a few partitions? Are you able to capture an example and run it in a transaction with explain (analyze, buffers, verbose) and then rollback?
Michael Lewis | Database Engineer
Entrata