github: shadowy octopus with the head of a robot, emblazoned with the Dreamwidth swirl (Default)
github ([personal profile] github) wrote in [site community profile] changelog2026-04-12 11:11 pm

[dreamwidth/dreamwidth] a19cc8: Improve esn-trace URL resolution with userid looku...

Branch: refs/heads/main Home: https://github.com/dreamwidth/dreamwidth Commit: a19cc8c787fca5419d8469a5977323ed68c450c2 https://github.com/dreamwidth/dreamwidth/commit/a19cc8c787fca5419d8469a5977323ed68c450c2 Author: Mark Smith mark@dreamwidth.org Date: 2026-04-12 (Sun, 12 Apr 2026)

Changed paths: M src/dwtool/main.go

Log Message:


Improve esn-trace URL resolution with userid lookup and precise Loki queries

Resolve the journal's userid from their profile page so we can build exact Loki regex queries matching [esn ETYPEID:JOURNALID:JTALKID:ARG2] instead of broad substring matches on ":JTALKID:" which produced false positives.

Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

Commit: b1e684b607034fa480f654db748922660b063d9d https://github.com/dreamwidth/dreamwidth/commit/b1e684b607034fa480f654db748922660b063d9d Author: Mark Smith mark@dreamwidth.org Date: 2026-04-12 (Sun, 12 Apr 2026)

Changed paths: M cgi-bin/DW/Task/ESN/FiredEvent.pm M cgi-bin/LJ/DB.pm

Log Message:


Fix ESN dropping notifications due to replication lag on comment load

FiredEvent reads comment data to determine which users' Reply subscriptions are relevant. LJ::Comment::preload_rows loads via get_cluster_reader, which hits the replica — but the comment was just written to the master and may not have replicated yet. When this race is lost, the comment fails to load, relevantuserids returns empty, Reply subscriptions are excluded, and the notification is silently dropped.

Fix: wrap the subscription lookup in LJ::DB::require_master so all reads go to the cluster master. Also extend get_cluster_reader to respect the existing PRAGMAFORCE_MASTER flag, which previously only affected global (non-cluster) readers.

Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

Compare: https://github.com/dreamwidth/dreamwidth/compare/eae7aaa21ba6...b1e684b60703

To unsubscribe from these emails, change your notification settings at https://github.com/dreamwidth/dreamwidth/settings/notifications