#etag 3 articles
- SharePoint REST has no increment — a "+1" computed from the count you read at page load loses every vote cast in betweengotchas / rest-apiA MERGE writes a value, so count + 1 from what the page loaded, sent with IF-MATCH: *, overwrites every vote cast since that page load; count distinct AuthorIds of per-user rows, or read fresh and write with the item's…
- The ETag key is @odata.etag in OData v4 – reading odata.etag silently turns IF-MATCH into *gotchas / rest-apiSPHttpClient speaks OData v4: the item ETag comes as @odata.etag; reading odata.etag yields undefined and your IF-MATCH protection quietly disappears
- Two MERGEs to the same list item at once: the second one fails with 409 Save Conflict even with IF-MATCH: * – and a fire-and-forget write just disappearsgotchas / rest-apiIF-MATCH: * only switches off the ETag check (412); SharePoint still refuses a second save of the same item while the first is in flight with 409 Save Conflict. Queue writes per item (list#id), retry 409 briefly, never…