Change record status: 
Project: 
Introduced in branch: 
8.3.x
Introduced in version: 
Description: 

A new key value store providing sorted sets / collections. This is for instances when sequential data needs to be stored in the key value store. it is based upon the Redis sorted sets. Keys may be used multiple times for items that are at the same position within a sequence.

Example usage:

$collection = 'my_collection';
$store = \Drupal::service('keyvalue.sorted_set')->get($collection);
$key = (int) (microtime(TRUE) * 1000000);
$value = [
  'ford' => [
    'focus',
    'fiesta',
  ],
  'volkswagen' => [
    'golf',
    'polo,
  ]
];
$store->add($key, $value);

To get items from the store the getRange($start, $stop); method would be used. This will return all items with a greater key than $start and a lower key than $stop. $stop is an optional parameter, if not provided it will get all items in the collection with a greater key than $start.

getMaxKey() and getMinKey() will return the highest and lowest keys in a collection.

getCount() will return the number of items in a collection.

Impacts: 
Module developers
Updates Done (doc team, etc.)
Online documentation: 
Not done
Theming guide: 
Not done
Module developer documentation: 
Not done
Examples project: 
Not done
Coder Review: 
Not done
Coder Upgrade: 
Not done
Other: 
Other updates done
Details: 
Progress: