From 41c17c77835c482a86b5f8eb2e9f2daa02e4e735 Mon Sep 17 00:00:00 2001 From: Zaahid Bateson Date: Thu, 2 Apr 2020 11:45:35 -0700 Subject: [PATCH] Update readme --- README.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e072ef3d..cc65cf03 100644 --- a/README.md +++ b/README.md @@ -485,7 +485,20 @@ Please review the help associated with each command as there are small differenc #### Anonymization There are a couple of changes affecting anonymization (in addition to [database configuration](#database-configuration)): -A new format and features for the requirements xml file. See the [sample_project]([sample_projects/anonymizer/) for an example new format, and also the xml schema file [requirement.xsd]([src/main/resources/com/strider/datadefender/requirement/file/requirement.xsd). +A new format and features for the requirements xml file. See the [sample_project]([sample_projects/anonymizer/) for an example new format, and also the xml schema file [requirement.xsd]([src/main/resources/com/strider/datadefender/requirement/file/requirement.xsd). Some of the high-level changes are: + +- Elements are now all lower-case, dash-separated. `````` becomes ``````, ```NotLike``` becomes ```not-like```, e.g. ``````. +- The top-level element is now `````` not `````` +- Below the top-level element, ```2.0``` is now required, and must match the version in the xsd included in the jar file. This will be updated as changes to the anonymizer happen that require new versions, so the correct version must be used on a requirement.xml file. +- ```client name``` becomes ```project name``` +- `````` becomes `````` for requirement file versioning. +- `````` ```IgnoreEmpty``` has been renamed to ```skip-empty``` and it's now "true" by default. +- `````` ```PKey``` attribute has been renamed to ```primary-key``` +- `````` ```Where``` attribute is now an element `````` under ``````. +- `````` is now called ``````. +- `````` must have a `````` or `````` below it. One or more `````` elements can exist below a `````` (used to be `````` under ``````). +- The `````` element now has ```name``` and ```type``` (to optionally specify return type) attributes. The ```name``` attribute refers to the fully-qualified name of the function (unless it's part of a class in a package defined under the top-level ``````, whereas before, the content of the `````` tag specified the name of the function. +- `````` no longer exists, instead `````` tags specify an argument to be passed to a function. The `````` tag exists directly under ``````. A new attribute of the `````` tag, ```pass-current-value``` passes the running value as the specified argument to the function. The running value for the first function in a series of functions is the columns value. Afterwords, it's the returned value from the call to the previous function. CoreFunctions has been split into a few different classes, and its package has been moved. See the new classes here: [src/main/java/com/strider/datadefender/anonymizer/functions](src/main/java/com/strider/datadefender/anonymizer/functions). Some functions have been removed entirely, for example randomInt, because apache commons can be used instead with RandomUtils.nextInt.