Title: LDP write path: If-Match conditional write is check-then-write, not atomic — concurrent writers can silently lose a write · Issue #600 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub
Open Graph Title: LDP write path: If-Match conditional write is check-then-write, not atomic — concurrent writers can silently lose a write · Issue #600 · JavaScriptSolidServer/JavaScriptSolidServer
X Title: LDP write path: If-Match conditional write is check-then-write, not atomic — concurrent writers can silently lose a write · Issue #600 · JavaScriptSolidServer/JavaScriptSolidServer
Description: What happens The host honors If-Match / If-None-Match correctly in the sequential case (stale If-Match PUT/DELETE → 412; If-None-Match: * on an existing resource → 412; If-None-Match GET → 304). But the check is check-then-write, not ato...
Open Graph Description: What happens The host honors If-Match / If-None-Match correctly in the sequential case (stale If-Match PUT/DELETE → 412; If-None-Match: * on an existing resource → 412; If-None-Match GET → 304). Bu...
X Description: What happens The host honors If-Match / If-None-Match correctly in the sequential case (stale If-Match PUT/DELETE → 412; If-None-Match: * on an existing resource → 412; If-None-Match GET → 304). Bu...
Opengraph URL: https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/600
X: @github
Domain: github.com
IPv4 address: 140.82.114.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"LDP write path: If-Match conditional write is check-then-write, not atomic — concurrent writers can silently lose a write","articleBody":"## What happens\n\nThe host honors `If-Match` / `If-None-Match` correctly in the sequential case (stale `If-Match` PUT/DELETE → 412; `If-None-Match: *` on an existing resource → 412; `If-None-Match` GET → 304). But the check is **check-then-write, not atomic**: two *concurrent* PUTs carrying the same currently-valid `If-Match` ETag both return 2xx, and the loser is silently overwritten.\n\nBoth callers are told success; one write is gone. The same two PUTs run sequentially 412 correctly — this is purely a race between the precondition check and the write.\n\n## Measured\n\nWitnessed live in a test (two overlapping conditional PUTs → 204/204, one body lost; sequential → 204/412 as expected):\n- https://github.com/JavaScriptSolidServer/plugins/tree/gh-pages/sparql (README, finding 7 — the UPDATE endpoint's concurrency test caught it on first run)\n- https://github.com/JavaScriptSolidServer/plugins/tree/gh-pages/remotestorage (README, finding 2 — the sequential cases that DO work)\n\n## Why it matters\n\nAny client using ETags for optimistic concurrency (remoteStorage clients, DAV clients, the sparql UPDATE bridge, anything doing GET→transform→PUT-If-Match) can lose writes under load while believing the protocol protected it. This is the one of the plugin experiment's findings with real data-loss consequences, and it is unfixable from outside the host.\n\n## Suggested fix\n\nMake the precondition check and the write atomic on the LDP write path — e.g. take a per-path lock (or serialize via a per-path promise queue) around stat→compare→write, or write-to-temp + atomic rename with the ETag re-checked under the lock.","author":{"url":"https://github.com/melvincarvalho","@type":"Person","name":"melvincarvalho"},"datePublished":"2026-07-11T07:47:49Z","url":"https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/600"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:2f016143-23bc-129d-49ee-ca38f2b789bb |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A044:D26F7:137AF06:1889879:6B0393A9 |
| html-safe-nonce | cce9d83fb75d41ebb731fb6200eeef71fdb4b6924da72e49103e1a164bc49cb3 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMDQ0OkQyNkY3OjEzN0FGMDY6MTg4OTg3OTo2QjAzOTNBOSIsInZpc2l0b3JfaWQiOiIyNDY5MDE2Nzk0MzM4Mzk5MTQ1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | a5d36619a24f0430cd53d821d12ba9f5bfaef1f005fff75dd6b16095e91b2bc8 |
| hovercard-subject-tag | issue:4861224329 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaScriptSolidServer/JavaScriptSolidServer/600/issue_layout |
| twitter:image | https://opengraph.githubassets.com/fc655b99cc3dfaa9a25ca73682eaab9c6d722f3f1ec26d204fd87536173b1573/JavaScriptSolidServer/JavaScriptSolidServer/issues/600 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/fc655b99cc3dfaa9a25ca73682eaab9c6d722f3f1ec26d204fd87536173b1573/JavaScriptSolidServer/JavaScriptSolidServer/issues/600 |
| og:image:alt | What happens The host honors If-Match / If-None-Match correctly in the sequential case (stale If-Match PUT/DELETE → 412; If-None-Match: * on an existing resource → 412; If-None-Match GET → 304). Bu... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | melvincarvalho |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaScriptSolidServer/JavaScriptSolidServer git https://github.com/JavaScriptSolidServer/JavaScriptSolidServer.git |
| octolytics-dimension-user_id | 205442424 |
| octolytics-dimension-user_login | JavaScriptSolidServer |
| octolytics-dimension-repository_id | 958025407 |
| octolytics-dimension-repository_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 958025407 |
| octolytics-dimension-repository_network_root_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width