=per #15429 Rewrite persistence documentation and samples (for validation)

Cherry picking this to master was a nightmare. First, master missed the persistence stream commit, so I have cherry picked that first, and after that still several conflicts. I hope this will not repeat.