How to configure a Validation Result store on a filesystem
By default,
Validation ResultsGenerated when data is Validated against an
Expectation or Expectation Suite.
are stored in the
uncommitted/validations/
directory.
Validation Results can include sensitive or regulated
data that should not be committed to a source control
system. Use the information provided here to configure
a new storage location for Validation Results in your
filesystem. You'll learn how to use an
ActionA Python class with a run method that takes a
Validation Result and does something with it
to update
Data DocsHuman readable documentation generated from Great
Expectations metadata detailing Expectations,
Validation Results, etc.
sites with new Validation Results from
CheckpointThe primary means for validating data in a
production deployment of Great Expectations.
runs.
Prerequisites
- Completion of the Quickstart guide.
- A working installation of Great Expectations.
- A Data Context.
- An Expectation Suite .
- A Checkpoint.
- A new storage location to store Validation Results. This can be a local path, or a path to a secure network filesystem.
1. Create a new folder for Validation Results
Run the following command to create a new folder for your Validation Results and move your existing Validation Results to the new folder:
# in the great_expectations/ folder
mkdir shared_validations
mv uncommitted/validations/npi_validations/ uncommitted/shared_validations/
In this example, the name of the Validation Result is
npi_validations
and the path to the new
storage location is shared_validations/
.
2. Identify your Data Context Validation Results Store
The configuration for your
Validation Results StoreA connector to store and retrieve information
about objects generated when data is Validated
against an Expectation Suite.
is available in your
Data ContextThe primary entry point for a Great Expectations
deployment, with configurations and methods for
all supporting components.. Open great_expectations.yml
and find
the following entry:
validations_store_name: validations_store
stores:
validations_store:
class_name: ValidationsStore
store_backend:
class_name: TupleFilesystemStoreBackend
base_directory: uncommitted/validations/
This configuration tells Great Expectations to look
for Validation Results in the
validations_store
Store. The default
base_directory
for
validations_store
is
uncommitted/validations/
.
3. Update your configuration file to include a new Store for Validation results
In the following example,
validations_store_name
is set to
shared_validations_filesystem_store
, but
it can be personalized. Also,
base_directory
is set to
uncommitted/shared_validations/
, but you
can set it to another path that is accessible by Great
Expectations.
validations_store_name: shared_validations_filesystem_store
stores:
shared_validations_filesystem_store:
class_name: ValidationsStore
store_backend:
class_name: TupleFilesystemStoreBackend
base_directory: uncommitted/shared_validations/
4. Confirm that the Validation Results Store has been correctly configured
Run a Checkpoint to store results in the new Validation Results Store in your new location, and then visualize the results by re-building Data Docs.