you on Nostr: at least adding three minor indexes as suggested by https://github.com/ankane/dexter ...
at least adding three minor indexes as suggested by
https://github.com/ankane/dexter seems to have lessened the read stampede
CREATE INDEX CONCURRENTLY ON "public"."nostr_events" ("created_at");
CREATE INDEX CONCURRENTLY ON "public"."nostr_events" ("pubkey", "created_at");
CREATE INDEX CONCURRENTLY ON "public"."nostr_tags" ("event_id");
although public.nostr_events (kind, content) isn't possible to add because that has txt longer than the 8191 size limit
Published at
2024-08-04 23:35:44Event JSON
{
"id": "12cf1ebdf6990095fb2ec8d0aa66814db85751379c35c3753bb47b107bcc6209",
"pubkey": "145a66a34db2b5ac7874ae75476296818e66300316e6b123d9f60c343df8f612",
"created_at": 1722814544,
"kind": 1,
"tags": [
[
"e",
"69bda3871a30869eabe7fbd588961bca5e41743e9017ecc54e04c0e1e47411e6",
"wss://str.256.lt/relay",
"root"
],
[
"e",
"69bda3871a30869eabe7fbd588961bca5e41743e9017ecc54e04c0e1e47411e6",
"wss://str.256.lt/relay",
"reply"
],
[
"imeta",
"url https://media.256.lt/18bad6fbde6f0aefe190869f90778d564a48da91d2a5374632bed8fb2b6d766d.png",
"m image/png",
"x 18bad6fbde6f0aefe190869f90778d564a48da91d2a5374632bed8fb2b6d766d",
"size 120041"
],
[
"r",
"https://github.com/ankane/dexter"
]
],
"content": "at least adding three minor indexes as suggested by https://github.com/ankane/dexter seems to have lessened the read stampede\n\nCREATE INDEX CONCURRENTLY ON \"public\".\"nostr_events\" (\"created_at\");\nCREATE INDEX CONCURRENTLY ON \"public\".\"nostr_events\" (\"pubkey\", \"created_at\");\nCREATE INDEX CONCURRENTLY ON \"public\".\"nostr_tags\" (\"event_id\");\n\nalthough public.nostr_events (kind, content) isn't possible to add because that has txt longer than the 8191 size limit\n\nhttps://media.256.lt/18bad6fbde6f0aefe190869f90778d564a48da91d2a5374632bed8fb2b6d766d.png",
"sig": "902336c9d9d9a784fbc64561293488d0cadd5b2ec1b407e2b6dfffb67cd78dabdb7c76963de4262143d26de11eeb9732569eaa2bc5380e0233b445701cc1803a"
}