Revert "Issue #1786490 by Berdir, amateescu, damiankloip, dawehner: Add caching to the state system." This reverts commit 8ec847cc.