Repository navigation
Document Lifecycle Actions and Tombstones
OpenCrawling supports the Open Ingestion Standard (OIS) specification for document lifecycle management and tombstone deletions. This allows crawlers, event streams, and external applications to publish explicit document removal signals (action: "DELETE") that purge document records and vector embeddings across target search engines and vector databases.
The document payload contract defines an optional action property defaulting to "UPSERT".
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "OpenIngestionDocument",
"type": "object",
"required": ["id", "source"],
"properties": {
"id": {
"type": "string",
"description": "Unique document identifier in target index"
},
"action": {
"type": "string",
"enum": ["UPSERT", "DELETE"],
"default": "UPSERT",
"description": "Document lifecycle action. UPSERT creates or updates the document; DELETE purges the document and its chunks."
},
"source": {
"type": "object",
"description": "Metadata describing the origin repository"
},
"content": {
"type": "object",
"description": "Binary or text content (optional for DELETE tombstones)"
},
"metadata": {
"type": "object",
"description": "Metadata key-value pairs (optional for DELETE tombstones)"
},
"security": {
"type": "object",
"description": "Access control list (ACL) configuration (optional for DELETE tombstones)"
}
}
}{
"id": "doc-101",
"action": "UPSERT",
"source": {
"type": "filesystem",
"instance": "local"
},
"content": {
"text": "OpenCrawling is an enterprise open-source document crawling pipeline."
},
"metadata": {
"name": "architecture.pdf",
"mimeType": "application/pdf"
}
}For tombstone deletions, content, metadata, and security payloads are optional. Only id, action: "DELETE", and source are required.
{
"id": "doc-101",
"action": "DELETE",
"source": {
"type": "filesystem",
"instance": "local"
}
}When a tombstone DELETE action is published to OpenCrawling:
[Crawler / API] ──(Tombstone: action=DELETE)──> [JobOrchestrator]
│
(Bypass Claim-Check)
│
▼
[Kafka: opencrawling-ingestion]
│
▼
[IngestionConsumer]
│
(Short-Circuit Tika/Chunking)
│
▼
[Kafka: opencrawling-chunks]
│
▼
[EmbeddingConsumer]
│
(Short-Circuit AI Embeddings)
│
▼
[Kafka: opencrawling-embedded]
│
▼
[Output Store Writer]
│
(Purge Document / Chunks)
│
▼
[Target Vector Database / Search Engine]
-
JobOrchestrator: DetectsDocumentAction.DELETEand bypasses binary stream persistence to the Claim Check Store (Ozone / S3 / Local Storage). -
IngestionConsumer: Short-circuits Apache Tika parsing and chunking, forwarding a tombstoneDocumentChunkMessagedirectly toopencrawling-chunks. -
EmbeddingConsumer: Short-circuits AI model inference (Ollama / OpenAI), forwarding a tombstoneDocumentEmbeddedMessagedirectly toopencrawling-embedded. -
Output Connectors: Vector store writers process
DocumentAction.DELETEand execute native deletion queries to purge documents and vector points.
| Output Connector | Target Store | Deletion Execution Method |
|---|---|---|
oc-vector-output-connector |
PostgreSQL (pgvector) |
vectorStore.delete(List.of(documentId)) across all dimension tables (vector_store, vector_store_384, vector_store_768, vector_store_1024) |
oc-solr-output-connector |
Apache Solr | solrClient.deleteByQuery(collection, "id:\"docId\" OR chunk_id:\"chunkId\"") |
oc-qdrant-output-connector |
Qdrant | client.deleteAsync(collection, List.of(id(pointUuid))) |
oc-milvus-output-connector |
Milvus | client.delete(DeleteReq.builder().collectionName(col).filter("id == 'chunkId'").build()) |
oc-vespa-output-connector |
Vespa | client.remove(DocumentId.of(namespace, documentType, chunkId)) |
oc-opensearch2-output-connector |
OpenSearch 2.x | client.delete(d -> d.index(indexName).id(chunkId)) |
oc-opensearch3-output-connector |
OpenSearch 3.x | client.delete(d -> d.index(indexName).id(chunkId)) |
The Java SDK provides strongly-typed models for OIS document payloads and tombstone creation:
import org.opencrawling.sdk.models.DocumentAction;
import org.opencrawling.sdk.models.DocumentPayload;
import java.util.Map;
// Construct an OIS Tombstone Deletion Payload
DocumentPayload tombstone = DocumentPayload.createDeleteTombstone(
"doc-101",
Map.of("type", "filesystem", "instance", "prod-cluster")
);
System.out.println("Payload Action: " + tombstone.action()); // DELETEValidate tombstone payloads offline using the OpenCrawling CLI:
oc schema validate --file tombstone-payload.jsonOutput:
✔ OIS Schema Validation Passed: Valid OIS document payload (Action: DELETE)
External producers (such as Apache StormCrawler, custom web scrapers, or CDC pipelines) can submit OIS documents and deletion tombstones directly to the runtime HTTP gateway (POST /api/v1/ingest/ois/{jobId}):
curl -X POST http://localhost:8080/api/v1/ingest/ois/1 \
-H "Authorization: Bearer ${OPENCRAWLING_INGEST_OIS_TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"id": "https://example.com/page.html",
"action": "UPSERT",
"content": {
"mimeType": "text/html",
"text": "Extracted text content of the page."
},
"metadata": {
"title": "Page Title"
},
"security": {
"permissions": [
{"identity": "ROLE_USER", "identityType": "role", "access": "read"}
]
}
}'curl -X POST http://localhost:8080/api/v1/ingest/ois/1 \
-H "Authorization: Bearer ${OPENCRAWLING_INGEST_OIS_TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"id": "https://example.com/page.html",
"action": "DELETE"
}'-
202 Accepted: Document stored in claim check and message acknowledged on Kafka. -
400 Bad Request: Invalid OIS JSON structure or missing required fields (id,content.textorsecurityforUPSERT). -
401 Unauthorized: Missing or invalid Bearer token. -
404 Not Found: Endpoint disabled (empty token) or target job ID does not exist. -
409 Conflict: Target job is inMIGRATIONmode (OIS HTTP ingestion supportsRAGjobs only). -
503 Service Unavailable: Storage or Kafka publisher failure.
- Home
- User & Installation Guide
- Quick Start
- VM & Bare-Metal Distribution Installation
- Local Development & Fast Docker Builds
- User Guide
- Architecture
- Zero-Trust Security & ACL Management
- Document Lifecycle Actions & Tombstones
- Apache Tika 4 Text Extraction
- Configuration Guide
- Connectors Reference
- Alfresco Content Services (ACS) Connector
- Alfresco Process Services (APS) Connector
- Flowable Repository Connector
- Camunda Repository Connector
- OASIS CMIS Repository Connector
- Doxis Repository Connector
- M-Files Repository Connector
- SharePoint Online Repository Connector
- Hyland OpenArch Integration (Repository, Output & MCP)
- Relational Database (JDBC) Connector
- Apache StormCrawler Repository Connector
- gRPC Push Repository Connector
- Apache Solr Output Connector
- Luxir Output Connector
- Apache SeaTunnel Output Connector
- Apache Ozone Output Connector (Migration Mode)
- Connector Execution Modes
- Model Context Protocol
- Apache Ozone Claim Check Store
- Lakehouse Audit Reporting & Ledger
- AI-Powered Observability (AIOps)
- Auto-Narrativization Copilot
- Maven Connector Archetypes
- Java Client SDK
- OpenCrawling CLI
- OpenAPI Specification & Swagger UI
- gRPC Internal Transport
- Migration Guide (ManifoldCF)
- Integration Test — Decoupled Pipeline
- M-Files Integration Test
- SharePoint Online Integration Test
- Hyland OpenArch Integration Test
- Local Docker Build Test
- Secure MCP Server Integration Test
- Narrativization Integration Test
- Reporting Integration Test