I tried to recreate the situation in a staging environment by lowering the max number of connections to 50 and running some thousands fetch requests. This is the output:
evo_backend_stage_db=# SELECT * FROM pg_stat_activity;
datid | datname | pid | usesysid | usename | application_name | client_addr | client_hostname | client_port | backend_start | xact_start | query_start | state_change | wait_event_type | wait_event | state | backend_xid | backend_xmin | query | backend_type
-------+----------------------+------+----------+----------+------------------+-------------+-----------------+-------------+-------------------------------+-------------------------------+-------------------------------+-------------------------------+-----------------+---------------------+--------+-------------+--------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+------------------------------
| | 31 | | | | | | | 2022-09-28 16:16:50.973258+00 | | | | Activity | AutoVacuumMain | | | | | autovacuum launcher
| | 33 | 10 | postgres | | | | | 2022-09-28 16:16:50.973288+00 | | | | Activity | LogicalLauncherMain | | | | | logical replication launcher
16384 | evo_backend_stage_db | 5849 | 10 | postgres | | 172.17.0.31 | | 52324 | 2022-09-28 16:55:42.220812+00 | | 2022-09-28 16:55:42.361289+00 | 2022-09-28 16:55:42.361324+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5850 | 10 | postgres | | 172.17.0.32 | | 51140 | 2022-09-28 16:55:42.386262+00 | | 2022-09-28 16:55:42.425814+00 | 2022-09-28 16:55:42.425842+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5174 | 10 | postgres | | 172.17.0.43 | | 55084 | 2022-09-28 16:54:50.902415+00 | | 2022-09-28 16:54:50.970189+00 | 2022-09-28 16:54:50.970384+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 4632 | 10 | postgres | | 172.17.0.39 | | 58676 | 2022-09-28 16:54:43.388749+00 | | 2022-09-28 16:54:43.404283+00 | 2022-09-28 16:54:43.405533+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 3862 | 10 | postgres | | 172.17.0.33 | | 37462 | 2022-09-28 16:54:40.342609+00 | | 2022-09-28 16:54:41.341288+00 | 2022-09-28 16:54:41.341787+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5321 | 10 | postgres | | 172.17.0.33 | | 50220 | 2022-09-28 16:55:30.403036+00 | | 2022-09-28 16:55:30.495692+00 | 2022-09-28 16:55:30.525328+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 4613 | 10 | postgres | | 172.17.0.39 | | 58638 | 2022-09-28 16:54:43.126092+00 | | 2022-09-28 16:54:43.171993+00 | 2022-09-28 16:54:43.172273+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5899 | 10 | postgres | | 172.17.0.33 | | 42788 | 2022-09-28 16:55:44.245468+00 | | 2022-09-28 16:55:44.287278+00 | 2022-09-28 16:55:44.287489+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5143 | 10 | postgres | | 172.17.0.40 | | 38612 | 2022-09-28 16:54:48.292862+00 | | 2022-09-28 16:54:48.333691+00 | 2022-09-28 16:54:48.333909+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5421 | 10 | postgres | | 172.17.0.33 | | 39560 | 2022-09-28 16:55:33.636056+00 | | 2022-09-28 16:55:33.651791+00 | 2022-09-28 16:55:33.652021+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 959 | 10 | postgres | psql | 127.0.0.1 | | 42780 | 2022-09-28 16:54:20.696987+00 | 2022-09-28 16:56:09.140191+00 | 2022-09-28 16:56:09.140191+00 | 2022-09-28 16:56:09.140193+00 | | | active | | 6343 | SELECT * FROM pg_stat_activity; | client backend
16384 | evo_backend_stage_db | 5882 | 10 | postgres | | 172.17.0.39 | | 53730 | 2022-09-28 16:55:44.04418+00 | | 2022-09-28 16:55:44.084618+00 | 2022-09-28 16:55:44.084827+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5862 | 10 | postgres | | 172.17.0.41 | | 59244 | 2022-09-28 16:55:43.421437+00 | | 2022-09-28 16:55:43.460567+00 | 2022-09-28 16:55:43.460593+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5854 | 10 | postgres | | 172.17.0.41 | | 59198 | 2022-09-28 16:55:42.728621+00 | | 2022-09-28 16:55:42.769025+00 | 2022-09-28 16:55:42.769055+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5855 | 10 | postgres | | 172.17.0.42 | | 40852 | 2022-09-28 16:55:42.788393+00 | | 2022-09-28 16:55:42.827239+00 | 2022-09-28 16:55:42.827269+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5870 | 10 | postgres | | 172.17.0.43 | | 50398 | 2022-09-28 16:55:43.693828+00 | | 2022-09-28 16:55:43.734868+00 | 2022-09-28 16:55:43.735076+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 3277 | 10 | postgres | | 172.17.0.43 | | 37960 | 2022-09-28 16:54:38.192371+00 | | 2022-09-28 16:54:42.891526+00 | 2022-09-28 16:54:42.892027+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5610 | 10 | postgres | | 172.17.0.33 | | 40060 | 2022-09-28 16:55:38.092832+00 | | 2022-09-28 16:55:38.132689+00 | 2022-09-28 16:55:38.132716+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5254 | 10 | postgres | | 172.17.0.40 | | 34362 | 2022-09-28 16:55:02.927281+00 | | 2022-09-28 16:55:03.015546+00 | 2022-09-28 16:55:03.096955+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 3317 | 10 | postgres | | 172.17.0.43 | | 38064 | 2022-09-28 16:54:38.493288+00 | | 2022-09-28 16:54:43.058393+00 | 2022-09-28 16:54:43.058682+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5158 | 10 | postgres | | 172.17.0.39 | | 59794 | 2022-09-28 16:54:49.791823+00 | | 2022-09-28 16:54:49.833412+00 | 2022-09-28 16:54:49.833443+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5159 | 10 | postgres | | 172.17.0.40 | | 38676 | 2022-09-28 16:54:49.852948+00 | | 2022-09-28 16:54:49.895564+00 | 2022-09-28 16:54:49.895601+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5260 | 10 | postgres | | 172.17.0.33 | | 50066 | 2022-09-28 16:55:28.533591+00 | | 2022-09-28 16:55:28.572451+00 | 2022-09-28 16:55:28.572477+00 | Client | ClientRead | idle | | | COMMIT | client backend
16384 | evo_backend_stage_db | 5900 | 10 | postgres | | 172.17.0.40 | | 57990 | 2022-09-28 16:55:44.245876+00 | | 2022-09-28 16:55:44.29003+00 | 2022-09-28 16:55:44.290243+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 3296 | 10 | postgres | | 172.17.0.39 | | 42216 | 2022-09-28 16:54:38.290139+00 | | 2022-09-28 16:54:42.99205+00 | 2022-09-28 16:54:42.992354+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5372 | 10 | postgres | | 172.17.0.41 | | 52200 | 2022-09-28 16:55:31.776005+00 | | 2022-09-28 16:55:31.825371+00 | 2022-09-28 16:55:31.825624+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5904 | 10 | postgres | | 172.17.0.31 | | 52684 | 2022-09-28 16:55:46.141645+00 | | 2022-09-28 16:55:46.206784+00 | 2022-09-28 16:55:46.206994+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 3860 | 10 | postgres | | 172.17.0.33 | | 37456 | 2022-09-28 16:54:40.340493+00 | | 2022-09-28 16:54:40.434745+00 | 2022-09-28 16:54:40.435903+00 | Client | ClientRead | idle | | | SELECT "silk_request"."id", "silk_request"."path", "silk_request"."query_params", "silk_request"."raw_body", "silk_request"."body", "silk_request"."method", "silk_request"."start_time", "silk_request"."view_name", "silk_request"."end_time", "silk_request"."time_taken", "silk_request"."encoded_headers", "silk_request"."meta_time", "silk_request"."meta_num_queries", "silk_request"."meta_time_spent_queries", "silk_request"."pyprofile", "silk_request"."prof_file", "silk_request"."num_sql_queries" FROM "silk_request" LIMIT 21 | client backend
16384 | evo_backend_stage_db | 5180 | 10 | postgres | | 172.17.0.40 | | 45558 | 2022-09-28 16:54:51.434526+00 | | 2022-09-28 16:54:51.473901+00 | 2022-09-28 16:54:51.473931+00 | Client | ClientRead | idle | | | COMMIT | client backend
...
It appears as though silk may be the culprit. I only turned it on in production a few days ago to profile a query that I had a hard time reproducing in development, and boom, this error appeared.