#postgresql
PostgreSQL and indexing
- Connection pooling vs read replicas for a 50k-member forum
We used to raise `max_connections` whenever p99 login latency spiked. After about 4_000 concurrent sessions that stopped working — the wait moved to row locks on `topic_subscript...
- Should we store markdown, HTML, or both?
TalkMoro stores `body` and `body_html`. Re-rendering on every read is a non-starter. Re-rendering on every edit is cheap. The expensive case is a renderer change (heading ids, tas...
- Replica lag after you upvote: is 400ms too long?
The home feed reads from a replica. Upvotes write to primary and invalidate Valkey `topics:list:v3`. The surprise was not lag — it was members who vote and immediately refresh s...
- Search finds the title but not a code token in a reply
Query `SPUBLISH` matches nothing even though a reply contains it. Topic titles match. Is comment FTS enabled on this deploy, and do we need the `simple` dictionary for code tokens...
- Can polls be limited to one vote per member without a new table?
We are using the Poll template and counting upvotes on the original post as the "yes" vote. That collides with ranking. Is there a supported vote model, or should we wait for a de...
- Search type=support returns zero after the rename to question
Bookmarks and saved searches still use `topic_type=support`. The API should canonicalize aliases. Confirm the list cache key uses the canonical id so we do not serve mixed pages f...
- Category topic_count not incremented on SQL seed imports
Bulk SQL inserts skip the application layer, so nav badges drift. Either a trigger or a nightly `UPDATE categories SET topic_count = (SELECT count(*))`.
- TalkMoro v2.5.0 — Faceted search on template and entity
v2.5.0 Filters for topic_type and entity_type in search. Aliases like help map to question. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.5.0 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Va
- TalkMoro v2.5.2 — Event start and end timestamps
v2.5.2 Stored as timestamptz. Location can be a venue name or a webinar https URL. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.5.2 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Valkey deta
- TalkMoro v2.6.1 — Review template with itemReviewed
v2.6.1 Entity overlay required for a meaningful Review graph. No fake star aggregates. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.6.1 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Valkey
- TalkMoro v2.7.0 — HowTo steps from numbered lists
v2.7.0 Guide schema splits 1. markdown lines into HowToStep nodes. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.7.0 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Valkey detail keys bump. Qu
- TalkMoro v2.8.0 — llms.txt lists template folders
v2.8.0 Machine-readable list of permalink prefixes for AI crawlers. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.8.0 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Valkey detail keys bump. Q
- TalkMoro v2.9.0 — SoftwareApplication overlay on releases
v2.9.0 When entity_type=software, a second JSON-LD graph is emitted. Upgrade 1. Take a backup of discuss_db . 2. Pull the release tag v2.9.0 . 3. Run new SQL migrations if listed in the notes. 4. Restart the API so Valkey detail keys bump.
