Skip to main content

Batch Processing

Everything batch-like that a user can trigger from the client, plus the visible traces of background processing. All client-triggered runs execute inside the user's session, single-threaded, row by row (loops with yield() calls and progress bars — e.g. u_progressbar in provider/w_hcn_enrollment_dump); there is no in-client job scheduler.

Important scope limit: any DB-server-side scheduled jobs (Oracle jobs, cron, a dedicated batch workstation) are invisible to this client-code analysis. Several subsystems clearly depend on such jobs — see the open questions.

Client-triggered batch runs

Claims / payments

RunTrigger screenWhat it doesCitation
Outbound claim EDI extractclmutils/w_edi_outbound_edi_processor, button "Outbound EDI Process"Loops all staged claims (d_edi_outbound_claims_to_process), explodes each into outbound_edi_* staging tables, then writes per-partner fixed-width files and purges staged rows; commits between phasesclmutils/u_edi_outbound_edi::of_load_claim/of_create_file
Inbound claim EDI (repricing responses)Same window, "Inbound EDI Process"Reads a user-selected fixed-width response file line by line, applies repricing, sends failures to hold/corrections (RFCP), writes a .bad error fileclmutils/w_edi_outbound_edi_processor::wf_process_file/wf_process_claims
Check/EOB reprint batchesreprint/w_reprint ("print queue manager"), reprint/w_reprint_maintenanceSelects sets of stored report_hist outputs (checks, EOBs, worksheets) and prints them in a batchreprint/n_cst_reprint_func::of_print
Manual check + register archivefunding/w_fund_manual_checkWrites a single check, records it to report_hist, archives the register text to archive_dir\YYYYMM\funding/w_fund_manual_check lines ~198, 274-310
PPACA letter generationclmrpt/w_ppaca_lettersGenerates a chosen letter for a claim/report selectionclmrpt/w_ppaca_letters

Billing

RunTrigger screenWhat it doesCitation
Bill run submissionbilling/w_bill_run_def_maint ("Billing Run Maintenance. Submit/Maintain billing runs and definitions.")Marks selected bill definitions for a bill date with status SUBMITTED (or DELAYED via checkbox); re-submission deletes previously produced charges and voids reportsbilling/w_bill_run_def_maint lines ~382-390, 520-527, 771-777
Bill computation(no in-client trigger found)billfunc/n_billproc ("Functions for billing process, including computing bill, group, and member rates", of_bill(bill_run, bill_def, bill_dt)) contains the full rating/charge engine, but nothing in client source calls of_billbillfunc/n_billproc line ~83; grep across _re/src
Bill output printbilling/w_bill_queuePrints/deletes queued bill-run reports from the bill_reports storebilling/w_bill_queue line ~168

Enrollment / eligibility

RunTrigger screenWhat it doesCitation
HCN enrollment dumpsprovider/w_hcn_enrollment_dump (submit button, progress bar, optional six-month scope)Builds CIGNA file client-side; runs Aetna extract stored procedures (sfpidba.sp_aetna_enrollment / P_BUILD_AETNA) then writes AETNA<timestamp>.TXT; runs SP_MMO_ENROLLMENT on the warehouse connectionprovider/w_hcn_enrollment_dump lines ~152-194, 279, 534
Group eligibility exportenroll/w_enroll_group_exportWrites a fixed-format eligibility file for one master group to enrolldump_pathenroll/w_enroll_group_export line ~149
PBM member transfersdrugplan/w_drugplan_report_transferGenerates PCS / CVS-Caremark / RxBenefits member eligibility files (whole plan population per run)drugplan/w_drugplan_report_transfer events ue_create_pcs_*
PBM accumulator flag filesprovider/w_provider_caremark_flag_transfer, w_provider_optum_flag_transferLoops divisions/groups producing deductible/OOP flag files plus an audit reportprovider/d_caremark_flag_file*, d_optum_flag_file*
Matria (disease mgmt) dumpsfunding/w_burns_enrollment_dump, funding/w_burns_claim_dump, enrolrpt/w_dep_auditCreate Matria enrollment/claim files from the d_burns_* extract familywindow comments; base/d_burns_*

Mass letter / document generation

RunTrigger screenWhat it doesCitation
HIPAA certificates — generateenroll/w_enroll_hipaa_generateFor each pending row in hipaa_transactions, renders the certificate, saves it as a blob in report_hist (report_hist_seq.nextval, UPDATEBLOB), marks the transaction PROCESSEDenroll/w_enroll_hipaa_generate lines ~467-566
HIPAA certificates — printenroll/w_enroll_hipaa_printBatch-prints stored certificates, sets prt_flg = 'Y', supports purge of printed itemsenroll/w_enroll_hipaa_print lines ~199-424
Custom termination lettersenroll/w_enroll_custom_term_generate / w_enroll_custom_term_printSame generate-to-history-then-batch-print pattern (incl. USFHP variant)enroll/w_enroll_custom_term_generate lines ~312-418
COBRA letterscobra/w_cobra_printqueue ("Main Print Queue Screen for Printing of letters"), errors surfaced in cobra/w_cobra_letter_errorsPrints queued COBRA letters by letter type/group; unavailability letters generated by cobradw/n_cst_cobra_unavailability_letter_gencobra/w_cobra_printqueue; cobradw
FSA noticesenrollutils/w_fsa_noticesFlexible-spending notices and summary listingswindow comment
Annual statementsenrolrpt/w_annlstmtGenerates annual employee statements for a groupwindow comment
USFHP ID card requestsidcard/w_enroll_idcard_usfhpProcesses ID card requests, generates request listing and accompanying letterswindow comment

Banking

RunTrigger screenWhat it doesCitation
Positive-pay exportfunding/w_pospayExports check-issue CSV files for the bankfunding/w_pospay lines ~275, 427, 694
Bank reconciliation importfunding/w_fund_bank_reconciliation_fileReads the bank's reconciliation file and matches cleared checksline ~359

Visible traces of server-side/background processing

  • Background claims adjudication: clmutils/w_bkgd_monitor is a live monitor with panes for throughput, last claim processed, current locks, and claim status counts, each on a refresh interval — clear evidence of a continuously running adjudication engine outside this client (the engine itself does not appear in the 53 libraries).
  • Bill runs: the client only sets SUBMITTED/DELAYED status; the computation engine (billfunc/n_billproc) has no in-client caller, implying a separate runner executes submitted runs and fills bill_reports.
  • Check runs: report_hist rows carry check_number and batch_id, and the chkrundw library holds the check/EOB layouts (d_checkrun_eob*), but no client screen creates a check run batch — only reprint/copy paths use these layouts (clmprint/n_check_copy, reprint/w_reprint_maintenance). Check-run generation is therefore presumed server-side or in a retired/ separate executable.
  • Batch report registry: batch_reports.allow_run_events/allow_times (maintained by homersys/w_batch_reports) describes event- and time-driven report execution with no corresponding client runner.
  • Aetna / MMO extract builds run as database stored procedures invoked from the client (provider/w_hcn_enrollment_dump) — the procedure bodies are in the database only.

Requirements

  • BAT-1 Long-running extract/import runs shall be executable on demand by authorized users, show progress, and report completion or per-row errors without terminating the whole run (w_edi_outbound_edi_processor, w_hcn_enrollment_dump progress bar, .bad error files).
  • BAT-2 Batch runs that change claim state shall commit in phases and roll back the affected unit on error, leaving already-processed rows intact (w_edi_outbound_edi_processorof_commit/of_rollback per phase).
  • BAT-3 Bill runs shall be defined, submitted (optionally deferred), and re-submitted; re-submission shall void prior outputs and remove prior charges for the run (billing/w_bill_run_def_maint).
  • BAT-4 Submitted bill runs shall be processed asynchronously from the submitting user's session, with outputs delivered to a reviewable queue (bill_reports / billing/w_bill_queue; processing engine external — see open questions).
  • BAT-5 Mass document generation shall be a two-stage pipeline — generate into durable report history, then batch-print with printed-flag tracking and purge of processed source transactions (w_enroll_hipaa_generate/_print; hipaa_transactions.lock_cd = 'PROCESSED').
  • BAT-6 Operations staff shall be able to monitor background adjudication health: throughput, last processed item, current locks, and queue/status counts, auto-refreshing on a configurable interval (clmutils/w_bkgd_monitor).
  • BAT-7 Partner extract runs shall be idempotent per staging row (a claim can be staged only once; files only include rows not yet marked file_created) (claims/w_claim_editor dup check; u_edi_outbound_edi::of_create_file filter isnull(file_created)).
  • BAT-8 The migrated platform shall provide a first-class scheduler to replace the implicit external mechanisms (check runs, bill run processing, background adjudication, time/event-driven batch reports), whose current implementations are outside the client codebase.

Open questions

  • Where do check runs, bill-run processing, and background adjudication actually execute today? Nothing in the 53 client libraries runs them; the monitor screen, status columns, and report layouts prove they exist. Candidates: Oracle scheduled jobs/procedures, or a separate batch executable built from libraries not included in this extract. This must be inventoried on the database server before migration.
  • Volumes: client code gives no row counts; the only volume hints are UI affordances (progress bars, six-month limiter checkbox on the HCN dump, per-phase commits), suggesting runs large enough to need them. Obtain production volumes (claims/day, checks/run, letters/run) from operations.
  • w_open_windowname / base library one-off DataWindows (e.g. d_in_ticket_1094, d_cvs_troubleshoot) look like ad-hoc support extraction tools; confirm which are still operationally required.
  • Whether DELAYED bill runs are picked up by time (scheduler) or manually re-flagged is not visible in code.