The reconciliation engine is the run pipeline. It stages source data, normalizes records, compares matching keys, applies rules, and writes generated output for review.Documentation Index
Fetch the complete documentation index at: https://docs.drpn.ai/llms.txt
Use this file to discover all available pages before exploring further.
High-level flow
Run responsibilities
| Stage | Responsibility |
|---|---|
| Setup and access | Persist run setup and resolve user, company, and tenant scope. |
| Source staging | Save uploaded files, text payloads, or configured-source inputs for processing. |
| Base comparison | Normalize records and compute missing-object or matched-pair output. |
| Rule evaluation | Apply RuleSet rules to compare-ready data and matched pairs. |
| Output storage | Store generated output metadata and files for review. |
Current execution paths
Darpan has two execution paths.| Path | Role |
|---|---|
| RuleSet path | A saved run points to a RuleSetCompareScope with compare sources and optional rules. |
| Mapping path | A reconciliation mapping describes source members and comparison behavior. |
RuleSetCompareScope; existing services and release history may still reference mappings.
RuleSet compare flow
The RuleSet path is built from these records:RuleSetRuleSetCompareScopeRuleSetCompareSourceRuleReconciliationRun- Generated output descriptor records
- The facade service creates or loads a saved run and its compare scope.
- Generic reconciliation saves uploaded or text payloads in a tenant-scoped temp location.
prepare#RuleSetCompareScoperesolves compare sources and builds normalized Spark datasets.reconcile#RuleSetCompareScopeBaseDifffinds base missing-object differences and matched pairs.reconcile#RuleSetCompareScopepreserves base diffs and appends rule-generated diffs from matched pairs.- The backend writes result data and summary metadata as a generated output.
File and source handling
The backend can compare uploaded files, text payloads, and configured sources. CSV and JSON inputs are normalized before comparison. The comparison layer receives structured data and saved run context, not UI-specific state. Generic file reconciliation is routed through:Generated outputs
Generated outputs are not just downloaded files. The backend stores descriptor metadata so the UI can list, open, and delete outputs consistently. Generated-output metadata can include:- Saved run ID and display name
- RuleSet and compare-scope IDs
- Source labels
- Output location
- Diff counts and summary fields
- Created user and tenant scope