Skip to content

Conversation

@peterthomassen
Copy link
Member

@peterthomassen peterthomassen commented Jan 12, 2026

About the first commit:

  • During high concurrency, we sometimes end up sending PATCH requests with duplicate records to nslord, who rejects them, causing a 500 response. In all instances observed in nslord pcaps (correlated with www logs), there were to updates on the same domain within a fraction of a second.
  • This happens when the second request's serializer fetches the RRset contents from the database before the first request writes them, so two rows get written.
  • PDNSChangeTracker then constructs the nslord update request from the database, with duplicate records.
  • This change makes this fail earlier, throwing a psycopg.errors.ExclusionViolation exception. Django turns this into an IntegrityError, which our exception handler turns into a 409 response.
  • A better approach would be to lock the RRset's records for reading while a corresponding write transaction is pending. However, that will cause processes to hang, which might lead to other problems. Also, I'm not sure how to do it. I'd thus like to see if this fix suffices.

Other commits handle various routine work.

@peterthomassen peterthomassen force-pushed the 20260112_unique_records branch from b9759fa to f8b78a0 Compare January 12, 2026 23:08
peterthomassen and others added 4 commits January 13, 2026 01:01
Bumps the github-actions group with 1 update: [actions/checkout](https://github.com/actions/checkout).

Updates `actions/checkout` from 4 to 6
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v4...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
@peterthomassen peterthomassen force-pushed the 20260112_unique_records branch from f8b78a0 to d6b68e8 Compare January 13, 2026 00:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants