{"record":{"id":"391a003f52280c3d","repo":"weaviate/weaviate","slug":"failed-to-put-empty-posting-d-after-split-operati","errorCode":null,"errorMessage":"failed to put empty posting %d after split operation","messagePattern":"failed to put empty posting (.+?) after split operation","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"adapters/repos/db/vector/hfresh/split.go","lineNumber":176,"sourceCode":"\t\t\treturn errors.Wrapf(err, \"failed to upsert new centroid %d after split operation\", newPostingID)\n\t\t}\n\t}\n\n\t// delete the old centroid\n\terr = h.Centroids.MarkAsDeleted(postingID)\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"failed to delete old centroid %d after split operation\", postingID)\n\t}\n\terr = h.setPostingVectorIDs(ctx, postingID, Posting{})\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"failed to set posting size for posting %d after split operation\", postingID)\n\t}\n\n\t// put empty posting for postingID to increase version and\n\t// allow cleanup of old vectors on disk\n\terr = h.PostingStore.Put(ctx, postingID, Posting{})\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"failed to put empty posting %d after split operation\", postingID)\n\t}\n\n\t// Mark the split operation as done\n\tmarkedAsDone = true\n\th.postingLocks.Unlock(postingID)\n\th.taskQueue.SplitDone(postingID)\n\n\tif !reassign {\n\t\treturn nil\n\t}\n\n\terr = h.enqueueReassignAfterSplit(ctx, postingID, newPostingIDs, result)\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"failed to enqueue reassign after split for posting %d\", postingID)\n\t}\n\n\treturn nil\n}","sourceCodeStart":158,"sourceCodeEnd":194,"githubUrl":"https://github.com/weaviate/weaviate/blob/75aa4b6d11f8818305aafd4440b4e32794f7ca04/adapters/repos/db/vector/hfresh/split.go#L158-L194","documentation":"HFresh wraps the error from PostingStore.Put when writing the now-empty old posting (to bump its version and allow cleanup of old vectors on disk). Failure aborts doSplit after the centroid updates; the split is retried by the caller.","triggerScenarios":"PostingStore.Put(ctx, postingID, Posting{}) errors while finalizing a split from append or Execute — disk full, store closed/corrupted, or context cancellation.","commonSituations":"Disk exhaustion during large imports; I/O errors on the data volume; shard shutdown racing background splits; corrupted posting store after crash.","solutions":["Fix the underlying storage error reported in the wrapped cause","Check and free disk space on the node","Restart the shard so the split retry succeeds","If errors persist, inspect/repair the LSM store for the affected shard"],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// pre-check: writable disk with sufficient space\n// e.g. run 'df' monitoring and alert below a threshold before large imports","typeGuard":null,"tryCatchPattern":"if err := op(); err != nil {\n\tif strings.Contains(err.Error(), \"failed to put empty posting\") {\n\t\treturn retry()\n\t}\n\treturn err\n}","preventionTips":["Provision adequate disk for ingest workloads","Avoid unclean shutdowns (use graceful stop)","Watch logs for repeated posting-store write failures"],"tags":["storage","hfresh","split","posting-store"],"backgroundTag":"storage-write-failed","analyzedSha":"75aa4b6d11f8818305aafd4440b4e32794f7ca04","analyzedAt":"2026-09-04T14:58:20.392Z","contentChangedAt":"2026-09-04T14:58:20.392Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}