  For any real number $p\in [1,+\infty)$, we characterise the operations
$\mathbb{R}^I \to \mathbb{R}$ that preserve $p$-integrability, i.e., the
operations under which, for every measure $\mu$, the set $\mathcal{L}^p(\mu)$
is closed. We investigate the infinitary variety of algebras whose operations
are exactly such functions. It turns out that this variety coincides with the
category of Dedekind $\sigma$-complete truncated Riesz spaces, where truncation
is meant in the sense of R. N. Ball. We also prove that $\mathbb{R}$ generates
this variety. From this, we exhibit a concrete model of the free Dedekind
$\sigma$-complete truncated Riesz spaces. Analogous results are obtained for
operations that preserve $p$-integrability over finite measure spaces: the
corresponding variety is shown to coincide with the much studied category of
Dedekind $\sigma$-complete Riesz spaces with weak unit, $\mathbb{R}$ is proved
to generate this variety, and a concrete model of the free Dedekind
$\sigma$-complete Riesz spaces with weak unit is exhibited.
