Extractor Service
This service receives a file event from the accepted-file topic, looks up the registered extractor configuration for the client application, submits the file to the extractor’s HTTP endpoint, and polls for a result. When the extractor reports completion, the result is stored in blob storage and a job status event is published.
Two extractor types are supported: DOCSAI and DBRICKS. Each has distinct submission and polling contracts.
Registration Contract
Extractor configuration is read from registration data using this precedence:
features[].featureName == "extractor"andfeatureConfig.extractorsextractorsin the registration payload- Fallback lookup to
/v1/clientApplication/{clientApplicationId}/extractors
Each configured extractor is expected to provide these fields.
Only the first extractor in the configured list is processed.
Submission Contract
The service sends an HTTP POST request to extractionUrl.
- Authentication: the request includes
Authorization: Bearer <token>. - Transport success: any HTTP
2xxresponse is treated as successful transport by the HTTP client. - Transport failure: non-
2xxresponses and transport errors are retried up to5attempts with a fixed2000 msdelay.
Submission Payload by Extractor Type
DOCSAI
Request body:
Expected response payload shape:
runId is derived from ExtractedEntityId.
DBRICKS
Request body:
Expected response payload shape:
runId is derived from id.
For DBRICKS, agent is required. Missing or blank agent fails submission.
Polling Contract
Polling starts after submission when a job has runId and extractor pollingUrl.
Polling URL format:
If pollingUrl is missing, polling fails and the job is marked failed.
If runId is missing, polling fails and the job is marked failed.
Polling Status Mapping
DOCSAI
- Reads
Statusfrom polling response. Status == "complete"maps toSucceededwithPayloadas result.Status == "failed"maps toFailed.Status == "processing"maps toProcessing.- Missing
Statusmaps toProcessingand keeps polling. - Polling request errors map to
Processingand keep polling.
DBRICKS
- Reads
overall_statusfrom polling response. COMPLETEDmaps toSucceeded.FAILEDorCANCELLEDmaps toFailed.ENQUEUEDorPROCESSINGmap toProcessing.- Missing or unrecognized status maps to
Processing. - Polling request errors map to
Processingand keep polling.
Polling Retry and Stop Conditions
Polling behavior is controlled by resolved job tracking configuration.
Configuration precedence:
extractor.jobTrackingConfig.*- Global app configuration keys:
FLUXX_EXTRACTOR_MAX_POLLING_ATTEMPTSFLUXX_EXTRACTOR_POLL_INTERVAL_MSFLUXX_EXTRACTOR_MAX_DELAY_MSFLUXX_EXTRACTOR_MAX_POLL_DURATION_MS
Backoff formula:
where:
effectiveMaxDelayMs = maxDelayMswhenmaxDelayMs > 0- otherwise
effectiveMaxDelayMs = baseIntervalMs
Polling stops and job fails when either condition is met:
attemptNumber >= maxPollingAttemptsjobAgeMs > maxDurationMs
Result Processing
When polling returns Succeeded, result handling is extractor-specific.
DOCSAI
- Inline object payloads are serialized to
result.json. - Data URL payloads are decoded and uploaded.
- HTTP URL payloads are downloaded and uploaded.
- Upload target container:
results - Upload target path:
$<clientApplicationId>/<fileId>/<jobId>/result.json
DBRICKS
- Uses
tasks[].result_urlto resolve blob location. - Reads result blobs from container
results. - Sends each blob payload to Palantir ingestion.
- Returns
result_urlwhen available.
Status Events
The service publishes job status events to the job status topic with statuses:
QueuedStartedProcessingSucceededFailedCanceled
The service publishes extracted result events after successful result handling.