You can record Turnkey application usage and preserve model documentation when you need evidence of how an application is used and defined.
Auditability in MDriven
Auditability is the ability to review evidence about an application. In MDriven, this can include a usage trace for a Turnkey application and published documentation of the model that defines the application.
For example, if you need to review which application actions and navigations were used, add the SysTurnkeyTrace pattern to the model. If you need a document describing modeled classes, attributes, and associations, maintain their documentation in Documtr and publish it as a FlowDocument.
Trace Turnkey usage
SysTurnkeyTrace is a model pattern that catches usage of a Turnkey application. At configured intervals, it spools the trace to the database as SysTurnkeyTrace objects.
- Open the model in MDriven Designer.
- Open the LiveEdit AssetsTK tab.
- Find the SysTurnkeyTrace pattern on GitHub and merge it into your model.
- Upload and run the Turnkey application with the pattern available in the model.
- Review the
SysTurnkeyTraceobjects written to the database.
For example, when a user navigates to a view and executes an action, the pattern tracks that navigation and action. The trace is then persisted when the current trace batch is spooled to the database.
Plan for trace loss during an outage
SysTurnkeyTrace collects trace information in batches before spooling it to the database. If the server is down, the current batch can be lost. Treat this as a limit when you define audit requirements for a regulated process.
Do not use the presence of SysTurnkeyTrace alone as evidence that every event was persisted. Define the acceptable loss window based on the trace-spooling interval and the consequences of losing the current batch.
Preserve model documentation
Documtr lets you document model artifacts, including classes, attributes, and associations. The documentation context changes as you select different model elements.
- Select a model artifact in the Modlr surface.
- Open the DOC tab.
- In the Documtr dialog, double-click a documentation field.
- Enter or update the documentation in the editor.
- Select Publish Flowdocument in the Documtr window.
For example, document the meaning of a class and the purpose of its attributes, then publish the FlowDocument to create a document containing the documentation snippets and the remaining model content.
Control access to persistent changes
AccessGroups, InterestGroups and ViewModel-Enable can distinguish expressions that affect persistent data from expressions that do not. An expression affects persistent data when it creates or deletes a persistent class or writes a persistent member.
For example, an action that assigns a value to a persistent attribute is treated as affecting persistent data. You can use View-Enable rules to prevent that action when the applicable rule evaluates to false.
