Parsing audit records stored in a hardware storage device
A computer-implemented method includes: receiving a request to perform an audit on data describing a medical safety event; obtaining an initial audit record based on the request; parsing the initial audit record to identify a structure of the initial audit record; identifying, from the structure, one or more fields that describe one or more properties of the medical safety event; identifying a mutation object based on the one or more fields, with the mutation object describing an initial content of the data; determining a first change of the data from the initial content to a first updated content; updating the mutation object to describe the first updated content; obtaining a first updated audit record based on the first updated content of the data; storing the mutation object describing the first updated content; and storing the initial audit record and the first updated audit record.
1 . A computer-implemented method, comprising:
receiving a request to perform an audit on data describing a medical safety event of a plurality of medical safety events within a healthcare institution;
obtaining, from a hardware storage device storing a plurality of audit records based on the request, an initial audit record corresponding to the medical safety event of the plurality of medical safety events;
parsing, by a parser, fields of the initial audit record to identify a structure of the initial audit record;
accessing, from a database from the structure of the parsed fields, one or more fields that describe one or more properties of the medical safety event;
instantiating a mutation object based on the one or more accessed fields of the initial audit record, with the mutation object describing an initial content of the data;
accessing, from a database by the mutation object according to executable logic for identifying differences between data files, a first change of the data from the initial content to a first updated content, wherein the first change of the data represents each point of difference between the initial content and the first updated content;
overwriting, in memory, storage space for the mutation object with an updated mutation object that describes the first updated content, the initial content, and the first change of the data from the initial content to the first updated content so that the first change of the data indicates, separately from the first updated content and the initial content, each point of difference between the initial content and the first updated content,
wherein overwriting the storage space saves computing and storage resources by decreasing an amount of storage needed for tracking the first change of the data from the initial content to the first updated content using the mutation object,
wherein the updated mutation object includes:
a first instance indicating a description of the initial content; and
a second instance indicating a description of the first updated content and a description of the first change of the data from the initial content to the first updated content,
wherein the first instance is associated with a full status indicator indicating that the first instance includes description without including description change, and
wherein the second instance is associated with a combined status indicator indicating that the second instance includes both description and description change;
accessing, from the database, a first updated audit record based on the first updated content of the data;
storing, in the hardware storage device, the updated mutation object including a single dataset corresponding to the initial content and a single dataset corresponding to the first change of the data without storing duplicate datasets of the initial content and the first change of the data, wherein storing the updated mutation object in the hardware storage device overwrites the mutation object with the updated mutation object in the hardware storage device so that first data corresponding to the mutation object is replaced with second data corresponding to the updated mutation object;
causing rendering on a display device of a user interface that provides one or more indicators of the first instance and one or more indicators of the second instance including:
a first time indicator corresponding to a time at which the first instance was created;
the full status indicator indicating that the first instance includes description without including description change;
a second time indicator to one or more times at which the second instance was created; and
the combined status indicator indicating that the second instance includes both description and description change; and
storing, in the hardware storage device, the initial audit record and the first updated audit record.
2 . The computer-implemented method of claim 1 ,
wherein the one or more properties comprise an action of the audit.
3 . The computer-implemented method of claim 1 ,
wherein the one or more properties comprise one or more references to the medical safety event.
4 . The computer-implemented method of claim 1 ,
wherein the mutation object comprises a set of instances including the first instance and the second instance, each instance of the set of instances including an event description, a mutation status indicator, and a mutation action indicator.
5 . The computer-implemented method of claim 4 , wherein updating the mutation object to describe the first updated content comprises:
setting the event description of the first instance to include the description of the initial content;
setting the mutation status indicator of the first instance to the full status indicator;
setting the mutation action indicator of the first instance to indicate that the first instance is associated with a creation of the mutation object;
setting the event description of the second instance to include the description of the first updated content and the description of the first change of the data;
setting the mutation status indicator of the second instance to the combined status indicator; and
setting the mutation action indicator of the second instance to indicate that the second instance is associated with an update of the mutation object.
6 . The computer-implemented method of claim 5 , wherein the updated mutation object comprises a first updated mutation object, and wherein the method further comprises:
determining a second change of the data from the first updated content to a second updated content; and
updating the first mutation object to a second updated mutation object describing the second updated content, the initial content, the first change of the data from the initial content to the first updated content, and the second change of the data from the first updated content to the second updated content; and
storing, in the hardware storage device, the second updated mutation object including the single dataset corresponding to the initial content, the single dataset corresponding to the first change of the data, and a single dataset corresponding to the second change of the data without storing duplicate datasets of the initial content, the first change of the data, and the second change of the data.
7 . The computer-implemented method of claim 6 , wherein updating the mutation object to describe the second updated content comprises:
generating a third instance of the set of instances so that the event description of the third instance includes a description of the second updated content and a description of the second change of the data from the first updated content to the second updated content;
setting the mutation status indicator of the third instance to the combined status indicator indicating that the third instance includes both description and description change;
setting the mutation action indicator of the third instance to indicate that the third instance is associated with an update of the mutation object;
truncating the second instance to include the description of the first change of the data from the initial content to the first updated content without including the description of the first updated content; and
changing the mutation status indicator of the second instance to a difference status indicator indicating that the second instance includes description change without including description.
8 . The computer-implemented method of claim 1 ,
wherein the initial audit record and the first updated audit record are stored in a format of an expression language.
9 . The computer-implemented method of claim 6 , further comprising:
obtaining a second updated audit record based on the second updated content of the data; and
storing, in the hardware storage device, the second updated audit record.
10 . A non-transitory computer-readable medium storing program instructions that cause a data processing system to perform operations comprising:
receiving a request to perform an audit on data describing a medical safety event of a plurality of medical safety events within a healthcare institution;
obtaining, from a hardware storage device storing a plurality of audit records based on the request, an initial audit record corresponding to the medical safety event of the plurality of medical safety events;
parsing, by a parser, fields of the initial audit record to identify a structure of the initial audit record;
accessing, from a database from the structure of the parsed fields, one or more fields that describe one or more properties of the medical safety event;
instantiating a mutation object based on the one or more fields of the initial audit record, with the mutation object describing an initial content of the data;
accessing, by the mutation object according to logic for identifying differences between data files, a first change of the data from the initial content to a first updated content, wherein the first change of the data represents each point of difference between the initial content and the first updated content;
overwriting, in memory, storage space for the mutation object with an updated mutation object that describes the first updated content, the initial content, and the first change of the data from the initial content to the first updated content so that the first change of the data indicates, separately from the first updated content and the initial content, each point of difference between the initial content and the first updated content,
wherein overwriting the storage space saves computing and storage resources by decreasing an amount of storage needed for tracking the first change of the data from the initial content to the first updated content using the mutation object,
wherein the updated mutation object includes:
a first instance indicating a description of the initial content; and
a second instance indicating a description of the first updated content and a description of the first change of the data from the initial content to the first updated content,
wherein the first instance is associated with a full status indicator indicating that the first instance includes description without including description change, and
wherein the second instance is associated with a combined status indicator indicating that the second instance includes both description and description change;
accessing, from the database, a first updated audit record based on the first updated content of the data;
storing, in the hardware storage device, the updated mutation object including a single dataset corresponding to the initial content and a single dataset corresponding to the first change of the data without storing duplicate datasets of the initial content and the first change of the data, wherein storing the updated mutation object in the hardware storage device overwrites the mutation object with the updated mutation object in the hardware storage device so that first data corresponding to the mutation object is replaced with second data corresponding to the updated mutation object;
causing rendering on a display device of a user interface that provides one or more indicators of the first instance and one or more indicators of the second instance including:
a first time indicator corresponding to a time at which the first instance was created;
the full status indicator indicating that the first instance includes description without including description change;
a second time indicator to one or more times at which the second instance was created; and
the combined status indicator indicating that the second instance includes both description and description change; and
storing, in the hardware storage device, the initial audit record and the first updated audit record.
11 . The non-transitory computer-readable medium of claim 10 ,
wherein the one or more properties comprise an action of the audit.
12 . The non-transitory computer-readable medium of claim 10 ,
wherein the one or more properties comprise one or more references to the medical safety event.
13 . The non-transitory computer-readable medium of claim 10 ,
wherein the mutation object comprises a set of instances including the first instance and the second instance, each instance of the set of instances including an event description, a mutation status indicator, and a mutation action indicator.
14 . The non-transitory computer-readable medium of claim 13 , wherein updating the mutation object to describe the first updated content comprises:
setting the event description of the first instance to include the description of the initial content;
setting the mutation status indicator of the first instance to the full status indicator;
setting the mutation action indicator of the first instance to indicate that the first instance is associated with a creation of the mutation object;
setting the event description of the second instance to the combined status indicator
setting the mutation status indicator of the second instance to the combined status indicator; and
setting the mutation action indicator of the second instance to indicate that the second instance is associated with an update of the mutation object.
15 . The non-transitory computer-readable medium of claim 14 , wherein the updated mutation object comprises a first updated mutation object, and the operations further comprising:
determining a second change of the data from the first updated content to a second updated content; and
updating the first mutation object to a second updated mutation object describing the second updated content, the initial content, the first change of the data from the initial content to the first updated content, and the second change of the data from the first updated content to the second updated content; and
storing, in the hardware storage device, the second updated mutation object including the single dataset corresponding to the initial content, the single dataset corresponding to the first change of the data, and a single dataset corresponding to the second change of the data without storing duplicate datasets of the initial content, the first change of the data, and the second change of the data.
16 . The non-transitory computer-readable medium of claim 15 , wherein updating the mutation object to describe the second updated content comprises:
generating a third instance of the set of instances so that the event description of the third instance includes a description of the second updated content and a description of the second change of the data from the first updated content to the second updated content;
setting the mutation status indicator of the third instance to the combined status indicator indicating that the third instance includes both description and description change;
setting the mutation action indicator of the third instance to indicate that the third instance is associated with an update of the mutation object;
truncating the second instance to include the description of the first change of the data from the initial content to the first updated content without including the description of the first updated content; and
changing the mutation status indicator of the second instance to a difference status indicator indicating that the second instance includes description change without including description.
17 . The non-transitory computer-readable medium of claim 10 ,
wherein the initial audit record and the first updated audit record are stored in a format of an expression language.
18 . The non-transitory computer-readable medium of claim 15 , the operations further comprising:
obtaining a second updated audit record based on the second updated content of the data; and
storing, in the hardware storage device, the second updated audit record.
19 . A system comprising:
a hardware storage device; and
one or more processors having access to the hardware storage device and configured to:
receive a request to perform an audit on data describing a medical safety event of a plurality of medical safety events within a healthcare institution;
obtain, from the hardware storage device storing a plurality of audit records based on the request, an initial audit record corresponding to the medical safety event of the plurality of medical safety events;
parse, using a parser, fields of the initial audit record to identify a structure of the initial audit record;
access, from a database from the structure of the parsed fields, one or more fields that describe one or more properties of the medical safety event;
instantiate a mutation object based on the one or more accessed fields of the initial audit record, with the mutation object describing an initial content of the data;
access, from a database by the mutation object according to executable logic for identifying differences between data files, a first change of the data from the initial content to a first updated content, wherein the first change of the data represents each point of difference between the initial content and the first updated content;
overwrite, in memory, storage space for the mutation object with an updated mutation object that describes the first updated content, the initial content, and the first change of the data from the initial content to the first updated content so that the first change of the data indicates, separately from the first updated content and the initial content, each point of difference between the initial content and the first updated content so that the first change of the data indicates, separately from the first updated content and the initial content, each point of difference between the initial content and the first updated content,
wherein overwriting the storage space saves computing and storage resources by decreasing an amount of storage needed for tracking the first change of the data from the initial content to the first updated content using the mutation object,
wherein the updated mutation object includes:
a first instance indicating a description of the initial content; and
a second instance indicating a description of the first updated content and a description of the first change of the data from the initial content to the first updated content,
wherein the first instance is associated with a full status indicator indicating that the first instance includes description without including description change, and
wherein the second instance is associated with a combined status indicator indicating that the second instance includes both description and description change;
access, from the database, a first updated audit record based on the first updated content of the data;
store, in the hardware storage device, the updated mutation object including a single dataset corresponding to the initial content and a single dataset corresponding to the first change of the data without storing duplicate datasets of the initial content and the first change of the data, wherein storing the updated mutation object in the hardware storage device overwrites the mutation object with the updated mutation object in the hardware storage device so that first data corresponding to the mutation object is replaced with second data corresponding to the updated mutation object;
cause rendering on a display device of a user interface that provides one or more indicators of the first instance and one or more indicators of the second instance including:
a first time indicator corresponding to a time at which the first instance was created;
the full status indicator indicating that the first instance includes description without including description change;
a second time indicator to one or more times at which the second instance was created; and
the combined status indicator indicating that the second instance includes both description and description change; and
store, in the hardware storage device, the initial audit record and the first updated audit record.