type - state type (the only supported type currently are: key value, priority queue)
an existing state, i.e. the one that was already created. The returned state will not
apply TTL to the passed values, regardless of the TTL settings. This prevents double
applying of TTL (recovered values are TTL values if TTL was enabled). The state will,
however, use TTL serializer if TTL is enabled. WARN: only valid during the recovery.