Fixed #12982 -- Added a ``get_or_set`` method to the BaseCache backend.