Add persistence configuration

Allow (a subset of) the configuration to also be saved in the session to
make session-backed data more consistent and compatible with up-and-coming
multi-site setups.