Tracing Software configuration on systems-live

The tracing software runs under crontab jobs under the rrbatch account on the systems-live server. rrbatch is also a windows server process account under active directories and is used to mount the tracing folders on systems-live.

This is a brief overview of the systems-live configuration 

0 * * * * /home/rrbatch/nhs-tracing/import.sh
0 18 * * 5 /home/rrbatch/nhs-tracing/export.sh
0 0 * * * /home/rrbatch/nhs-tracing/clean-outbox.sh

55 * * * * /home/rrbatch/simplified-tracing/venv/bin/python3.6 /home/rrbatch/simplified-tracing/tracer.py -t --log /var/tracing/log.txt
35 * * * * /home/rrbatch/simplified-tracing/venv/bin/python3.6 /home/rrbatch/simplified-tracing/tracer.py -m --log /var/tracing/log.txt

The connection config file for the nhs-tracing code is located in /nhs-tracing/registry.py

nhs-tracing code

Script to export a tracing file from the renalreg database:

export.sh
#!/bin/bash

set -e

PYTHONUNBUFFERED=1

/usr/bin/flock -n /home/rrbatch/nhs-tracing/export.lock /home/rrbatch/nhs-tracing/venv/bin/registry-tracing export &>> /home/rrbatch/nhs-tracing/export.log

Script to process returned tracing file:

import.sh
#!/bin/bash

set -e

PYTHONUNBUFFERED=1

/usr/bin/flock -n /home/rrbatch/nhs-tracing/import.lock /home/rrbatch/nhs-tracing/venv/bin/registry-tracing import &>> /home/rrbatch/nhs-tracing/import.log
/home/rrbatch/nhs-tracing/venv/bin/registry-tracing last-traced > /var/www/html/last-traced.txt


The last date a trace was run can be found by going to https://systems-live.renalregistry.northbristol.local/last-traced.txt

Simplified

This is the tracing stage of the Simplified Extract process SIMPLIFIED Extract and is the first step of the output. Simplified File Processing details the incoming flow initiated by an upload from Cambridge.

Details of the tracing are here: Simplified Data Set (Tracing Data)

ukrdc-tracing (work in progress)

There are two tracing processes one to trace the staging UKRDC and one to trace the live UKRDC. Each process creates a tracing file from the appropriate UKRDC database and submits it for tracing. Currently any successfully traced records will get an updated TRACE file created and sent to the appropriate mirth server /data/rda/in folder. SO currently if a record has a TRACING feed/record it means it has successfully traced. A further enhancement will be to record details of the mismatches such that the UI can provide this information to allow corrections. Currently only NHS numbers are trace as we have no access to TRACE CHI or HSC numbers.