Creates a writer targeting the same paths the loader reads.
Filesystem the two files are saved on.
Absolute path to config.json.
Splits and writes the full config; secrets are encrypted when configured. The secret values are registered with the value masker first, so a new credential saved from the portal is hidden from every output at once.
The merged importer config to persist.
Procedure resolving when both files are written, or failure.
Deletes the staged files a save killed mid-way left beside either file,
including the fixed-name .tmp files older releases staged at.
A save removes what it staged when it fails, but not when the process is killed. Whoever owns the process lifecycle calls this after startup.
How many were removed, or why the directory could not be read.
Persists merged config to config.json + credentials.json.